Publication | Closed Access
C/C++ Thread Safety Analysis
12
Citations
8
References
2014
Year
Unknown Venue
Software MaintenanceC++ ProgramsEngineeringCompiler TechnologySoftware EngineeringMultithreading (Computer Architecture)Memory Model (Programming)Software AnalysisFormal VerificationReliability EngineeringStatic Analysis ToolsStatic CheckingParallel ComputingCompilersCompiler SupportStatic AnalysisConcurrent ProgrammingComputer EngineeringComputer ScienceStatic Program AnalysisSoftware DesignProgram AnalysisStatic Type SystemSoftware TestingFormal MethodsSystem Software
Writing multithreaded programs is hard. Static analysis tools can help developers by allowing threading policies to be formally specified and mechanically checked. They essentially provide a static type system for threads, and can detect potential race conditions and deadlocks. This paper describes Clang Thread Safety Analysis, a tool which uses annotations to declare and enforce thread safety policies in C and C++ programs. Clang is a production-quality C++ compiler which is available on most platforms, and the analysis can be enabled for any build with a simple warning flag: -Wthread-safety. The analysis is deployed on a large scale at Google, where it has provided sufficient value in practice to drive widespread voluntary adoption. Contrary to popular belief, the need for annotations has not been a liability, and even confers some benefits with respect to software evolution and maintenance.
| Year | Citations | |
|---|---|---|
Page 1
Page 1