[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bdw-gc includes in libguile.h
From: |
Ludovic Courtès |
Subject: |
Re: bdw-gc includes in libguile.h |
Date: |
Mon, 28 Mar 2011 22:40:47 +0200 |
User-agent: |
Gnus/5.110013 (No Gnus v0.13) Emacs/23.3 (gnu/linux) |
Hello,
Andy Wingo <address@hidden> writes:
> On Mon 28 Mar 2011 21:22, address@hidden (Ludovic Courtès) writes:
>
>> The problem is that libgc ends up being initialized behind our back upon
>> the first libgc-redirected ‘pthread_create’ call.
>
> Indeed.
>
>> Hans Boehm suggested [0] two solutions:
>>
>> 1. Disable pthread redirects and instead register threads explicitly
>> (in ‘scm_with_guile’).
>>
>> 2. Initialize libgc in a constructor.
>>
>> I was leaning towards (2), because this way we’d be in control, and in
>> particular we’d have GC_all_interior_pointers = 0. It would only work
>> on GCC/ELF platforms, and only if libgc wasn’t already initialized (for
>> instance if Guile is used in an application that already uses libgc on
>> its own)—but that really covers 90% of our use cases.
>>
>> I understand you’re in favor of (1). This would give the same behavior
>> as in 1.8[*] while being less hackish than (2). However, it’s only
>> applicable to 2.1.
>
> Why is this only applicable to 2.1 ?
I was thinking it’d break the ABI, but maybe not?
Ludo’.
- bdw-gc includes in libguile.h, Andy Wingo, 2011/03/25
- Re: bdw-gc includes in libguile.h, Andy Wingo, 2011/03/25
- Re: bdw-gc includes in libguile.h, Ludovic Courtès, 2011/03/25
- Re: bdw-gc includes in libguile.h, Andy Wingo, 2011/03/25
- Re: bdw-gc includes in libguile.h, Ludovic Courtès, 2011/03/27
- Re: bdw-gc includes in libguile.h, Andy Wingo, 2011/03/28
- Re: bdw-gc includes in libguile.h, Ludovic Courtès, 2011/03/28
- Re: bdw-gc includes in libguile.h, Andy Wingo, 2011/03/28
- Re: bdw-gc includes in libguile.h,
Ludovic Courtès <=
- Re: bdw-gc includes in libguile.h, Andy Wingo, 2011/03/29
- Re: bdw-gc includes in libguile.h, Ludovic Courtès, 2011/03/30
- Re: bdw-gc includes in libguile.h, Andy Wingo, 2011/03/30