[Gc] GC7.0 on Leopard (MacOS X 10.5)... again Re: Gc Digest, Vol 50, Issue 6

Manuel.Serrano at sophia.inria.fr Manuel.Serrano at sophia.inria.fr
Thu Jan 10 05:31:54 PST 2008


Hello Hans,

> It would be interesting to know what happens with this version compiled with both --enable-parallel-mark and --enable-gc-assertions.  The parallel marking code has a reasonable number of assertions that might catch any weirdness.
> 
> The version everyone is using is similar to the CVS version?  People are presumably testing on dual core machines?  When it hangs there is only a single thread around?
Yes. The whole in just main() { GC_INIT(); }. There is thread involved here...

> I believe this was intended to work, and I don't immediately see why it doesn't.  But I suspect some of the testing may have happened on single-core machines, where --enable-parallel-mark isn't that interesting.  In any case, it would be good to understand why this is breaking now.

Enabling assertions does not help.

-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----
$ ./configure --enable-parallel-mark --enable-gc-assertions --prefix=$HOME/bgl/gc
$ make
$ make install
$ cat > foo.c <<EOF
#include <gc.h>

int main() {
GC_INIT();
}
EOF
$ gcc foo.c -lgc
$ gdb a.out
(gdb) run
Starting program: /Users/serrano/bgl/gc/gc-7.0/a.out 
Reading symbols for shared libraries +++. done
^C
Program received signal SIGINT, Interrupt.
0xffff0295 in __spin_lock ()
(gdb) bt
#0  0xffff0295 in __spin_lock ()
#1  0x926ba539 in pthread_mutex_unlock ()
#2  0x0004df50 in GC_release_mark_lock () at pthread_support.c:1422
#3  0x0004e6c4 in GC_stop_world () at darwin_stop_world.c:517
#4  0x0003ac34 in GC_stopped_mark (stop_func=0x3a980 <GC_never_stop_func>) at alloc.c:454
#5  0x0003b7de in GC_try_to_collect_inner (stop_func=0x3a980 <GC_never_stop_func>) at alloc.c:348
#6  0x00048152 in GC_init_inner () at misc.c:742
#7  0x00048297 in GC_init () at misc.c:428
#8  0x00001ffd in main () at foo.c:4
(gdb) c
Continuing.
^C
Program received signal SIGINT, Interrupt.
0xffff0292 in __spin_lock ()
(gdb) bt
#0  0xffff0292 in __spin_lock ()
#1  0x00000000 in ?? ()
(gdb) c
Continuing.
^C
Program received signal SIGINT, Interrupt.
0xffff0292 in __spin_lock ()
(gdb) bt
#0  0xffff0292 in __spin_lock ()
#1  0x00000000 in ?? ()
(gdb) c
Continuing.
^C
Program received signal SIGINT, Interrupt.
0xffff0292 in __spin_lock ()
(gdb) bt
#0  0xffff0292 in __spin_lock ()
#1  0x00000000 in ?? ()
(gdb) c
Continuing.
^C
Program received signal SIGINT, Interrupt.
0xffff0292 in __spin_lock ()
(gdb) bt
#0  0xffff0292 in __spin_lock ()
#1  0x00000000 in ?? ()
(gdb) The program is running.  Exit anyway? (y or n) y
-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----


-- 
Manuel


More information about the Gc mailing list