gcl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Gcl-devel] 2.6.2


From: Mike Thomas
Subject: RE: [Gcl-devel] 2.6.2
Date: Thu, 3 Jun 2004 10:36:44 +1000

Hi Camm/Vadim.

Sorry about the delays, but I'm getting further away from debugging GCL this
week rather than closer, so as both of you are sharpening your tools I am
passing on all I have discovered since Saturday night through testing and
reading.


IGNORE-ERRORS

The status on Saturday evening was that I reported debug and normal CVS
optimisation builds of GCL which eliminated the Maxima ignore-erros bug,
using CVS Maxima.

Unfortunately, changing the top optimisation to -O on that patched system
led to a failure.

That result was reinforced by repeating the experiment on another machine
using the Maxima source bundle of 20040424 and using those same patches,
under which conditions the bug occurs on all optimisations tested EXCEPT on
CVS default optimsation (-O3 -fomit-frame-pointers).


UNIVERSE.LSP

The best optimisation I have gotten so far without triggering this bug is
"-O2".  Haven't tried "-O3" (ie also without -fomit-frame-pointer) yet.


GCL_SETF.LSP BUILD FAILURE

As a result of these experiments I have now found that this happens both
with gcc 3.4.0 on default optimisation (-O3 -fomit-fram-pointers), and also
gcc 3.3.1 with "-g -O2 -fomit-fram-pointers".  (It does not happen on 3.3.1
with "-O3 -fomit-fram-pointers", or "-g -O3 -fomit-fram-pointers", or "-O",
or just "-g").


MINGW SETJMP NOTE

Yesterday on the Chicken Scheme mailing list the following message appeared
from a guy called Jonah Beckford which may be relevant:

"The nsample executable was crashing on my MinGW, giving an "Invalid memory
access" error when calling longjmp(C_restart, 1) from C_reclaim.  I think
the problem has been there for a significant time.

I decided to see if it was a problem with setjmp/longjmp, or if it was
something else.  I put in some #ifdefs, replacing the 3 setjmp/longjmp calls
with try/catch/throw (C++).

For all tests, I compiled runtime.c (which has some typecasts and C++
reserved words renamed to get it in C++ conformance) with the g++ compiler,
changed the linker ($CCLD) to g++, and let everything else be compiled by
the default CC (gcc).  The common gcc/g++ optimizing options were -O3
-fno-strict-aliasing.

Speed (ms) for fully-optimized NSAMPLE with -:s that gave best nursery size
---------------------------------------------------------------------------
setjmp/longjump without -fomit-frame-pointer - 380, 380, 386, 390, 386
setjmp/longjump with -fomit-frame-pointer    - always crashes
try/catch/throw with -fomit-frame-pointer    - 416, 433, 450, 420, 413

So we can just take out the -fomit-frame-pointer option on MinGW; it might
be a good idea though to use the above technique if similar problems exists
on other platforms."

Google turned up this:

http://www.caddr.com/macho/archives/iolanguage/2004-3/1951.html

and referred to in that message:

http://www-2.cs.cmu.edu/~mihaib/articole/threads/threads.c

Unfortunately I am ignorant of setjmp/longjmp at the moment so have no way
of using this information in the context of GCL.


I can't say when I will be able to look further into this but it may be as
long as a week.

Cheers

Mike Thomas.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]