From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 45739 invoked by alias); 23 Aug 2016 16:26:17 -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 45727 invoked by uid 89); 23 Aug 2016 16:26:17 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=love X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 23 Aug 2016 16:26:16 +0000 Received: from svr-orw-fem-02x.mgc.mentorg.com ([147.34.96.206] helo=SVR-ORW-FEM-02.mgc.mentorg.com) by relay1.mentorg.com with esmtp id 1bcEWk-0005EM-3U from Luis_Gustavo@mentor.com ; Tue, 23 Aug 2016 09:26:14 -0700 Received: from [134.86.105.206] (147.34.91.1) by svr-orw-fem-02.mgc.mentorg.com (147.34.96.168) with Microsoft SMTP Server id 14.3.224.2; Tue, 23 Aug 2016 09:26:14 -0700 Subject: Re: [PATCH] Fix for gdb.base/pc-fp.exp. References: <1471900578.4102.36.camel@us.ibm.com> <8f1a63df-5140-831e-0892-34be046144c5@redhat.com> <1471969030.4102.52.camel@us.ibm.com> To: "Carl E. Love" , Pedro Alves CC: Ulrich Weigand , Edjunior Barbosa Machado , Reply-To: Luis Machado From: Luis Machado Message-ID: Date: Tue, 23 Aug 2016 16:26:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <1471969030.4102.52.camel@us.ibm.com> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2016-08/txt/msg00233.txt.bz2 On 08/23/2016 11:17 AM, Carl E. Love wrote: > On Tue, 2016-08-23 at 00:17 +0100, Pedro Alves wrote: >> Can you provide more details? >> >> E.g.: >> >> What's was wrong? What failed? Why is removing this line the >> right fix? >> >> I'm not suggesting that the fix is wrong (or right, I have no >> idea). Just pointing out that context is missing. >> >> Thanks, >> Pedro Alves >> > > > > Here is an updated patch with the missing detail. > -------------------------------------------------------------------------- > Fix for gdb.base/pc-fp.exp. > > It is my understanding that GDB used to require each architecture to > define a Frame Pointer (fp). However, this functionality was deprecated > some time ago so the call to setup the fp_reg was changed to deprecated > (set_gdbarch_deprecated_fp_regnum). It should have been removed from the > Power code. > > That said, the code "set_gdbarch_deprecated_fp_regnum > (gdbarch, PPC_R0_REGNUM + 1);" sets up register r1 as the frame pointer. > Register r1 is no longer used to hold the frame pointer on Power. By > removing the fp definition for Power in GDB, it causes GDB to fall back > to the call get_frame_base_address (frame) which returns the correct value > depending on the specific senario but most of the time is the DWARF > canonical frame address. Is this the case for all Power ABI's or only server? I wonder what the impact would be on Power embedded.