LOCKSMITH: Practical static race detection for C

TitleLOCKSMITH: Practical static race detection for C
Publication TypeJournal Articles
Year of Publication2011
AuthorsPratikakis P, Foster JS, Hicks MW
JournalACM Trans. Program. Lang. Syst.
Volume33
Issue1
Pagination3:1–3:55 - 3:1–3:55
Date Published2011/01//
ISBN Number0164-0925
Keywordscontext sensitivity, contextual effects, correlation inference, Data race, locksmith, race detection, sharing analysis, static analysis
Abstract

Locksmith is a static analysis tool for automatically detecting data races in C programs. In this article, we describe each of Locksmith's component analyses precisely, and present systematic measurements that isolate interesting trade-offs between precision and efficiency in each analysis. Using a benchmark suite comprising stand-alone applications and Linux device drivers totaling more than 200,000 lines of code, we found that a simple no-worklist strategy yielded the most efficient interprocedural dataflow analysis; that our sharing analysis was able to determine that most locations are thread-local, and therefore need not be protected by locks; that modeling C structs and void pointers precisely is key to both precision and efficiency; and that context sensitivity yields a much more precise analysis, though with decreased scalability. Put together, our results illuminate some of the key engineering challenges in building Locksmith and data race detection analyses in particular, and constraint-based program analyses in general.

URLhttp://doi.acm.org/10.1145/1889997.1890000
DOI10.1145/1889997.1890000