<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8"/>
    <title>Project-Team:CELTIQUE</title>
    <link rel="stylesheet" href="../static/css/raweb.css" type="text/css"/>
    <meta name="description" content="Research Program - Static program analysis"/>
    <meta name="dc.title" content="Research Program - Static program analysis"/>
    <meta name="dc.subject" content=""/>
    <meta name="dc.publisher" content="INRIA"/>
    <meta name="dc.date" content="(SCHEME=ISO8601) 2015-01"/>
    <meta name="dc.type" content="Report"/>
    <meta name="dc.language" content="(SCHEME=ISO639-1) en"/>
    <meta name="projet" content="CELTIQUE"/>
    <!-- Piwik -->
    <script type="text/javascript" src="/rapportsactivite/piwik.js"></script>
    <noscript><p><img src="//piwik.inria.fr/piwik.php?idsite=49" style="border:0;" alt="" /></p></noscript>
    <!-- End Piwik Code -->
  </head>
  <body>
    <div class="tdmdiv">
      <div class="logo">
        <a href="http://www.inria.fr">
          <img style="align:bottom; border:none" src="../static/img/icons/logo_INRIA-coul.jpg" alt="Inria"/>
        </a>
      </div>
      <div class="TdmEntry">
        <div class="tdmentete">
          <a href="uid0.html">Project-Team Celtique</a>
        </div>
        <span>
          <a href="uid1.html">Members</a>
        </span>
      </div>
      <div class="TdmEntry">Overall Objectives<ul><li><a href="./uid3.html">Project overview</a></li></ul></div>
      <div class="TdmEntry">Research Program<ul><li class="tdmActPage"><a href="uid5.html&#10;&#9;&#9;  ">Static program analysis</a></li></ul></div>
      <div class="TdmEntry">
        <a href="./uid13.html">Highlights of the Year</a>
      </div>
      <div class="TdmEntry">New Software and Platforms<ul><li><a href="uid16.html&#10;&#9;&#9;  ">JSCert</a></li><li><a href="uid21.html&#10;&#9;&#9;  ">Jacal</a></li><li><a href="uid24.html&#10;&#9;&#9;  ">Javalib</a></li><li><a href="uid28.html&#10;&#9;&#9;  ">SAWJA</a></li><li><a href="uid32.html&#10;&#9;&#9;  ">Timbuk</a></li><li><a href="uid36.html&#10;&#9;&#9;  ">CompCertSSA</a></li></ul></div>
      <div class="TdmEntry">New Results<ul><li><a href="uid41.html&#10;&#9;&#9;  ">Certified compilation</a></li><li><a href="uid44.html&#10;&#9;&#9;  ">Certified Static Analyses</a></li><li><a href="uid48.html&#10;&#9;&#9;  ">Static analysis of functional programs
using tree automata and term rewriting</a></li><li><a href="uid49.html&#10;&#9;&#9;  ">Static analysis of functional specifications</a></li><li><a href="uid50.html&#10;&#9;&#9;  ">Semantics</a></li></ul></div>
      <div class="TdmEntry">Partnerships and Cooperations<ul><li><a href="uid53.html&#10;&#9;&#9;  ">National Initiatives</a></li><li><a href="uid61.html&#10;&#9;&#9;  ">International Initiatives</a></li><li><a href="uid73.html&#10;&#9;&#9;  ">International Research Visitors</a></li></ul></div>
      <div class="TdmEntry">Dissemination<ul><li><a href="uid81.html&#10;&#9;&#9;  ">Promoting Scientific Activities</a></li><li><a href="uid118.html&#10;&#9;&#9;  ">Teaching - Supervision - Juries</a></li><li><a href="uid166.html&#10;&#9;&#9;  ">Popularization</a></li></ul></div>
      <div class="TdmEntry">
        <div>Bibliography</div>
      </div>
      <div class="TdmEntry">
        <ul>
          <li>
            <a id="tdmbibentmajor" href="bibliography.html">Major publications</a>
          </li>
          <li>
            <a id="tdmbibentyear" href="bibliography.html#year">Publications of the year</a>
          </li>
          <li>
            <a id="tdmbibentfoot" href="bibliography.html#References">References in notes</a>
          </li>
        </ul>
      </div>
    </div>
    <div id="main">
      <div class="mainentete">
        <div id="head_agauche">
          <small><a href="http://www.inria.fr">
	    
	    Inria
	  </a> | <a href="../index.html">
	    
	    Raweb 
	    2015</a> | <a href="http://www.inria.fr/en/teams/celtique">Presentation of the Project-Team CELTIQUE</a> | <a href="http://www.irisa.fr/celtique">CELTIQUE Web Site
	  </a></small>
        </div>
        <div id="head_adroite">
          <table class="qrcode">
            <tr>
              <td>
                <a href="celtique.xml">
                  <img style="align:bottom; border:none" alt="XML" src="../static/img/icons/xml_motif.png"/>
                </a>
              </td>
              <td>
                <a href="celtique.pdf">
                  <img style="align:bottom; border:none" alt="PDF" src="IMG/qrcode-celtique-pdf.png"/>
                </a>
              </td>
              <td>
                <a href="../celtique/celtique.epub">
                  <img style="align:bottom; border:none" alt="e-pub" src="IMG/qrcode-celtique-epub.png"/>
                </a>
              </td>
            </tr>
            <tr>
              <td/>
              <td>PDF
