RFC: "Generic" gthread model

Jason Merrill jason_merrill@redhat.com
Wed Aug 22 06:15:00 GMT 2001


>>>>> "Jonathan" == Jonathan Larmour <jlarmour@redhat.com> writes:

> Jason Merrill wrote:
>> 
>> >>>>> "Jonathan" == Jonathan Larmour <jlarmour@redhat.com> writes:
>> 
>> > I've implemented this now in the attached patch. But after playing with it,
>> > I have a serious reservation: our support for #pragma weak is woefully
>> > poor.
>> 
>> You can use __attribute__ ((weak)) instead.

> For a weak reference rather than weak definition? GCC didn't use to do
> that, but I'll assume you're right and try it :).

Looking more closely at the source, it seems that it works for weak
references, but only on targets that also support #pragma weak.  This seems
rather bogus; instances of #ifdef HANDLE_PRAGMA_WEAK in varasm.c should be
changed to test SUPPORTS_WEAK instead.

Jason



More information about the Gcc-patches mailing list