This is the mail archive of the
mailing list for the GCC project.
Re: C++ demangler fix
- From: Paolo Carlini <paolo dot carlini at oracle dot com>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org, DJ Delorie <dj at redhat dot com>, Ian Lance Taylor <ian at airs dot com>
- Date: Tue, 10 Sep 2013 20:36:02 +0200
- Subject: Re: C++ demangler fix
- Authentication-results: sourceware.org; auth=none
- References: <20130904142943 dot GA18972 at blade dot nx> <20130910153400 dot GC1817 at tucnak dot redhat dot com>
On 09/10/2013 05:34 PM, Jakub Jelinek wrote:
This is now bootstrap/58386. IMHO we should for the time being revert
the patch, the required modifications don't seem trivial.
On Wed, Sep 04, 2013 at 03:29:43PM +0100, Gary Benson wrote:
I've added the result to the demangler test suite, but I know of
no way to check the validity of the demangled symbol other than by
inspection (and I am no expert here!) If anybody knows a way to
check this then please let me know! Otherwise, I hope this
not-really-checked demangled version is acceptable.
Unfortunately this patch broke GCC bootstrap.
cp-demangle.c isn't used just in libiberty, where using hashtab,
xcalloc, XNEW etc. is fine, but also in libsupc++/libstdc++, where
none of that is fine. That is why cp-demangle.c only uses e.g. realloc,
checks for allocation failures and propagates those to the caller
if they happen (see allocation_failure field). hashtab.o isn't linked
into libstdc++ nor libsupc++, and the question is if we really do want to
link all the hashtable code into libstdc++.
How many hash table entries are there typically? Is a hashtable required?