</td>
              <td>e-Pub
</td>
            </tr>
          </table>
        </div>
      </div>
      <!--FIN du corps du module-->
      <br/>
      <div class="bottomNavigation">
        <div class="tail_aucentre">
          <a href="./uid3.html" accesskey="P"><img style="align:bottom; border:none" alt="previous" src="../static/img/icons/previous_motif.jpg"/> Previous | </a>
          <a href="./uid0.html" accesskey="U"><img style="align:bottom; border:none" alt="up" src="../static/img/icons/up_motif.jpg"/>  Home</a>
          <a href="./uid13.html" accesskey="N"> | Next <img style="align:bottom; border:none" alt="next" src="../static/img/icons/next_motif.jpg"/></a>
        </div>
        <br/>
      </div>
      <div id="textepage">
        <!--DEBUT2 du corps du module-->
        <h2>Section: 
      Research Program</h2>
        <h3 class="titre3">Static program analysis</h3>
        <p>Static program analysis is concerned with obtaining information about
the run-time behaviour of a program without actually running it. This
information may concern the values of variables, the relations among
them, dependencies between program values, the memory structure being
built and manipulated, the flow of control, and, for concurrent
programs, synchronisation among processes executing in parallel.
Fully automated analyses usually render approximate information about
the actual program behaviour. The analysis is correct if the
information includes all possible behaviour of a
program. Precision of an analysis is improved by reducing the amount
of information describing spurious behaviour that will never occur.</p>
        <p>Static analysis has traditionally found most of its applications in the area of
program optimisation where information about the
run-time behaviour can be used to transform a program so that it
performs a calculation faster and/or makes
better use of the available memory resources.
The last decade has witnessed an increasing use of static analysis in
software verification for proving invariants about programs. The
Celtique
project is mainly concerned with this
latter use. Examples of static
analysis include:</p>
        <ul>
          <li>
            <p class="notaparagraph"><a name="uid6"> </a>Data-flow analysis as it is used in optimising compilers for
imperative languages. The properties can either be approximations of
the values of an expression (“the value of variable <span class="math"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>𝗑</mi></math></span> is
greater than 0” or <span class="math"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>𝗑</mi></math></span> is equal to <span class="math"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>𝗒</mi></math></span> at this
point in the program” ) or more intensional information about program
behaviour such as “this variable is not used before being re-defined”
in the classical “dead-variable” analysis <a href="./bibliography.html#celtique-2015-bid0">[74]</a> .</p>
          </li>
          <li>
            <p class="notaparagraph"><a name="uid7"> </a>Analyses of the memory structure includes shape analysis that
aims at approximating the data structures created by a program.
Alias analysis is another data flow analysis that finds out
which variables in a program addresses the same memory location. Alias
analysis is a fundamental analysis for all kinds of programs
(imperative, object-oriented) that manipulate state, because alias
information is necessary for the precise modelling of assignments.</p>
          </li>
          <li>
            <p class="notaparagraph"><a name="uid8"> </a>Control flow analysis will find a safe approximation to the
