MT-safe exception and thread library

H.J. Lu
Tue Dec 16 12:25:00 GMT 1997

I am glad to see the Thread-safe EH support in egcs 971215. There is
already configure support for thread in libobjc.a. Can libgcc also use
it also? Basically, configure defines "thread_file", which can be
single, posix, mach, win32, solaris, irix. It shouldn't be hard to
add DCE. libgcc-thr.h can be linked to libgcc-$thread_file.h
so that --enable-threads will enable the Thread-safe EH support
and set the right thread file.

I am not sure if I like the multilibs for the Thread-safe EH support.
That may be a problem for glibc. I'd like to see an option for a
single libgcc.a with the the Thread-safe EH support using weak
symols. I think it should work with gcc on platforms with weak
support. We can use SUPPORTS_WEAK to detect it. It should be
very easy to do.


H.J. Lu (

More information about the Gcc mailing list