[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
user/1430: gcc has problems with C++ and exceptions
>Number: 1430
>Category: user
>Synopsis: gcc has problems with C++ and exceptions
>Confidential: no
>Severity: serious
>Priority: low
>Responsible: bugs
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Oct 3 08:10:01 MDT 2000
>Last-Modified:
>Originator: Marc Espie
>Organization:
net
>Release:
>Environment:
System : OpenBSD 2.7
Architecture: OpenBSD.i386
Machine : i386
>Description:
As of gcc 2.95.x, g++ has some problems optimizing files that use
exceptions. This is due to setjump/longjump exceptions creating highly
non-local jumps that tend to force the whole of the file through
optimization
>How-To-Repeat:
Compile kde-1.94. Observe g++ memory usage going thru the rooftop and
beyond on a few files (stopped it at 300M).
Observed on a 386, likely to occur elsewhere.
>Fix:
Add primitives needed to support dwarf2 exceptions (known) and activate
exceptions through dwarf2 unwinds. As long as C++ shared libraries are
linked with gcc -shared, collect2 will add the required
register_frame_info/deregister_frame_info.
The intermediate code produced has much better locality, and doesn't bug
g++ as much.
make sure the code works correctly (currently, kde2 with dwarf2 unwinds
hangs in exit()), test release, activate.
Alternately, switch to elf, and native dwarf2 unwinds should come
naturally.
>Audit-Trail:
>Unformatted: