[Gc] Problem pthread_atfork
Manuel.Serrano at inria.fr
Manuel.Serrano at inria.fr
Sun Mar 25 23:33:08 PST 2012
Hi Ivan,
I think we are facing a problem with the pthread_atfork support of the
collector. This week-end, we have found the following problem with
the latest Bigloo version that runs a patched version of the GC 7.3alpha1:
-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----
make[2]: Entering directory
`/home/liew/Downloads/bigloo3.8a/api/pthread/recette'
/home/liew/Downloads/bigloo3.8a/bin/bigloo -c -call/cc -O3
-fcfa-arithmetic -q recette.scm -o recette.o
/home/liew/Downloads/bigloo3.8a/bin/bigloo -O3 -fcfa-arithmetic -q
recette.o -o recette
/usr/bin/ld: recette: hidden symbol `pthread_atfork' in
/usr/lib/i386-linux-gnu/libpthread_nonshared.a(pthread_atfork.oS) is
referenced by DSO
/usr/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status
make[2]: *** [recette] Error 1
make[2]: Leaving directory `/home/liew/Downloads/bigloo3.8a/api/pthread/recette'
make[1]: *** [c-test] Error 1
make[1]: Leaving directory `/home/liew/Downloads/bigloo3.8a'
make: *** [test] Error 2
-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----
Bigloo does not use pthread_atfork directly. This function is only used
in the GC code, in the files pthread_support.c and win32_threads.c.
This issue clearly relates to the issues mentioned in the Blog found at:
http://ryanarn.blogspot.com/
However, contrary to what's stated in the Blog, the problem cannot be solved
by simply mentioning -lpthread after the object files. Bigloo actually
links with:
gcc recette.o -o recette -Wpointer-arith -Wswitch -Wtrigraphs -DBGL_BOOTCONFIG -O3 -Wpointer-arith -Wswitch -Wtrigraphs -DBGL_BOOTCONFIG -s -L. -L/users/serrano/prgm/project/bigloo/lib/3.8a -lbigloopthread_s-3.8a -lbigloo_s-3.8a -lbigloogc_fth-3.8a -ldl -lm -lpcre -lgmp -ldl -lbigloopthread_s-3.8a -lpthread
Right now, I'm not able to reproduce that problem. Apparently, this is a
very recent problem. All the Linux boxes I have tried worked
correctly. Hence, it's difficult for me to understand what's really
going on and how to solve the problem. However, I imagine, this is
something that should be fixed in the collector.
It's not clear to me what would the consequences of disable the
pthread_atfor support. Could you enlighten me? Do you think that it could
be a possible option to disable this support while we have not understood
how this problem should be fixed?
Thanks in advance for your help.
--
Manuel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 489 bytes
Desc: not available
Url : http://napali.hpl.hp.com/pipermail/gc/attachments/20120326/50c47fad/attachment.pgp
More information about the Gc
mailing list