order in which the instructions of a program are executed. This is
particularly relevant in languages where parameters or functions can be
passed as arguments to other functions, making it impossible to
determine the flow of control from the program syntax alone. The same
phenomenon occurs in object-oriented languages where it is the class
of an object (rather than the static type of the variable containing
the object) that determines which method a given method invocation
will call. Control flow analysis is an example of an analysis
whose information in itself does not lead to dramatic optimisations
(although it might enable in-lining of code) but is necessary for
subsequent analyses to give precise results.</p>
          </li>
        </ul>
        <p>Static analysis possesses strong <b>semantic foundations</b>, notably abstract
interpretation <a href="./bibliography.html#celtique-2015-bid1">[57]</a> , that allow to prove its correctness. The
implementation of static analyses is usually based on well-understood
constraint-solving techniques and iterative fixpoint algorithms. In
spite of the nice mathematical theory of program analysis and the
solid algorithmic techniques available one problematic issue persists,
<i>viz.</i>, the <i>gap</i> between the analysis that is proved
correct on paper and the analyser that actually runs on the
machine. While this gap might be small for toy languages, it becomes
important when it comes to real-life languages for which the
implementation and maintenance of program analysis tools become a
software engineering task. A <i>certified static analysis</i> is an
analysis that has been formally proved correct using a
proof assistant.</p>
        <p>In previous work we studied the benefit of using abstract
interpretation for developing <b>certified static analyses</b>
<a href="./bibliography.html#celtique-2015-bid2">[55]</a> , <a href="./bibliography.html#celtique-2015-bid3">[77]</a> . The development of
certified static analysers is an ongoing activity that will be part of
the Celtique project. We use the Coq proof assistant which allows for
extracting the computational content of a constructive proof. A Caml
implementation can hence be extracted from a proof of existence, for
any program, of a correct approximation of the concrete program
semantics. We have isolated a theoretical framework based on abstract
interpretation allowing for the formal development of a broad range of
static analyses. Several case studies for the analysis of Java byte
code have been presented, notably a memory usage analysis
<a href="./bibliography.html#celtique-2015-bid4">[56]</a> . This work has recently found
application in the context of Proof Carrying Code
and have also been successfully applied to
particular form of static analysis based on term rewriting and tree
automata <a href="./bibliography.html#celtique-2015-bid5">[4]</a> .</p>
        <a name="uid9"/>
        <h4 class="titre4">Static analysis of Java</h4>
        <p>Precise context-sensitive control-flow analysis is a fundamental
prerequisite for precisely analysing Java programs.
Bacon and Sweeney's Rapid Type Analysis (RTA)  <a href="./bibliography.html#celtique-2015-bid6">[48]</a>  is a
scalable algorithm for constructing an initial call-graph of the
program. Tip and Palsberg  <a href="./bibliography.html#celtique-2015-bid7">[80]</a>  have proposed a variety of
more precise but scalable call graph construction algorithms
<i>e.g.,</i> MTA, FTA, XTA which accuracy is between RTA and 0'CFA.
All those analyses are not context-sensitive. As early as 1991,
Palsberg and Schwartzbach  <a href="./bibliography.html#celtique-2015-bid8">[75]</a> , <a href="./bibliography.html#celtique-2015-bid9">[76]</a>  proposed a theoretical
parametric framework for typing object-oriented programs in a
context-sensitive way. In their setting, context-sensitivity is
obtained by explicit code duplication and typing amounts to analysing
the expanded code in a context-insensitive manner. The framework
accommodates for both call-contexts and allocation-contexts.</p>
        <p>To assess the respective merits of different instantiations, scalable
