[m-rev.] for prelim review: fix compiler performance problems on large programs

Zoltan Somogyi zs at cs.mu.OZ.AU
Tue Mar 28 13:18:49 AEDT 2006


On 28-Mar-2006, Julien Fischer <juliensf at cs.mu.OZ.AU> wrote:
> > My laptop still tries to swap itself to death on the full version of
> > training_cars.m (it has only 512 Mb), but the compiler now works fine
> > on a version containing about 20% of its clauses, whereas previously
> > it couldn't compile it at all.
> 
> That should be added as a test case, but whether it it is run will need to be
> controlled by an environment variable, e.g. ENABLE_BIG_TEST_CASES or
> something.  Since, it's causing your laptop to thrash, I'd hate to think about
> what it might do to mine.

I am not sure about the usefulness of a test case that fails by killing the
machine. Remember, the symptom is the usage of lots of virtual memory.
On Linux, if the machine runs out of swap space, it will cause the next
call to malloc to fail, even if the malloc is by a process other than
the one that used up all the memory.

> You should check that my changes to the warnings for obsolete pragmas
> conform to the any new naming scheme as well (I think I committed them
> after you made this diff).

When resolving the conflict I got, I fitted your warn_obsolete into
the new scheme.

> >  :- pred transform_goal(goal::in, prog_substitution::in, hlds_goal::out,
> > -    prog_varset::in, prog_varset::out,
> > +    int::out, prog_varset::in, prog_varset::out,
> >      module_info::in, module_info::out, qual_info::in, qual_info::out,
> >      svar_info::in, svar_info::out, io::di, io::uo) is det.
> 
> Would it be possible to use an equivalence type for the int argument
> here (and below)?

What equivalence type name would be clearer to you?

I followed your other suggestions.

Zoltan.
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list