From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 124565 invoked by alias); 14 May 2019 08:04:03 -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 124556 invoked by uid 89); 14 May 2019 08:04:03 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-26.2 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy= X-HELO: mail-wr1-f66.google.com Received: from mail-wr1-f66.google.com (HELO mail-wr1-f66.google.com) (209.85.221.66) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 14 May 2019 08:04:02 +0000 Received: by mail-wr1-f66.google.com with SMTP id d9so9676380wrx.0 for ; Tue, 14 May 2019 01:04:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=embecosm.com; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=EAQ5ZjU8pFpDkubsqkFpVG4ncP0+u+C7j646cOylPxc=; b=TnuGXmcu34FxYqFiZjid8CqHLEiyKxcWxiad4ISbLCr0OtDmfrZ5pqBrUBuj29QEUV 6K3Rr1ApglMnCG7aySAQf/GFeISVSOh2sV/c9vTi6cFccCaIbeUl3/w5/PpdJbduQ+r7 Ev6L9NijvQE4Q5JGrPIGhogb7DpMkNi48HdFwpr4EacoOtRqJHtu/oRcs0Q+bIJbFbxv JcwWNRS5HXTT6AzBxJYl5IAxBf0K9seYJ7UIQLCxqt3mSc8w4OHsppVFQKMALT0an6Yu Pw8ccY3C7VxhgZKIs8OSYzOsoOxYe+F56q072pApKoJ3NQZ2+Z0GDeBl/UBVKGA26yS7 1uVw== Return-Path: Received: from localhost (host86-180-62-212.range86-180.btcentralplus.com. [86.180.62.212]) by smtp.gmail.com with ESMTPSA id x6sm5901506wru.36.2019.05.14.01.03.59 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 14 May 2019 01:03:59 -0700 (PDT) Date: Tue, 14 May 2019 08:04:00 -0000 From: Andrew Burgess To: Tom de Vries Cc: gdb-patches@sourceware.org Subject: Re: [RFC][gdb/testsuite] Fix base address selection entry encoding in dw2-skip-prologue.S Message-ID: <20190514080358.GJ2568@embecosm.com> References: <20190307121149.GA14543@delia> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190307121149.GA14543@delia> X-Fortune: Too few computrons available. X-Editor: GNU Emacs [ http://www.gnu.org/software/emacs ] User-Agent: Mutt/1.9.2 (2017-12-15) X-IsSubscribed: yes X-SW-Source: 2019-05/txt/msg00309.txt.bz2 * Tom de Vries [2019-03-07 13:11:50 +0100]: > Hi, > > A base address selection entry in a location list consist of two (constant or > relocated) address offsets. The two offsets are the same size as an address > on the target machine. > > The test-case gdb.dwarf2/dw2-skip-prologue.S encodes a base address selection > entry using .4byte, which is incorrect for 8-byte pointer size. [ Which > triggers an assert in dwz, see PR dwz/24172. ] > > Fix this by using PTRBYTE instead. > > Tested on x86_64-linux. > > Do we fix this type of errors in the testsuite? AFAICT, the invalid dwarf is > not intentional. > > Thanks, > - Tom > > [gdb/testsuite] Fix base address selection entry encoding in dw2-skip-prologue.S > > gdb/testsuite/ChangeLog: > > 2019-03-07 Tom de Vries > > * gdb.dwarf2/dw2-skip-prologue.S (.debug_loc): Fix base address > selection entry encoding. This patch looks great. Please go ahead and apply it. Thanks, Andrew > > --- > gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.S | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.S b/gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.S > index cef6e6df12..a55699fdc6 100644 > --- a/gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.S > +++ b/gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.S > @@ -123,7 +123,7 @@ > .section .debug_loc > loclist: > /* Reset the location list base address first. */ > - .4byte -1, 0 > + PTRBYTE -1, 0 > > PTRBYTE func_start, func_end > .2byte 2f-1f