[m-rev.] diff: make AGC debugging a run-time option

Zoltan Somogyi zs at cs.mu.OZ.AU
Tue Aug 6 13:17:43 AEST 2002


On 02-Aug-2002, Fergus Henderson <fjh at cs.mu.OZ.AU> wrote:
> Make the accurate GC debugging code a run-time option
> rather than a compile-time option.
> 
> The run-time cost of this is very small -- just a few `if' statements
> per garbage collection -- and it is more convenient if agc debugging
> can be enabled by setting MERCURY_OPTIONS rather than by having to
> recompile the Mercury runtime.

Actually, our policy has been for this kind of debugging code to be protected
by *both* a #ifdef and a runtime test. This allows maximum speed for installed
programs while still allowing particular pieces of debugging code to be
switched on and off independently via MERCURY_OPTIONS if you are debugging
something.

I even have a slide to that effect in the 252 lecture notes :-)

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