This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/64535] Emergency buffer for exception allocation too small
- From: "rguenther at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 27 Jan 2015 12:09:16 +0000
- Subject: [Bug libstdc++/64535] Emergency buffer for exception allocation too small
- Auto-submitted: auto-generated
- References: <bug-64535-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64535
--- Comment #20 from rguenther at suse dot de <rguenther at suse dot de> ---
On Tue, 27 Jan 2015, jakub at gcc dot gnu.org wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64535
>
> Jakub Jelinek <jakub at gcc dot gnu.org> changed:
>
> What |Removed |Added
> ----------------------------------------------------------------------------
> CC| |mark at gcc dot gnu.org
>
> --- Comment #19 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
> I think a destructor is too risky here.
> Can't you just register with valgrind a pointer known not to be freed at exit?
> Would be nice to have something like __libc_freeres for libstdc++ too, that
> valgrind/mtrace/LeakSanitizer could invoke.
> I'm afraid tons of programs just do busy work in various threads until some
> thread exits the whole app, and your change could break it.
It indeed would free memory of in-flight exceptions. Which means that
process termination in OOM situations might become interesting?
OTOH we now leak with dlopen/dlclose of libstdc++.so (just consider
doing that multiple times).