Abstract

Data races are one of the major causes of concurrency bugs in multithreaded programs, but they are hard to find due to nondeterministic thread scheduling. Data race detectors are essential tools that help long-suffering programmers to locate data races in multithreaded programs. One type of detectors precisely detects data races but is sensitive to thread scheduling, whereas another type is less sensitive to thread scheduling but reports a considerable number of false positives. In this paper, we propose a new dynamic data race detector called Simple Lock that accurately detects data races in a scheduling insensitive manner with low execution overhead. We reduce execution overhead by using two assumptions. The first is that most data races are caused by the accessing of shared variables without locks. The second is that two accesses that cause a data race have not a long distance between them in an execution trace. The results of experiments conducted on the Road Runner framework confirm that these assumptions are valid and that our Simple Lock detector can efficiently and accurately detect real and potential data races in one execution trace. The results also indicate that the execution overhead of Simple Lock is not much higher than that of Fast Track, the fastest happens-before race detector.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call