Effective fault localization and context-aware debugging for concurrent programs

Justin Chu, Tingting Yu, Jane Huffman Hayes, Xue Han, Yu Zhao

Research output: Contribution to journalArticlepeer-review

1 Scopus citations


Concurrent programs are difficult to debug because concurrency faults usually occur under specific inputs and thread interleavings. Fault localization techniques for sequential programs are often ineffective because the root causes of concurrency faults involve memory accesses across multiple threads rather than single statements. Previous research has proposed techniques to analyse passing and failing executions obtained from running a set of test cases for identifying faulty memory access patterns. However, stand-alone access patterns do not provide enough contextual information, such as the path leading to the failure, for developers to understand the bug. We present an approach, Coadec, to automatically generate interthread control flow paths that can link memory access patterns that occurred most frequently in the failing executions to better diagnose concurrency bugs. Coadec consists of two phases. In the first phase, we use feature selection techniques from machine learning to localize suspicious memory access patterns based on failing and passing executions. The patterns with maximum feature diversity information can point to the most suspicious pattern. We then apply a data mining technique and identify the memory access patterns that occurred most frequently in the failing executions. Finally, Coadec identifies faulty program paths by connecting both the frequent patterns and the suspicious pattern. We also evaluate the effectiveness of fault localization using test suites generated from different test adequacy criteria. We introduce and have evaluated Coadec on 10 real-world multithreaded Java applications. Results indicate that Coadec outperforms state-of-the-art approaches for localizing concurrency faults and that Coadec's context debugging can help developers understand concurrency fault by inspecting a small percentage of code.

Original languageEnglish
Article numbere1797
JournalSoftware Testing Verification and Reliability
Issue number1
StatePublished - Jan 2022

Bibliographical note

Funding Information:
This work was supported in part by National Science Foundation Grants CCF‐1464032, CCF‐1652149 and CCF‐1511117.

Publisher Copyright:
© 2021 John Wiley & Sons, Ltd


  • concurrent program
  • fault localization
  • software debugging

ASJC Scopus subject areas

  • Software
  • Safety, Risk, Reliability and Quality


Dive into the research topics of 'Effective fault localization and context-aware debugging for concurrent programs'. Together they form a unique fingerprint.

Cite this