From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2053 invoked by alias); 9 Sep 2003 21:18:27 -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 2035 invoked from network); 9 Sep 2003 21:18:25 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sources.redhat.com with SMTP; 9 Sep 2003 21:18:25 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.11.6/8.11.6) with ESMTP id h89LIOl04437 for ; Tue, 9 Sep 2003 17:18:24 -0400 Received: from pobox.corp.redhat.com (pobox.corp.redhat.com [172.16.52.156]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id h89LINe13436 for ; Tue, 9 Sep 2003 17:18:23 -0400 Received: from localhost.redhat.com (porkchop.devel.redhat.com [172.16.58.2]) by pobox.corp.redhat.com (8.12.8/8.12.8) with ESMTP id h89LIMba013596; Tue, 9 Sep 2003 17:18:23 -0400 Received: by localhost.redhat.com (Postfix, from userid 469) id 341952CB35; Tue, 9 Sep 2003 17:27:10 -0400 (EDT) From: Elena Zannoni MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <16222.17838.527612.509356@localhost.redhat.com> Date: Tue, 09 Sep 2003 21:18:00 -0000 To: Daniel Jacobowitz Cc: gdb-patches@sources.redhat.com, jimb@redhat.com, ezannoni@redhat.com Subject: Re: [rfa/6.0] Fix a thinko in dwarf2loc In-Reply-To: <20030907041237.GB10340@nevyn.them.org> References: <20030801193245.GA2529@nevyn.them.org> <20030817205822.GD11300@nevyn.them.org> <20030824164855.GA17841@nevyn.them.org> <20030907041237.GB10340@nevyn.them.org> X-SW-Source: 2003-09/txt/msg00176.txt.bz2 Daniel Jacobowitz writes: > On Sun, Aug 24, 2003 at 12:48:55PM -0400, Daniel Jacobowitz wrote: > > On Sun, Aug 17, 2003 at 04:58:22PM -0400, Daniel Jacobowitz wrote: > > > On Fri, Aug 01, 2003 at 03:32:45PM -0400, Daniel Jacobowitz wrote: > > > > Any variable with DW_OP_reg* requires a frame to read it - what > > > > symbol_read_needs_frame () really means is "is this variable meaningful when > > > > the program is not running". > > > > > > > > This would show up in the testsuite, but GCC doesn't tend to put locals in > > > > registers without optimization or register keywords everywhere. Symptom is > > > > that a watchpoint was not deleted when we left its scope, since we thought > > > > it was global. > > > > > > > > OK? > > > > > > Ping... > > > > > > [Does dwarf2loc fall under the maintenance umbrella of the dwarf2 > > > reader?] > > > > Ping? I would like to fix this bug for 6.0. > > Jim, Elena? I hit this bug again in testing the > deprecated_safe_get_selected_frame () patch. > > > > > 2003-08-01 Daniel Jacobowitz > > > > > > > > * dwarf2loc.c (dwarf2_loc_desc_needs_frame): Variables in a > > > > register do need a frame. > > > > > > > > --- gdb-5.3.20030801/gdb/dwarf2loc.c.orig 2003-08-01 14:58:57.000000000 -0400 > > > > +++ gdb-5.3.20030801/gdb/dwarf2loc.c 2003-08-01 15:00:05.000000000 -0400 > > > > @@ -318,7 +318,7 @@ dwarf2_loc_desc_needs_frame (unsigned ch > > > > > > > > free_dwarf_expr_context (ctx); > > > > > > > > - return baton.needs_frame; > > > > + return baton.needs_frame || ctx->in_reg; > > > > } > > > > Hmmm, the ctx just got freed, you cannot dereference it. Need to use a local variable. What you are really saying here is that the needs_frame variable is not sufficient to describe what's needed. Can the case be added, so that needs_frame becomes OK? Proabably you need another need_frame_* function. elena > > > > static void > > > > > > > > > > -- > Daniel Jacobowitz > MontaVista Software Debian GNU/Linux Developer