guile-user
[Top][All Lists]
Advanced

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

Re: Latest guile 1.9 segfault in GC


From: Ludovic Courtès
Subject: Re: Latest guile 1.9 segfault in GC
Date: Wed, 18 Aug 2010 16:12:29 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

Hi,

Cedric Cellier <address@hidden> writes:

> But finaly, thanks to libgc's debug message, I got it.
> Actually, libgc overwrite pthread_create (and pthread_sigmask,
> and a few more) to know when a new thread is started.
> But this overloading is done "softly", ie. by a define in a
> C header file.

[...]

> So, in conclusion : always include libguile.h in the compilation
> units calling pthread functions.

That’s not entirely true, see Section “Thread Support” at
<http://www.hpl.hp.com/personal/Hans_Boehm/gc/gcdescr.html>:

  All  implementations must intercept  thread creation  and a  few other
  thread-specific calls to allow  enumeration of threads and location of
  thread stacks.  This is current  accomplished with # define's  in gc.h
  (really gc_pthread_redirects.h), or  optionally by using ld's function
  call wrapping mechanism under Linux.

Indeed, here’s what I have on GNU/Linux:

  $ objdump -T ~/soft/lib/libgc.so|grep pthread_create
  000000000001ef80 g    DF .text  000000000000028e  Base        
GC_pthread_create
  0000000000000000      DF *UND*  0000000000000000  GLIBC_2.2.5 pthread_create

What OS do you use?

Thanks,
Ludo’.




reply via email to

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