[m-dev.] intermod optimization framework

Peter Ross peter.ross at miscrit.be
Thu Mar 29 22:47:25 AEST 2001


On Thu, Mar 29, 2001 at 10:37:46PM +1000, Peter Schachte wrote:
> > Predicate eval:interpret calls renderer:render, the aliasing for this is
> > top because we haven't calculated the aliases for renderer:render.
> > Now we analyse renderer:renderer which calls eval:interpret and the
> > aliasing is top because of the call to eval:interpret.  Obviously no
> > matter how many times we iterate over this process we will always have a
> > top.
> 
> It sounds like you're trying to find the greatest fixpoint, when the least
> fixpoint is much more useful.  To find the least fixpoint, you have to
> approximate everything as bottom initially and iterate until you reach a
> fixpoint.  The advantage of starting out at top is that you can stop any
> time you like and you'll have a safe approximation.  The disadvantage is
> that you wind up with the greatest fixpoint.
> 
Inside a module we use the least fixpoint, however for safety reasons
(the fact that we want a safe approximation at every stage) we cannot to
do this with the current implementation when optimizing across module
boundries.  It would be nice if the optimization framework explicitly
supported both methods.  For instance use the greatest fix point while
iterating towards the least fixpoint and then when safe switch to the
least fixpoint.

Here is an idea for a summer student, adapt the Mercury compiler to spit
out a new source tree where all the strongly connected modules have been
collapsed into one module.
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list