From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29706 invoked by alias); 16 Mar 2004 16:26:58 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 29629 invoked from network); 16 Mar 2004 16:26:55 -0000 Received: from unknown (HELO miranda.se.axis.com) (193.13.178.2) by sources.redhat.com with SMTP; 16 Mar 2004 16:26:55 -0000 Received: from axis.com (ironmaiden.se.axis.com [10.13.8.120]) by miranda.se.axis.com (8.12.9/8.12.9/Debian-5local0.1) with ESMTP id i2GGQG8u014678; Tue, 16 Mar 2004 17:26:17 +0100 Message-ID: <40572AA8.5040406@axis.com> Date: Tue, 16 Mar 2004 16:26:00 -0000 From: Orjan Friberg Organization: Axis Communications User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040113 MIME-Version: 1.0 To: Daniel Jacobowitz CC: gdb-patches@sources.redhat.com, Hans-Peter Nilsson Subject: Re: [CRIS] dwarf2 frame sniffer problem? References: <404F481E.9060709@axis.com> <20040310165905.GA4291@nevyn.them.org> <405072FE.1010403@axis.com> <40508BD8.10802@axis.com> <20040311171139.GA17530@nevyn.them.org> <40518F6A.2080806@axis.com> <20040312153817.GA20055@nevyn.them.org> In-Reply-To: <20040312153817.GA20055@nevyn.them.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-03.o/txt/msg00356.txt Daniel Jacobowitz wrote: > > I see that your GCC port uses textual prologues. As it happens, I just > implemented dwarf generation for that mechanism (for Thumb), so I know > how it's supposed to work. Here's your problem. First you have: > > /* FIXME: Slightly redundant calculation, as we do the same in > pieces below. This offset must be the total adjustment of the > stack-pointer. We can then def_cfa call at the end of this > function with the current implementation of execute_cfa_insn, but > that wouldn't really be clean. */ > > cfa_label = dwarf2out_cfi_label (); > dwarf2out_def_cfa (cfa_label, cfa_reg, cfa_offset); > > but that label is at the beginning of the function, so this is > incorrect. That's not what the CFA is at the beginning of the > function. Would emitting that label *after* the prologue be an option (i.e. leaving us without dwarf2 information while still in the prologue)? -- Orjan Friberg Axis Communications From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29706 invoked by alias); 16 Mar 2004 16:26:58 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 29629 invoked from network); 16 Mar 2004 16:26:55 -0000 Received: from unknown (HELO miranda.se.axis.com) (193.13.178.2) by sources.redhat.com with SMTP; 16 Mar 2004 16:26:55 -0000 Received: from axis.com (ironmaiden.se.axis.com [10.13.8.120]) by miranda.se.axis.com (8.12.9/8.12.9/Debian-5local0.1) with ESMTP id i2GGQG8u014678; Tue, 16 Mar 2004 17:26:17 +0100 Message-ID: <40572AA8.5040406@axis.com> Date: Fri, 19 Mar 2004 00:09:00 -0000 From: Orjan Friberg Organization: Axis Communications User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040113 MIME-Version: 1.0 To: Daniel Jacobowitz CC: gdb-patches@sources.redhat.com, Hans-Peter Nilsson Subject: Re: [CRIS] dwarf2 frame sniffer problem? References: <404F481E.9060709@axis.com> <20040310165905.GA4291@nevyn.them.org> <405072FE.1010403@axis.com> <40508BD8.10802@axis.com> <20040311171139.GA17530@nevyn.them.org> <40518F6A.2080806@axis.com> <20040312153817.GA20055@nevyn.them.org> In-Reply-To: <20040312153817.GA20055@nevyn.them.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-03/txt/msg00356.txt.bz2 Message-ID: <20040319000900.dpywTLUrgOVMt2L_g4GrgWwiUruiKW5kSrJNzj6UVMs@z> Daniel Jacobowitz wrote: > > I see that your GCC port uses textual prologues. As it happens, I just > implemented dwarf generation for that mechanism (for Thumb), so I know > how it's supposed to work. Here's your problem. First you have: > > /* FIXME: Slightly redundant calculation, as we do the same in > pieces below. This offset must be the total adjustment of the > stack-pointer. We can then def_cfa call at the end of this > function with the current implementation of execute_cfa_insn, but > that wouldn't really be clean. */ > > cfa_label = dwarf2out_cfi_label (); > dwarf2out_def_cfa (cfa_label, cfa_reg, cfa_offset); > > but that label is at the beginning of the function, so this is > incorrect. That's not what the CFA is at the beginning of the > function. Would emitting that label *after* the prologue be an option (i.e. leaving us without dwarf2 information while still in the prologue)? -- Orjan Friberg Axis Communications