This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/11610] _init/_fini do not have proper unwinding information on x86_64 and i686
- From: "ppluzhnikov at google dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: Fri, 26 Oct 2012 21:30:20 +0000
- Subject: [Bug libc/11610] _init/_fini do not have proper unwinding information on x86_64 and i686
- Auto-submitted: auto-generated
- References: <bug-11610-131@http.sourceware.org/bugzilla/>
http://sourceware.org/bugzilla/show_bug.cgi?id=11610
Paul Pluzhnikov <ppluzhnikov at google dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
CC| |ppluzhnikov at google dot
| |com
AssignedTo|drepper.fsp at gmail dot |ppluzhnikov at google dot
|com |com
Summary|_fini does not have proper |_init/_fini do not have
|unwinding information on |proper unwinding
|x86_64 |information on x86_64 and
| |i686
--- Comment #2 from Paul Pluzhnikov <ppluzhnikov at google dot com> 2012-10-26 21:30:20 UTC ---
This has just bit me as well.
The proposed patch no longer works, as initfini.c has been replaced with
sysdeps/x86_64/crti.S and sysdeps/i386/crti.S
The same problem now exists on i686 as well.
This is not just a GDB problem either: if I dlopen a library in a try/catch,
and the library ctor throws, that throw is not caught:
// g++ -g main.cc -ldl
#include <dlfcn.h>
#include <stdio.h>
int main(int argc, char *argv[])
{
try {
void *h = dlopen("./foo.so", RTLD_LAZY);
} catch (...) {
fprintf(stderr, "got exception\n");
return 1;
}
return 0;
}
// g++ -g -fPIC -shared -o foo.so foo.cc
#include <stdio.h>
static void __attribute__((constructor))
foo(void)
{
fprintf(stderr, "in foo\n");
throw 1;
}
./a.out
in foo
terminate called after throwing an instance of 'int'
Aborted
I'll send a new patch to libc-alpha.
--
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.