re: Abstract Interpretation Query

P.T. Breuer <ptb@eng.cam.ac.uk>
Mon, 14 Sep 1992 11:58:11 GMT

          From comp.compilers

Related articles
Re: Abstract Interpretation Query vugranam@pike.ee.mcgill.ca (1992-09-05)
Re: Abstract Interpretation Query masticol@cadenza.rutgers.edu (1992-09-06)
re: Abstract Interpretation Query ptb@eng.cam.ac.uk (P.T. Breuer) (1992-09-14)
| List of all articles for this month |

Newsgroups: comp.compilers
From: P.T. Breuer <ptb@eng.cam.ac.uk>
Organization: Compilers Central
Date: Mon, 14 Sep 1992 11:58:11 GMT
Keywords: functional, logic
References: 92-09-044 92-09-041

masticol@cadenza.rutgers.edu (Steve Masticola) writes:
>vugranam@pike.ee.mcgill.ca (Vugranam Chakravarthy Sreedhar) writes:
>>AI, although nice, is expensive in terms of time and space. I doubt if the
>>concept is being used in any production compilers.
>
>I don't believe that this generalization holds. As I understand it,
>abstract interpretation (please forgive me if I don't use the prejudicial
>term "AI" :-) is a theoretical framework for connecting a program to an
>abstraction of that program, or for generating the abstraction given some
>particular information you'd like to estimate. The abstraction is
>supposed to have properties that make it nice for data flow analysis
>(monotonic edge functions, etc.)
>
>Standard problems like reaching definitions can be cast in an abstract
>interpretation framework, and it costs nothing in terms of analysis
>time to do so.
>
> If anyone knows differently, please jump in...


I can understand hardly a word of the above, and I have written at least
one paper on A-I, and probably four (it's hard to tell what is and what
ain't A-I). If anyone else feels the same, here's the 2c I owe. I may not
actually know what it is, but I know what I think it is:


I believe A-I is just the interpretation of a program text as something
other than a program. As a type, for example. Or as a control flow graph.
Fin. That's the end of the mystery.


There are especially nice consequences for the proper treatment of
recursion if the following square diagram appears anywhere:


        thing -AI---> other thing
          | |
          | |
          | |
          V -AI---> > V
      one more yet another thing
      thing




The `'>' (in some sense) at the bottom is important. For example, I have
often used:


        seq of ---AI--> seq of
        programs numbers
        | |
        | limit | limit
        V V
        program ---AI-> > number


and this diagram tells me that my A-I allows me to take limits of numbers
instead of solving for limits of programs. What I get is a lower bound for
the number that I would have got as the A-I of the limiting program.


In my case, the number was associated with a nontermination estimate, and
the sequence of programs was a loop expanded out various numbers of times.


To make the diagrams `make sense', one has to have the right settings
(computational domains, categories, or whatever you prefer as the semantic
substrate) and the right conditions within that setting (here that the seq
is directed and increasing in a limit-complete structure - boy, wouldn't
you just love infinite programs to be meaningless?) But I don't see any
need for jargon or obfuscation! Cognoscenti will see from this that I was
using the lest fixed point semantics for ptograms, and therefore must have
been dealing with a lazy language, but that's by and by. People who use
strict semantics wil talk about `<' where I have `>', and be trying to
prove finite termination, not infinite extension (I was interested in the
program that never stops, because it never hangs).


Now will someone please explain to me what all this has to do with
compilation? Static analysis, I can understand the connection with.
Compilers no. Optimisation, yes.


Peter
-----------------------------
Peter T. Breuer
Oxford University Computing Laboratory <ptb@uk.ac.ox.comlab>
Cambridge University Engineering Department <ptb@uk.ac.cam.eng>
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.