Team Celtique

Overall Objectives
Scientific Foundations
New Results
Contracts and Grants with Industry

Section: New Results

Certified Static Analysis and Compilation

Participants : Frédéric Besson, Sandrine Blazy, David Cachera, Thomas Jensen, David Pichardie.

A certified static analysis is an analysis whose semantic validity has been formally proved correct with a proof assistant. The recent increasing interest in using proof assistants for mechanizing programming language metatheory has given rise to several approaches for certification of static analysis. We propose in [19] a panorama of these techniques and compare their respective strengths and weaknesses.

In [27] we propose a tutorial on building a certified static analysis in Coq. We study a simple bytecode language for which we propose an interval analysis that allows to verify statically that no array-out-of-bounds accesses will occur.

Proving the correctness of an analyzer is based on semantic properties, and becomes difficult to ensure when complex analysis techniques are involved. In [14] we propose to adapt the general theory of static analysis by abstract interpretation to the framework of constructive logic. Implementing this formalism into the Coq proof assistant then allows for automatic extraction of certified analyzers. We focus in this work on a simple imperative language and present the computation of fixpoints by widening/narrowing and syntax-directed iteration techniques.

Iterated Register Coalescing (IRC) is a widely used heuristic for performing register allocation via graph coloring. Many implementations in existing compilers follow the imperative algorithm published in 1996. In [16] , we present a formal verification of the whole IRC algorithm, that can be used as a reference for IRC. We also define the theory of register-interference graphs in Coq; we implement a purely functional version of the IRC algorithm, and we prove its total correctness. The automatic extraction of our IRC algorithm yields a program with competitive performance. This work has been integrated into the CompCert verified compiler.

In [17] , we focus on optimal register allocation and we present two compiler optimizations for reducing interference graphs, while preserving optimality. This work has been done while Sandrine Blazy was a member of the Gallium group, as well as the definition of a formal semantics for the Clight source language of the CompCert compiler [11] .


Logo Inria