[Top][All Lists]

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

Re: Trouble joining with threads from C

From: Ludovic Courtès
Subject: Re: Trouble joining with threads from C
Date: Mon, 25 Apr 2011 16:49:10 +0200
User-agent: Gnus/5.110015 (No Gnus v0.15) Emacs/23.3 (gnu/linux)


Andy Wingo <address@hidden> writes:

> On Mon 25 Apr 2011 15:53, address@hidden (Ludovic Courtès) writes:


>> Currently they all pass, but ‘test-scm-spawn-thread’ hits a libgc
>> assertion failure (“Duplicate large block deallocation”) once every 5
>> runs or so:
> I guess we disable this one then?
> That code always seemed a little fishy to me:
>   /* Ensure the signal handling thread has been launched, because we might be
>      shutting it down.  */
>   scm_i_ensure_signal_delivery_thread ();
> Perhaps we can avoid spawning a thread in the key destructor.

I apparently found a fix: calling ‘scm_i_ensure_signal_delivery_thread’
in Guile mode.

I *think* the stack of ‘GC_pthread_create’ wasn’t scanned, so the area
pointed to by its variable ‘si’ would be reclaimed before the function
completes, leading to the “duplicate deallocation” error.



reply via email to

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