caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Florian Weimer <fw@deneb.enyo.de>
To: Xavier Rival <Xavier.Rival@ens.fr>
Cc: Gabriel Kerneis <gabriel@kerneis.info>,  caml-list@inria.fr
Subject: Re: [Caml-list] [ocaml-jobs] Developper position: designing a C front-end in OCaml
Date: Tue, 15 Oct 2013 20:13:57 +0200	[thread overview]
Message-ID: <87a9ia8kre.fsf@mid.deneb.enyo.de> (raw)
In-Reply-To: <alpine.DEB.2.02.1310151442260.20768@ssh-di.ens.fr> (Xavier Rival's message of "Tue, 15 Oct 2013 14:48:49 +0200 (CEST)")

* Xavier Rival:

> I have used CIL in another project in the past. My experience is that
> it is a great front-end for program transformation. It is less adapted
> to static analysis though, as it does a lot of syntactic
> transformations, causing part of the structure of the code to be
> lost. For instance, it transforms loops into a while(1) form, with
> break statements. This design choice does not help static analyzers,
> and may require recalculating information that was lost in the early
> phases.

Clang mirrors the source pretty closely in its AST, so a Zephyr ASDL
model and serializer for that might be the way to go.  The advantage
would be that you get not just C, but also many popular extensions,
broadening the set of potential inputs for your analysis tools.

GCC is another option (using a similar approach), but it's trees are a
little less close to the source code.

  parent reply	other threads:[~2013-10-15 18:14 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-15 12:31 [Caml-list] " Xavier Rival
2013-10-15 12:41 ` Gabriel Kerneis
2013-10-15 12:48   ` [Caml-list] [ocaml-jobs] " Xavier Rival
2013-10-15 12:52     ` Julia Lawall
2013-10-15 13:02     ` David MENTRE
2013-10-15 13:22       ` Gabriel Kerneis
2013-10-15 18:29         ` Dmitry Grebeniuk
2013-10-15 21:36           ` Gabriel Kerneis
2013-10-16  0:12             ` Wojciech Meyer
2013-10-16  6:12         ` David MENTRE
2013-10-15 18:13     ` Florian Weimer [this message]
2013-10-15 14:06 ` [Caml-list] " Basile Starynkevitch
2013-10-15 15:36   ` Wojciech Meyer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a9ia8kre.fsf@mid.deneb.enyo.de \
    --to=fw@deneb.enyo.de \
    --cc=Xavier.Rival@ens.fr \
    --cc=caml-list@inria.fr \
    --cc=gabriel@kerneis.info \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).