From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22750 invoked by alias); 13 May 2014 19:22:35 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 22738 invoked by uid 89); 13 May 2014 19:22:34 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 13 May 2014 19:22:33 +0000 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s4DJMU8w020470 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 13 May 2014 15:22:30 -0400 Received: from blade.nx (ovpn-116-68.ams2.redhat.com [10.36.116.68]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s4DJMTP9026204; Tue, 13 May 2014 15:22:30 -0400 Received: by blade.nx (Postfix, from userid 1000) id 1548526234A; Tue, 13 May 2014 20:22:29 +0100 (BST) Date: Tue, 13 May 2014 19:22:00 -0000 From: Gary Benson To: Florian Weimer Cc: Mark Kettenis , gdb-patches@sourceware.org Subject: Re: [PATCH 0/2] Demangler crash handler Message-ID: <20140513192228.GC26575@blade.nx> References: <20140509100656.GA4760@blade.nx> <201405091120.s49BKO1f010622@glazunov.sibelius.xs4all.nl> <87fvkhjqvs.fsf@mid.deneb.enyo.de> <20140513102223.GC17805@blade.nx> <87ppjhilni.fsf@mid.deneb.enyo.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87ppjhilni.fsf@mid.deneb.enyo.de> X-IsSubscribed: yes X-SW-Source: 2014-05/txt/msg00175.txt.bz2 Florian Weimer wrote: > * Gary Benson: > > > It would be more reliable to run the demangler in a separate > > > process. > > > > Agreed. There are two issues though. First is performance: > > GDB can demangle a lot of symbols--starting GDB on LibreOffice > > demangles more than 369,000 symbols on my machine, and typing > > "b " demangles 2,740,000 more--so the IPC overhead > > has to be seriously low. > > Is most of the demangling of the bulk kind? These cases are easy in > the sense that a ping-pong between the two processes is avoidable. > > More worrisome would be the occasional demangling as part of other > tasks, where the context switches might become very visible. It probably is bulk, though I don't know for sure. You could probably rearrange GDB to demangle a whole object file or CU's symbols at once. > > > What's so difficult about fixing the demangler? > > > > It's not so difficult really, but fixes take time to diagnose, > > reproduce, fix, test, review, etc. > > I was referring to a more permanent fix, not just patching the bug > of the day as users encounter it. Ah, sorry. The main difficulty for me is that I don't fully understand the mangling spec. The people who really know it backwards are the people who wrote the libiberty demangler in the first place :) That, and time. This demangler work is not my main job at the moment. It just happens that I (foolishly?) fixed a bug on it last year so now I'm Demangler Man until someone else falls into the trap. Cheers, Gary -- http://gbenson.net/