RE: extensible compilers

"Zhukov, Victor" <vic@paragraph.com>
30 Mar 1998 21:49:58 -0500

          From comp.compilers

Related articles
extensible compilers mtrofimov@glas.apc.org (1998-03-22)
Re: extensible compilers ndc@alum.mit.edu (N. D. Culver) (1998-03-24)
RE: extensible compilers vic@paragraph.com (Zhukov, Victor) (1998-03-30)
Re: extensible compilers ndc@alum.mit.edu (N. D. Culver) (1998-04-03)
| List of all articles for this month |

From: "Zhukov, Victor" <vic@paragraph.com>
Newsgroups: comp.compilers
Date: 30 Mar 1998 21:49:58 -0500
Organization: Compilers Central
References: 98-03-212 98-03-215
Keywords: design, optimize

> N. D. Culver ndc@alum.mit.edu wrote
> I think that the way to do an extensible compiler/language is as
> follows:
> ASSUMPTION: a complete AST is retained after the parse and is
> processed by:
info about generalized AST and parser engine skipped.


The problem with extensible languages is that they are giving us more
power to express domain-specific idioms while on the other side
making program sources much less understandable and manageable.
    Also, there are difficulties with pre-coding all possible 'semantic
categories' into the language, which is supposed to handle not only
a priori cases.
    There is alternative approach, which tries to avoid syntax problem
by replacing parseable source codes with persistent AST-like structure
and providing alternative editing means (claimed to be even more
convenient than source code editing).
    Semantics of the nodes (called intentions) is given in terms of rewriting
rules transforming an intention tree to fixed intermediate representation,
which is directly understood by code generator. Rules themselves are
expressed in the intention nodes, so you can build new node type by
giving description of how the node should be rewritten.
    These rules can do a lot of domain specific optimization during rewriting.
Rules also can check types and enforce programming discipline,
serving as static checkers.
    So called Intentional Programming approach is being developed at
Microsoft Research. It is quite ambitious project, aimed at solving problems
with programming languages in general by replacing them with new idiom
set. They claim to have working, self-compiling system of this structure.


More detailed info you can get from MS Research site at:
http://www.research.microsoft.com/research/ip/


Disclaimer: I am not connected with Microsoft in any ways (except
using their products), I just like the idea.


Victor Zhukov,
Senior Researcher.
Parallel Graphics.
--


Post a followup to this message

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