[m-dev.] Re: [leslieg at ugrad.unimelb.edu.au: Assertion failure in Mercury compiler]

Fergus Henderson fjh at cs.mu.OZ.AU
Thu Apr 1 18:04:21 AEST 2004

On 31-Mar-2004, Zoltan Somogyi <zs at cs.mu.OZ.AU> wrote:
> On 31-Mar-2004, Fergus Henderson <fjh at cs.mu.OZ.AU> wrote:
> > Are you working on this?
> > 
> > I would have a look at it myself, except that legally I can't fix it until
> > I get a non-Galois computer.
> Here is the minimized test case, and the diagnosis. I see three possible fixes.
> One is to eliminate the sanity check, as shown in the diff to det_analysis.m
> below; this yields a reasonable error message instead of a compiler abort.

That would be OK.

I think the reason that this problem arose is that the sanity check
makes sense for switches and disjunctions, but not for if-then-else.
So perhaps we could leave det_switch_maxsoln and det_disj_maxsoln as
they are, and add det_ifthenelse_maxsoln which is like det_switch_maxsoln
but without the sanity check.

> The second is to change the rules of determinism analysis so that if
> a goal is in a first_solution context, then we coerce its detism from
> fail and semidet to cc_nondet and from erroneous and det to cc_multi;
> I don't think this works because we lose info about erroneous.
> The third is to add cc_ versions of not only nondet and multi but also
> of failure, semidet, erroneous and det.

Neither of those sounds very appealing.

I could happily live with either your solution of just removing the
sanity check or the other alternative that I mentioned above.

Fergus Henderson                    |  "I have always known that the pursuit
                                    |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.
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