From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16547 invoked by alias); 3 Dec 2003 16:58:06 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 16536 invoked from network); 3 Dec 2003 16:58:05 -0000 Received: from unknown (HELO yosemite.airs.com) (209.128.65.135) by sources.redhat.com with SMTP; 3 Dec 2003 16:58:05 -0000 Received: (qmail 3969 invoked by uid 10); 3 Dec 2003 16:58:03 -0000 Received: (qmail 2051 invoked by uid 500); 3 Dec 2003 16:57:56 -0000 From: Ian Lance Taylor To: mec.gnu@mindspring.com (Michael Elizabeth Chastain) Cc: ac131313@redhat.com, drow@mvista.com, gdb@sources.redhat.com, wcohen@redhat.com Subject: Re: Slow handling of C++ symbol names References: <20031203164734.201124B35B@berman.michael-chastain.com> Date: Wed, 03 Dec 2003 16:58:00 -0000 In-Reply-To: <20031203164734.201124B35B@berman.michael-chastain.com> Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2003-12/txt/msg00043.txt.bz2 mec.gnu@mindspring.com (Michael Elizabeth Chastain) writes: > So far I've found one type of difference that looks like a bug in the > new demangler. > > _ZStltI9file_pathSsEbRKSt4pairIT_T0_ES6_ > OLD: bool std::operator< , std::allocator > >(std::pair, std::allocator > > const&, std::pair std::char_traits, std::allocator > > const&) > NEW: bool std::operator<(std::pair const&, std::pair const&) > > The old demangler produces "operator< <", and the new demangler produces > "operator <<". I'm not a name mangling expert but I think that > "operator <" is correct here and the new demangler suffers from > shift-operator-versus-template-syntax gotcha. Whoops. Quite right. The old name you list above was generated using DMGL_VERBOSE. I can tell by use of std::basic_string, std::allocator > where the new demangler just uses std::string. The old demangler generates the former with DMGL_VERBOSE, or std::string without DMGL_VERBOSE. If the old demangler is being run with DMGL_VERBOSE, then I'm not surprised that the resulting strings are much larger. That was the main thing which concerned me, since I didn't see anything in gdb which passed DMGL_VERBOSE to the demangler. > Also, why do you want the demangled names? I would think you would > have the same old+new demanglers that I do, so that the mangled names > would suffice. My reason is that the mangled names which are different > amount to 3 megabytes or so, but the demangled names which are different > amount to 300 megabytes or so. Oh sure, for some reason I thought it was easier for you to send the demangled names. Doesn't make much sense, I guess. The mangled names are fine. Ian