From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22443 invoked by alias); 2 Dec 2009 17:07:59 -0000 Mailing-List: contact archer-help@sourceware.org; run by ezmlm Sender: Precedence: bulk List-Post: List-Help: List-Subscribe: List-Id: Received: (qmail 22429 invoked by uid 22791); 2 Dec 2009 17:07:57 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org From: Tom Tromey To: Daniel Jacobowitz Cc: Cary Coutant , Dodji Seketeli , GDB/Archer list Subject: Re: [RFC] Proposal for a new DWARF name index section References: <4A7FE28D.4050901@redhat.com> <4A8D8868.3010302@redhat.com> <20091202051717.GA24978@caradoc.them.org> Reply-To: Tom Tromey Date: Wed, 02 Dec 2009 17:07:00 -0000 In-Reply-To: <20091202051717.GA24978@caradoc.them.org> (Daniel Jacobowitz's message of "Wed, 2 Dec 2009 00:17:17 -0500") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2009-q4/txt/msg00071.txt.bz2 >>>>> "Daniel" == Daniel Jacobowitz writes: Tom> The hash code idea seems a little weird to me, but the name Tom> canonicalization problem seems important to solve. Daniel> FWIW, I think this is a good argument for handling this as a GDB Daniel> caching extension rather than a DWARF extension. I can't imagine any Daniel> way to stably standardize this. GDB is designed to be, if not Daniel> completely robust, at least flexible w.r.t. future changes in the Daniel> demangler's canonicalized output. I think it would still be ok. We would specify the canonical form as part of the extension, and it would be up to compilers, and gdb, to correctly implement it. AFAICT it can be specified entirely in terms of the source language of the CU. In terms of our own demangler, if we wanted to change its output -- say, we make some tweak to make it prettier somehow -- we could add a "DWARF" demangle style that would preserve compatibility. We don't need to ever display the contents of this index to users. It is purely an internal detail. gdb (and presumably any debugger) needs to canonicalize the table entries, so why not have the compiler generate things already canonicalized, to save a step? If we need to change the canonicalization for some other reason, say because C++ adds new features, we can bump the version number in .debug_gnu_index and specify a new canonical form. Tom