aComment: mining annotations from comments and code to detect interrupt related concurrency bugs

  • Authors:
  • Lin Tan;Yuanyuan Zhou;Yoann Padioleau

  • Affiliations:
  • University of Waterloo, Waterloo, ON, Canada;University of California, San Diego, La Jolla, CA, USA;Facebook, Inc., Palo Alto, CA, USA

  • Venue:
  • Proceedings of the 33rd International Conference on Software Engineering
  • Year:
  • 2011

Quantified Score

Hi-index 0.03

Visualization

Abstract

Concurrency bugs in an operating system (OS) are detrimental as they can cause the OS to fail and affect all applications running on top of the OS. Detecting OS concurrency bugs is challenging due to the complexity of the OS synchronization, particularly with the presence of the OS specific interrupt context. Existing dynamic concurrency bug detection techniques are designed for user level applications and cannot be applied to operating systems. To detect OS concurrency bugs, we proposed a new type of annotations - interrupt related annotations - and generated 96,821 such annotations for the Linux kernel with little manual effort. These annotations have been used to automatically detect 9 real OS concurrency bugs (7 of which were previously unknown). Two of the key techniques that make the above contributions possible are: (1) using a hybrid approach to extract annotations from both code and comments written in natural language to achieve better coverage and accuracy in annotation extraction and bug detection; and (2) automatically propagating annotations to caller functions to improve annotating and bug detection. These two techniques are general and can be applied to non-OS code, code written in other programming languages such as Java, and for extracting other types of specifications.