implementations are needed. For Cecil and Java programs, Grove
<i>et al.,</i>  <a href="./bibliography.html#celtique-2015-bid10">[64]</a> , <a href="./bibliography.html#celtique-2015-bid11">[63]</a>  have explored the algorithmic design
space of contexts for benchmarks of significant size.
Later on, Milanova <i>et. al.,</i>  <a href="./bibliography.html#celtique-2015-bid12">[71]</a>  have
evaluated, for Java programs, a notion of context called
<i>object-sensitivity</i> which abstracts the call-context by the
abstraction of the <tt>this</tt>  pointer. More recently, Lhotak and
Hendren  <a href="./bibliography.html#celtique-2015-bid13">[69]</a>  have extended the empiric
evaluation of object-sensitivity using a BDD implementation allowing
to cope with benchmarks otherwise out-of-scope.
Besson and Jensen  <a href="./bibliography.html#celtique-2015-bid14">[53]</a>  proposed to use <span class="smallcap">datalog </span>
in order to specify context-sensitive analyses. Whaley and
Lam  <a href="./bibliography.html#celtique-2015-bid15">[81]</a>  have implemented a context-sensitive
analysis using a BDD-based <span class="smallcap">datalog </span> implementation.</p>
        <p>Control-flow analyses are a prerequisite for other analyses. For instance, the
security analyses of Livshits and Lam  <a href="./bibliography.html#celtique-2015-bid16">[70]</a>  and
the race analysis of Naik, Aiken  <a href="./bibliography.html#celtique-2015-bid17">[72]</a>  and
Whaley  <a href="./bibliography.html#celtique-2015-bid18">[73]</a>  both heavily rely on the precision of a
control-flow analysis.</p>
        <p>Control-flow analysis allows to statically prove the absence of
certain run-time errors such as "message not understood" or cast
exceptions. Yet it does not tackle the problem of "null pointers".
Fahnrich and Leino  <a href="./bibliography.html#celtique-2015-bid19">[60]</a>  propose a type-system for
checking that after object creation fields are non-null. Hubert,
Jensen and Pichardie have formalised the type-system and derived a
type-inference algorithm computing the most precise
typing  <a href="./bibliography.html#celtique-2015-bid20">[67]</a> . The
proposed technique has been implemented in a tool called
NIT  <a href="./bibliography.html#celtique-2015-bid21">[66]</a> . Null pointer
detection is also done by bug-detection tools such as
FindBugs  <a href="./bibliography.html#celtique-2015-bid21">[66]</a> . The main difference is that the
approach of findbugs is neither sound nor complete but effective in
practice.</p>
        <a name="uid10"/>
        <h4 class="titre4">Quantitative aspects of static analysis</h4>
        <p>Static analyses yield qualitative results, in the sense that they
compute a safe over-approximation of the concrete semantics of a
program, w.r.t. an order provided by the abstract domain structure.
Quantitative aspects of static analysis are two-sided: on one hand,
one may want to express and verify (compute) quantitative
properties of programs that are not captured by usual semantics, such
as time, memory, or energy consumption; on the other hand, there is a
deep interest in quantifying the precision of an analysis, in order to
tune the balance between complexity of the analysis and accuracy of
its result.</p>
        <p>The term of quantitative analysis is often related to probabilistic
models for abstract computation devices such as timed automata or
process algebras. In the field of programming languages which is more
specifically addressed by the Celtique project, several approaches have
been proposed for quantifying resource usage: a non-exhaustive list
includes memory usage analysis based on specific type
systems  <a href="./bibliography.html#celtique-2015-bid22">[65]</a> , <a href="./bibliography.html#celtique-2015-bid23">[47]</a> , linear logic approaches to
implicit computational complexity  <a href="./bibliography.html#celtique-2015-bid24">[49]</a> , cost
model for Java byte code  <a href="./bibliography.html#celtique-2015-bid25">[46]</a>  based on size relation inference,
and WCET computation by abstract interpretation based loop bound
interval analysis techniques  <a href="./bibliography.html#celtique-2015-bid26">[58]</a> .</p>
        <p>We have proposed an original approach for designing
