Recompilation Is Not Enough: Test-Guided Decompiled-C Repair
Abstract
Decompiled C often becomes recompilable only after repair, but recompilation alone does not establish test-observed behavior. A recompiled command-line binary can still parse options incorrectly, print different bytes, or return a different exit status. We present a few-step workflow for repairing decompiled C using compiler feedback and related official tests. Compiler and linker diagnostics first guide build repair. Once the repaired C recompiles into a binary, smoke checks and related official tests expose behavioral discrepancies for semantic repair. In a preliminary static-enriched evaluation on 104 Coreutils 9.5 binaries with available decompiler exports and deterministic exact-output smoke comparisons, 91 binaries (87.5%) recompile and pass the test gate; 9 do not recompile within the repair budget, and 4 recompile but still fail the test gate. The result suggests that test-gate feedback can make LLM-assisted repair of decompiled C more auditable than compile-only recovery.
Create a lesson
Metadata
- Categories
- cs.SE, cs.AI
- Comments
- 5 pages, 2 figures
Related papers
Does Fault Localization Beat a Fresh Attempt? A Placebo-Controlled Study of Test-Guided Code Repair
Shared title terminologycs.SEAnik Jha
Towards Autonomous Mobile Testing with LLM-Guided Non-Invasive Interaction
Shared title terminologycs.SEDavi Freitas, Breno Miranda, Juliano Iyoda
From Suspicious Signals to Crashes: Guiding Bug-Driven GUI Testing via Code-Inspired Tracing
Shared title terminologycs.SEMengzhuo Chen, Zhe Liu, Chunyang Chen et al.
Correct Tests Are Not Enough: Measuring and Training Oracle Conversion in Specification-Based Test Generation
Shared title terminologycs.SEYunhao Liang, Chengguang Gan, Ruixuan Ying et al.
SWE-Gate: Passing Functional Tests Is Not Enough for Software Engineering Agents
Shared title terminologycs.SEXin He, Yanlin Wang, Mingwei Liu et al.
Separate What from How: Repairing Static Analyzer Summaries with a Typed Repair IR
Shared title terminologycs.SEJinbao Chen, Zixiang Zhou, Yu Zhang