[m-dev.] Freeze the compiler

Mark Anthony BROWN dougl at cs.mu.OZ.AU
Tue Jan 30 02:35:57 AEDT 2001


Fergus Henderson writes:
> Neither of these bugs have been fixed yet.
> 
> On 10-Nov-2000, Fergus Henderson <fjh at cs.mu.OZ.AU> wrote:
> > 
> > One thing we should do for the next release is to make sure that it
> > passes its test cases on all of our test systems.
> ...
> > 2. debugger/queens
> > 
> > The goal path for `stack -d' doesn't match.
> > This is probably caused by `-O1 --opt-space',
> > and so is really a problem in the test case.
> > 
> > the differences are:
> > *** queens.exp  Sat Oct 14 01:33:22 2000
> > --- queens.out  Thu Nov  9 21:48:10 2000
> > ***************
> > *** 123,131 ****
> >      5       pred queens:main/2-0 (cc_multi) (queens.m:15)
> >   mdb> stack -d
> >      0      20      10    6 pred queens:qperm/2-0 (nondet) (queens.m:45) (empty)
> > !    1      15       8    5 pred queens:qperm/2-0 (nondet) (queens.m:49) s1;c2;
> > !    2      10       6    4 pred queens:qperm/2-0 (nondet) (queens.m:49) s1;c2;
> > !    3       5       4    3 pred queens:qperm/2-0 (nondet) (queens.m:49) s1;c2;
> >      4       4       3    2 pred queens:queen/2-0 (nondet) (queens.m:42) c2;
> >      5       1       1    1 pred queens:main/2-0 (cc_multi) (queens.m:15) ?;c2;q!;
> >   mdb> print *
> > --- 123,131 ----
> >      5       pred queens:main/2-0 (cc_multi) (queens.m:15)
> >   mdb> stack -d
> >      0      20      10    6 pred queens:qperm/2-0 (nondet) (queens.m:45) (empty)
> > !    1      15       8    5 pred queens:qperm/2-0 (nondet) (queens.m:49) s1;c4;
> > !    2      10       6    4 pred queens:qperm/2-0 (nondet) (queens.m:49) s1;c4;
> > !    3       5       4    3 pred queens:qperm/2-0 (nondet) (queens.m:49) s1;c4;
> >      4       4       3    2 pred queens:queen/2-0 (nondet) (queens.m:42) c2;
> >      5       1       1    1 pred queens:main/2-0 (cc_multi) (queens.m:15) ?;c2;q!;
> > 
> > Someone should verify that both of these outputs are valid.
> > If so, the test case should be modified so that it doesn't fail.
> > 

I'll commit this on both the main and release branches.

Cheers,
Mark.

Estimated hours taken: 0.5

This test was failing at optimization levels -O0 and -O1 because some
unifications were not being simplified away, which led to subsequent goals
having a different goal path to what was expected.

tests/debugger/queens.m:
	Write the unifications in a way which is not affected by
	optimization level.

Index: tests/debugger/queens.m
===================================================================
RCS file: /home/mercury1/repository/tests/debugger/queens.m,v
retrieving revision 1.3
diff -u -r1.3 queens.m
--- tests/debugger/queens.m	1999/04/16 01:13:01	1.3
+++ tests/debugger/queens.m	2001/01/29 14:44:40
@@ -43,8 +43,8 @@
 	safe(Out).
 
 qperm([], []).
-qperm([X|Y], K) :-
-	qdelete(U, [X|Y], Z),
+qperm(L, K) :-
+	L = [_ | _], qdelete(U, L, Z),
 	K = [U|V],
 	qperm(Z, V).
 
--------------------------------------------------------------------------
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