ACM SIGPLAN Notices · 2014 · 207 citations · 19 references
ComputingComputer EngineeringComputer ScienceCompilersMalware AnalysisProgramming LanguagesCompiler ConstructionControl-flow AnalysisData-flow AnalysisEquivalence CheckingSoftware TestingCompiler Optimization ValidationProgram Transformation
We introduce equivalence modulo inputs (EMI) , a simple, widely applicable methodology for validating optimizing compilers. Our key insight is to exploit the close interplay between (1) dynamically executing a program on some test inputs and (2) statically compiling the program to work on all possible inputs. Indeed, the test inputs induce a natural collection of the original program's EMI variants, which can help differentially test any compiler and specifically target the difficult-to-find miscompilations. To create a practical implementation of EMI for validating C compilers, we profile a program's test executions and stochastically prune its unexecuted code. Our extensive testing in eleven months has led to 147 confirmed, unique bug reports for GCC and LLVM alone. The majority of those bugs are miscompilations, and more than 100 have already been fixed. Beyond testing compilers, EMI can be adapted to validate program transformation and analysis systems in general. This work opens up this exciting, new direction.
19
Finding and understanding bugs in C compilers
Xuejun Yang, Yang Chen, Eric Eide et al. · 2011 · 733 citations
Formal certification of a compiler back-end or
Xavier Leroy · 2006 · 652 citations
Translation validation for an optimizing compiler
George C. Necula · 2000 · 487 citations
A Formally Verified Compiler Back-end
Xavier Leroy · Journal of Automated Reasoning · 2009 · 487 citations · Full text
Differential Testing for Software.
W. M. McKeeman · 1998 · 454 citations