Accelerating race condition detection through procrastination
Paper in proceeding, 2011

Race conditions are notoriously frustrating to find, and good tools can help. The main difficulty is reliably provoking the race condition. In previous work we presented a randomising scheduler for Erlang that helps with this task. In a language without pervasive shared mutable state, such as Erlang, performing scheduling decisions at random uncovers race conditions surprisingly well. However, it is not always enough. We describe a technique, procrastination, that aims to provoke race conditions more often than by random scheduling alone. It works by running the program and looking for pairs of events that might interfere, such as two message sends to the same process. Having found such a pair of events, we re-run the program but try to provoke a race condition by reversing the order of the two events. We apply our technique to a piece of industrial Erlang code. Compared to random scheduling alone, procrastination allows us to find minimal failing test cases more reliably and more quickly.

quickcheck

race conditions

erlang

Author

Thomas Arts

Chalmers, Computer Science and Engineering (Chalmers), Software Engineering (Chalmers)

John Hughes

Chalmers, Computer Science and Engineering (Chalmers), Software Technology (Chalmers)

Ulf Norell

Chalmers, Computer Science and Engineering (Chalmers), Computing Science (Chalmers)

Nicholas Smallbone

Chalmers, Computer Science and Engineering (Chalmers), Software Technology (Chalmers)

Hans Svensson

Chalmers, Computer Science and Engineering (Chalmers), Software Engineering (Chalmers)

Proceedings of the 2011 ACM SIGPLAN Erlang Workshop, Tokyo, 23 September 2011

14-22
978-145030859-5 (ISBN)

Subject Categories

Computer and Information Science

DOI

10.1145/2034654.2034659

ISBN

978-145030859-5

More information

Latest update

9/7/2021 1