What Types of Bugs Exist?

This lesson presents a summary of different types of concurrency bugs based on a study.

The first, and most obvious, the question is this: what types of concurrency bugs manifest in complex, concurrent programs? This question is difficult to answer in general, but fortunately, some others have done the work for us. Specifically, we rely upon a study by Lu et al.“Learning from Mistakes — A Comprehensive Study on Real World Concurrency Bug Characteristics” by Shan Lu, Soyeon Park, Eunsoo Seo, Yuanyuan Zhou. ASPLOS ’08, March 2008, Seattle, Washington. The first in-depth study of concurrency bugs in real software, and the basis for this chapter. Look at Y.Y. Zhou’s or Shan Lu’s web pages for many more interesting papers on bugs., which analyzes a number of popular concurrent applications in great detail to understand what types of bugs arise in practice.

The study focuses on four major and important open-source applications:

  • MySQL (a popular database management system)
  • Apache (a well-known web server)
  • Mozilla (the famous web browser)
  • OpenOffice (a free version of the MS Office suite, which some people actually use).

In the study, the authors examine concurrency bugs that have been found and fixed in each of these code bases, turning the developers’ work into a quantitative bug analysis; understanding these results can help you understand what types of problems actually occur in mature codebases.

The table below shows a summary of the bugs Lu and colleagues studied. From the figure, you can see that there were 105 total bugs, most of which were not deadlock (74); the remaining 31 were deadlock bugs. Further, you can see the number of bugs studied from each application; while OpenOffice only had 8 total concurrency bugs, Mozilla had nearly 60.

Get hands-on with 1400+ tech skills courses.