Model-Based Diagnosis with Multiple Observations: A Unified Approach for C Software and Boolean Circuits

📅 2025-12-02
📈 Citations: 0
Influential: 0
📄 PDF
🤖 AI Summary
Debugging multi-fault programs and circuits remains a critical bottleneck in software and hardware verification; existing formula-based fault localization (FBFL) techniques often lack diagnostic completeness and subset minimality. This paper introduces the first unified model-based diagnosis (MBD) framework for both C programs and Boolean circuits, which jointly encodes multiple failing test cases into a single MaxSAT problem to yield cross-observation-consistent, subset-minimal, and precise diagnoses. By innovatively integrating MBD theory with MaxSAT solving, our approach eliminates redundant diagnoses and enhances interpretability. Experimental evaluation on TCAS, C-Pack-IPAs, and ISCAS85 benchmarks demonstrates that CFaults significantly outperforms BugAssist, SNIPER, and HSD in fault localization speed for C programs while exclusively outputting minimal diagnosis sets; in circuit diagnosis, it matches HSD’s accuracy and efficiency.

Technology Category

Application Category

📝 Abstract
Debugging is one of the most time-consuming and expensive tasks in software development and circuit design. Several formula-based fault localisation (FBFL) methods have been proposed, but they fail to guarantee a set of diagnoses across all failing tests or may produce redundant diagnoses that are not subset-minimal, particularly for programs/circuits with multiple faults. This paper introduces CFaults, a novel fault localisation tool for C software and Boolean circuits with multiple faults. CFaults leverages Model-Based Diagnosis (MBD) with multiple observations and aggregates all failing test cases into a unified Maximum Satisfiability (MaxSAT) formula. Consequently, our method guarantees consistency across observations and simplifies the fault localisation procedure. Experimental results on three benchmark sets, two of C programs, TCAS and C-Pack-IPAs, and one of Boolean circuits, ISCAS85, show that CFaults is faster at localising faults in C software than other FBFL approaches such as BugAssist, SNIPER, and HSD. On the ISCAS85 benchmark, CFaults is generally slower than HSD; however, it localises faults in only 6% fewer circuits, demonstrating that it remains competitive in this domain. Furthermore, CFaults produces only subset-minimal diagnoses of faulty statements, whereas the other approaches tend to enumerate redundant diagnoses (e.g., BugAssist and SNIPER).
Problem

Research questions and friction points this paper is trying to address.

Develops a unified fault localization tool for C software and Boolean circuits with multiple faults.
Ensures consistent diagnoses across all failing tests using a unified MaxSAT formula.
Produces only subset-minimal diagnoses, eliminating redundancy compared to existing methods.
Innovation

Methods, ideas, or system contributions that make the work stand out.

Leverages Model-Based Diagnosis with multiple observations
Aggregates failing tests into unified MaxSAT formula
Guarantees subset-minimal diagnoses for C software and Boolean circuits
🔎 Similar Papers
No similar papers found.