Problems with exception handling in glibc and gcc.

H . J . Lu hjl@lucon.org
Tue Jul 4 18:32:00 GMT 2000


On Tue, Jul 04, 2000 at 05:56:09PM -0700, Ulrich Drepper wrote:
> "H . J . Lu" <hjl@lucon.org> writes:
> 
> > The problem is there should be only one copy of the exception funtions
> > used in the main executable and all DSOs. If we decide that glibc 
> > will never use the exception, things may be a little easier.
> 
> This is actually something we want to use in glibc.  The exception
> handling mechanism is currently poorly (means not at all) integrated
> with the thread cleanup handling.  Also, we implement for the cleanup
> handling something similar to exception handling.
> 
> Therefore the idea is to have exceptions in C (compatible with the C++
> exceptions) and use them in the thread cleanup handling.
> 

It sounds like we should explore the libgcc.so option. Due to the
dependency of libc.so on libgcc.so, I suggest we build libgcc.so
from libgcc.a in gcc while building glibc. libgcc.so will be the part
of glibc and glibc will decide where to install libgcc.so. To do that,
we need a well defined libgcc ABI. I think it is doable. I can
investigate a little further if everyone thinks is a good idea.



H.J.


More information about the Gcc-bugs mailing list