[m-rev.] for review: dead_pred_elim optimization

Simon Taylor stayl at cs.mu.OZ.AU
Thu Mar 6 23:27:14 AEDT 2003


On 06-Mar-2003, Peter Ross <pro at missioncriticalit.com> wrote:
> On Thu, Mar 06, 2003 at 10:31:13PM +1100, Simon Taylor wrote:
> > On 06-Mar-2003, Peter Ross <pro at missioncriticalit.com> wrote:
> > > How about this?
> > 
> > >                                 predicate_table_insert_2(Table0,
> > >                                                 yes(PredId), PredInfo,
> > >                                                 NeedQual, no, _, Table)
> > 
> > This is still wrong -- you need to pass the `maybe(partial_qualifier_info)'.
> > 
> Hmmmmm.   Need to think about how to solve this some more then.  I am
> guessing what the best approach would be would be to add a new field to
> the predicate_table which caches the values of need_qualifier and
> maybe(partial_qualifier_info).  As I can see no easy way to determine
> the maybe(partial_qualifier_info).  Do you have any other suggestion?

The `maybe(partial_qualifier_info)' field is
`yes(ModuleInfo ^ partial_qualifier_info)' for predicates which
should appear in the name search maps, and `no' for other predicates
(e.g. type specific special preds).

Rather than caching the `maybe(partial_qualifier_info)',
record whether the predicate can be called from user programs
(I'd suggest adding a new marker type for predicates which
can't be called from user programs, which would be added
to the pred_info by the version of predicate_table_insert
which doesn't add the predicate to the name search maps).

Simon.
--------------------------------------------------------------------------
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