From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18750 invoked by alias); 26 Mar 2002 23:26:45 -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 18692 invoked from network); 26 Mar 2002 23:26:44 -0000 Received: from unknown (HELO dberlin.org) (64.246.6.106) by sources.redhat.com with SMTP; 26 Mar 2002 23:26:44 -0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by dberlin.org (8.11.6/8.11.6) with ESMTP id g2QNQ4m12775; Tue, 26 Mar 2002 18:26:04 -0500 Date: Tue, 26 Mar 2002 15:26:00 -0000 From: Daniel Berlin To: Andrew Cagney cc: Jim Blandy , Subject: Re: [PATCH] Let dwarf2 CFI's execute_stack_op be used outside of CFI In-Reply-To: <3CA0FB7B.3020302@cygnus.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-SW-Source: 2002-03/txt/msg00512.txt.bz2 On Tue, 26 Mar 2002, Andrew Cagney wrote: > You wrote: > > > > > Whoops. > > You're right. > > I must have merged it while on crack or something. > > I *meant* to add the frame argument, and only require *either* the > > context argument (Which is what it currently takes, a CFA context) or the > > frame, but it looks like I messed up. > > > > What it *should* look like is closer to the one from the WIP i sent. It > > should call get_saved_register with the frame argument if the context is > > null, or get_reg with the context argument if the context is not null. > > That is what I was asking > > I wrote: > > >> Shouldn't the dwarf2 location expression evaluator be separated out > >> (dwarf2loc?) and be parameterized with both the frame it is to operate > >> within and the expression it is to evaluate. > > > > Whoops. > > You're right. > > I must have merged it while on crack or something. > > I *meant* to add the frame argument, and only require *either* the > > context argument (Which is what it currently takes, a CFA context) or the > > frame, but it looks like I messed up. > > > > What it *should* look like is closer to the one from the WIP i sent. It > > should call get_saved_register with the frame argument if the context is > > null, or get_reg with the context argument if the context is not null. > > That is what I was asking > > I wrote: > > >> Shouldn't the dwarf2 location expression evaluator be separated out > >> (dwarf2loc?) and be parameterized with both the frame it is to operate > >> within and the expression it is to evaluate. > > > > > Whoops. > > You're right. > > I must have merged it while on crack or something. > > I *meant* to add the frame argument, and only require *either* the > > context argument (Which is what it currently takes, a CFA context) or the > > frame, but it looks like I messed up. > > > > What it *should* look like is closer to the one from the WIP i sent. It > > should call get_saved_register with the frame argument if the context is > > null, or get_reg with the context argument if the context is not null. > > That is what I was asking Errr, not really. What I said is correct. It is parameterized already with a frame and an expression. It's just that we want to hand it a different type of frame. You implied it wasn't parameterized with either, when it has been since the beginning. However, I *meant* to change it to take either a struct context (one type of frame), or a struct frame_info. I've written this code so many times that I rewrote/merged it without thinking, and forgot to add the other type of frame parameter to the external entry point. The only actual changes needed between what I submitted, and what it should be, is one more parameter, and changing read_register_gen to get_saved_register. > I wrote: > > >> Shouldn't the dwarf2 location expression evaluator be separated out > >> (dwarf2loc?) and be parameterized with both the frame it is to operate > >> within and the expression it is to evaluate. > > > > Yeah, so? > > I'm doing this incrementally. > > The first step is adding an external entry point, then moving it outside > > of dwarf2cfi.c, then modifying it to take a struct frame info, etc. > > I'm trying to do this without breaking anything. > > It currently *is* parameterized with both the frame and expression. The > > problem is that the frame it expects isn't a "struct frame_info", it's a > > dwarf2 frame context. > > Andrew >