Practical verification of peephole optimizations with alive

Nuno P. Lopes, David Menendez, Santosh Nagarakatte, John Regehr

Research output: Contribution to journalArticlepeer-review

7 Scopus citations

Abstract

Compilers should not miscompile. Peephole optimizations, which perform local rewriting of the input program to improve the efficiency of generated code, are a persistent source of compiler bugs. We created Alive, a domain-specific language for writing optimizations and for automatically either proving them correct or else generating counterexamples. Furthermore, Alive can be automatically translated into C++ code that is suitable for inclusion in an LLVM optimization pass. Alive is based on an attempt to balance usability and formal methods; for example, it captures-but largely hides-The detailed semantics of the various kinds of undefined behavior. Alive has found numerous bugs in the LLVM compiler and is being used by LLVM developers.

Original languageAmerican English
Pages (from-to)84-91
Number of pages8
JournalCommunications of the ACM
Volume61
Issue number2
DOIs
StatePublished - Feb 2018

ASJC Scopus subject areas

  • Computer Science(all)

Fingerprint

Dive into the research topics of 'Practical verification of peephole optimizations with alive'. Together they form a unique fingerprint.

Cite this