Refined Input, Degraded Output: The Counterintuitive World of Compiler Behavior
summary
Automated pipeline instruments C programs generated by cith with runtime checks, then injects compiler builtins (unreachable/assume) to encode observed dead branches and value ranges, compiles with GCC/LLVM, and compares outputs using size, dead-code, and value-range oracles. Testing on 10,000 generated programs surfaces regressions in a nontrivial single-digit percent of cases; analysis attributes failures to buggy passes and interactions (notably value-range propagation), and leads to 59 cases reported across GCC and LLVM, 55 confirmed or fixed.
AI-written summary · about
chapters (9)
- 0:00Compiler behavior quirks
- 1:24Compiler assumptions backfire
- 3:57Compiler pass interactions
- 5:44Automated testing for misbehavior
- 8:54Oracle methods for regressions
- 12:45Root causes of regressions
- 14:09Prevalence in real code
- 15:34Implications for compiler design
- 16:57Q&A
related talks
53mLocknote: How Badly Do We Want Correct Compilers?
53mFrom Within: Compiler Testing and Validation via Compilers
01h 25mPeeking Into Your Compiler
59mCompilers can be surprising
17mRecent Developments in Optimizing Compilers for RISC-V
01h 04mCompiler Bugs And Bug Compilers
52mUnderstanding Compiler Optimization
14mUnveiling Compiler Faults via Attribute-Guided Compilation Space Exploration