static analyses computing program costs: inspired from a probabilistic
approach  <a href="./bibliography.html#celtique-2015-bid27">[78]</a> , a quantitative operational semantics
for expressing the cost of execution of a program has been
defined. Semantics is seen as a linear operator over a dioid structure
similar to a vector space. The notion of long-run cost is particularly
interesting in the context of embedded software, since it provides an
approximation of the asymptotic behaviour of a program in terms of
computation cost. As for classical static analysis, an abstraction
mechanism allows to effectively compute an over-approximation of the
semntics, both in terms of costs and of accessible
states  <a href="./bibliography.html#celtique-2015-bid28">[54]</a> . An example of cache miss analysis has
been developed within this framework  <a href="./bibliography.html#celtique-2015-bid29">[79]</a> .</p>
        <a name="uid11"/>
        <h4 class="titre4">Certified static analysis</h4>
        <p>In spite of the nice mathematical theory of program analysis (notably
abstract interpretation) and the solid algorithmic
techniques available one problematic issue persists, <i>viz.</i>, the
<i>gap</i> between the analysis that is proved correct on paper and
the analyser that actually runs on the machine. While this gap might
be small for toy languages, it becomes important when it comes to
real-life languages for which the implementation and maintenance of
program analysis tools become a software engineering task.</p>
        <p>A <i>certified static analysis</i> is an analysis whose implementation
has been formally proved correct using a proof assistant. Such
analysis can be developed in a proof assistant like Coq  <a href="./bibliography.html#celtique-2015-bid30">[45]</a> 
by programming the analyser inside the assistant and formally proving
its correctness. The Coq extraction mechanism then allows for
extracting a Caml implementation of the analyser. The feasibility of
this approach has been demonstrated
in <a href="./bibliography.html#celtique-2015-bid31">[6]</a> .</p>
        <p>We also develop this technique through certified reachability analysis over term
rewriting systems.
Term rewriting systems are a very general, simple and convenient
formal model for a large variety of computing systems. For
instance, it is a very simple way to describe deduction systems, functions,
parallel processes or state transition systems where rewriting models
respectively deduction, evaluation, progression or transitions. Furthermore
rewriting can model every combination of them (for instance two
parallel processes running functional programs).</p>
        <p>Depending on the computing system modelled using rewriting,
reachability (and unreachability) permits to achieve some verifications on
the system: respectively prove that a deduction is feasible, prove
that a function call evaluates to a particular value, show that a
process configuration may occur, or that a state is reachable from
the initial state. As a consequence, reachability analysis has several applications in
equational proofs used in the theorem provers or in the proof
assistants as well as in verification where term rewriting systems can
be used to model programs.</p>
        <p>For proving unreachability, i.e. safety properties, we already have some
results based on the over-approximation of the set of reachable
terms  <a href="./bibliography.html#celtique-2015-bid32">[61]</a> , <a href="./bibliography.html#celtique-2015-bid33">[62]</a> . We defined a simple and efficient
algorithm  <a href="./bibliography.html#celtique-2015-bid34">[59]</a> 
for computing exactly the set of reachable terms, when it is regular,
and construct an over-approximation otherwise. This algorithm consists of
a <i>completion</i> of a <i>tree automaton</i>, taking advantage
of the ability of tree automata to finitely represent infinite sets of
reachable terms.</p>
        <p>To certify the corresponding analysis, we have defined a checker
guaranteeing that a tree automaton is a valid fixpoint of the completion
algorithm. This consists in showing that for all term recognised by a tree
automaton all his rewrites are also recognised by the same tree automaton. This
checker has been formally defined in Coq and an efficient Ocaml implementation
has been automatically extracted <a href="./bibliography.html#celtique-2015-bid5">[4]</a> . This checker is now
used to certify all analysis results produced by the regular completion tool as
well as the optimised version of  <a href="./bibliography.html#celtique-2015-bid35">[50]</a> .</p>
      </div>
      <!--FIN du corps du module-->
      <br/>
      <div class="bottomNavigation">
        <div class="tail_aucentre">
          <a href="./uid3.html" accesskey="P"><img style="align:bottom; border:none" alt="previous" src="../static/img/icons/previous_motif.jpg"/> Previous | </a>
          <a href="./uid0.html" accesskey="U"><img style="align:bottom; border:none" alt="up" src="../static/img/icons/up_motif.jpg"/>  Home</a>
          <a href="./uid13.html" accesskey="N"> | Next <img style="align:bottom; border:none" alt="next" src="../static/img/icons/next_motif.jpg"/></a>
        </div>
        <br/>
      </div>
    </div>
  </body>
</html>
