This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [PATCH] Next attempt on the gcc3 vs glibc2.2.4 patch


On Tue, Aug 07, 2001 at 08:56:52AM -0700, H . J . Lu wrote:
> On Mon, Aug 06, 2001 at 04:41:36PM +0200, Jakub Jelinek wrote:
> > Unlike the previous one, it does not care which gcc was used to build GLIBC
> > - everywhere but on Linux/IA-64 it exports the new GCC 3.0 unwind
> > register/deregister routines plus _Unwind_Find_FDE (using gcc's
> > unwind-dw2-fde.c with just a few changes for glibc), plus on platforms which
> > used to export __frame_state_for from glibc it does so. __frame_state_for
> > implementation in GLIBC means first try to dlopen libgcc_s.so.1 if it exists
> > and call __frame_state_for in there, if it does not exist, it has a
> > fallback, so that GLIBC 2.2.4 does not require GCC 3.0.1+'s libgcc to be
> > installed.
> 
> One more comment, I don't know what you will gain by dlopening
> libgcc_s.so.1, given that those functions are also available in
> libc.so. You can't say which ones are newer at the run-time, those
> in libc.so or those in libgcc_s.so.1. I believe we should do a
> run-time/link-time version check of those functions instead.

The run-time/link-time version check is IMHO not needed, once libgcc_s will
need a different _Unwind_Find_FDE it can use different symbol version or
even different name (but as Richard said, it is unlikely to happen soon).

The in-glibc fallback_frame_state_for is there for glibc built with gcc
< 3.0.1 (ie. on systems which don't necessarily have libgcc_s.so.1).
If we agree that Linux which has glibc compiled with gcc 3.0.1+ needs
libgcc_s.so.1 installed (very likely, otherwise it would mean one just could
not use any C++ 3.0.1+ compiled programs), then fallback_frame_state_for can
be compiled for gcc < 3.0.1 only.
The dlopen call is needed there so that gcc upgrade can be done
independently from glibc upgrade. There is no dilema about which
__frame_state_for implementation is newer - always libgcc_s.so.1 has to have
the newest one used on the system. If this was not true, new C++ ABI
programs could not throw exceptions through such code (note that
__frame_state_for@@GLIBC_2.0 in libgcc_s.so.1 uses the same code as does the
new C++ _Unwind_* exception code which is not exported from GLIBC).

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]