problems
Thomas Charles CONWAY
conway at cs.mu.OZ.AU
Tue Sep 22 09:13:41 AEST 1998
Tomas By, you write:
> | Mercury runtime: memory zone detstack#0 overflowed
> | PC at signal: -277789040 (ef714690)
> | You can get a stack dump by using grade debug
>
> The machine is a Sun with 256MB running Solaris 2.6.
>
> Since I can't add any printing anywhere I don't quite know where
> to start. What kind of information is it that there was too much
> of? (Call frames? / local data structures? / both?) Do you have
> any suggestions for how to approach this?
My first guess is that you have an infinite loop somewhere.
What you've run out of is storage to call frames for det and
semidet procedures.
You could try enlarging the det-stack with the MERCURY_OPTIONS
environment variable (see the user guide for details). If you
really do have an infinite loop, then this won't help, but if
you've just been unlucky and have run out of det-stack even
though your program is "terminating", then this may help.
If the latter is the case, you may be able to make your code
more tail-recursive by introducing accumulators and so forth.
(Remember that currently, even if only unifications happen after
the last call, it won't be amenable to last-call optimization unlike
Prolog.)
Thomas
--
Thomas Conway <conway at cs.mu.oz.au>
Nail here [] for new monitor. )O+
More information about the users
mailing list