From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4355 invoked by alias); 25 Apr 2008 19:00:16 -0000 Received: (qmail 4324 invoked by uid 22791); 25 Apr 2008 19:00:12 -0000 X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (65.74.133.4) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 25 Apr 2008 18:59:54 +0000 Received: (qmail 3296 invoked from network); 25 Apr 2008 18:59:52 -0000 Received: from unknown (HELO orlando.local) (pedro@127.0.0.2) by mail.codesourcery.com with ESMTPA; 25 Apr 2008 18:59:52 -0000 From: Pedro Alves To: gdb-patches@sourceware.org Subject: Re: Handle DW_AT_const_value/DW_FORM_strp variables Date: Fri, 25 Apr 2008 20:14:00 -0000 User-Agent: KMail/1.9.6 (enterprise 0.20070907.709405) Cc: Joel Brobecker References: <200804251915.27580.pedro@codesourcery.com> <20080425182858.GB841@adacore.com> In-Reply-To: <20080425182858.GB841@adacore.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200804251959.51368.pedro@codesourcery.com> X-IsSubscribed: yes 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 X-SW-Source: 2008-04/txt/msg00580.txt.bz2 A Friday 25 April 2008 19:28:58, Joel Brobecker escreveu: > Hi Pedro, > > > gdb/ > > 2008-04-25 Pedro Alves > > > > * dwarf2read.c (dwarf2_const_value): Handle DW_FORM_strp. > > > > gdb/testsuite/ > > 2008-04-25 Pedro Alves > > > > * gdb.dwarf2/dw2-strp.S, gdb.dwarf2/dw2-strp.exp: New files. > > Both patches look good to me. Please go ahead and commit. > Thanks for the quick review. It's in now. > > +# This test can only be run on targets which support DWARF-2 and use > > gas. +# For now pick a sampling of likely targets. > > +if {![istarget *-*-linux*] > > + && ![istarget *-*-gnu*] > > + && ![istarget *-*-elf*] > > + && ![istarget *-*-openbsd*] > > + && ![istarget arm-*-eabi*] > > + && ![istarget powerpc-*-eabi*]} { > > + return 0 > > +} > > I wonder if we should put that in a function somewhere. We have been > repeating this pretty large condition in several files, now. Just > thinking out loud... Indeed. ( Thinking out load too: However, we could also make the predicate the other way around. Check for targets that *don't* support dwarf and *don't* use gas. Could they be fewer? Probably some of the non-free Unixen, and older xcoff/coff/a.out based targets. E.g. Windows/Cygwin aren't running these tests, and dwarf is a bit more susceptible to bugs there in the sense that debug sections don't get VMA == 0. ) -- Pedro Alves