[m-dev.] [reuse] diff: bugfix (again?) for testing for reuse (also check alias)
Nancy Mazur
Nancy.Mazur at cs.kuleuven.ac.be
Sat Oct 14 02:04:19 AEDT 2000
Hi,
===================================================================
Estimated hours taken: 0.2
Reuse is only possible if the datastruct you're deconstructing
is not live and the alias-set is not top (unknown).
The first condition was verified, but the second was not
giving software errors further down.
sr_dead.m:
Fix a bug. When testing for reuse, also check that the alias
is not top (beside the usual testing of the set of live variables).
Index: sr_dead.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/Attic/sr_dead.m,v
retrieving revision 1.1.2.4
diff -u -r1.1.2.4 sr_dead.m
--- sr_dead.m 2000/10/13 09:33:31 1.1.2.4
+++ sr_dead.m 2000/10/13 15:00:55
@@ -209,7 +209,12 @@
sr_live__init(LIVE0),
pa_alias_as__live(LU, LIVE0, Alias0, LIVE),
(
- sr_live__is_live(Var,LIVE)
+ (
+ sr_live__is_live(Var,LIVE)
+ ;
+ pa_alias_as__is_top(Alias0)
+ )
+
->
goal_info_set_reuse(Info0,
choice(deconstruct(no)), Info),
--------------------------------------------------------------------------
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