TY - GEN
T1 - Ballerina
T2 - 34th International Conference on Software Engineering, ICSE 2012
AU - Nistor, Adrian
AU - Luo, Qingzhou
AU - Pradel, Michael
AU - Gross, Thomas R.
AU - Marinov, Darko
PY - 2012
Y1 - 2012
N2 - Testing multithreaded code is hard and expensive. A multithreaded unit test creates two or more threads, each executing one or more methods on shared objects of the class under test. Such unit tests can be generated at random, but basic random generation produces tests that are either slow or do not trigger concurrency bugs. Worse, such tests have many false alarms, which require human effort to filter out. We present Ballerina, a novel technique for automated random generation of efficient multithreaded tests that effectively trigger concurrency bugs. Ballerina makes tests efficient by having only two threads, each executing a single, randomly selected method. Ballerina increases chances that such simple parallel code finds bugs by appending it to more complex, randomly generated sequential code. We also propose a clustering technique to reduce the manual effort in inspecting failures of automatically generated multithreaded tests. We evaluate Ballerina on 14 real-world bugs from six popular codebases: Groovy, JDK, JFreeChart, Apache Log4j, Apache Lucene, and Apache Pool. The experiments show that tests generated by Ballerina find bugs on average 2X-10X faster than basic random generation, and our clustering technique reduces the number of inspected failures on average 4X-8X. Using Ballerina, we found three previously unknown bugs, two of which were already confirmed and fixed.
AB - Testing multithreaded code is hard and expensive. A multithreaded unit test creates two or more threads, each executing one or more methods on shared objects of the class under test. Such unit tests can be generated at random, but basic random generation produces tests that are either slow or do not trigger concurrency bugs. Worse, such tests have many false alarms, which require human effort to filter out. We present Ballerina, a novel technique for automated random generation of efficient multithreaded tests that effectively trigger concurrency bugs. Ballerina makes tests efficient by having only two threads, each executing a single, randomly selected method. Ballerina increases chances that such simple parallel code finds bugs by appending it to more complex, randomly generated sequential code. We also propose a clustering technique to reduce the manual effort in inspecting failures of automatically generated multithreaded tests. We evaluate Ballerina on 14 real-world bugs from six popular codebases: Groovy, JDK, JFreeChart, Apache Log4j, Apache Lucene, and Apache Pool. The experiments show that tests generated by Ballerina find bugs on average 2X-10X faster than basic random generation, and our clustering technique reduces the number of inspected failures on average 4X-8X. Using Ballerina, we found three previously unknown bugs, two of which were already confirmed and fixed.
UR - https://www.scopus.com/pages/publications/84864224668
UR - https://www.scopus.com/pages/publications/84864224668#tab=citedBy
U2 - 10.1109/ICSE.2012.6227145
DO - 10.1109/ICSE.2012.6227145
M3 - Conference contribution
AN - SCOPUS:84864224668
SN - 9781467310673
T3 - Proceedings - International Conference on Software Engineering
SP - 727
EP - 737
BT - Proceedings - 34th International Conference on Software Engineering, ICSE 2012
Y2 - 2 June 2012 through 9 June 2012
ER -