From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1207 invoked by alias); 12 Apr 2002 16:05:14 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 1200 invoked from network); 12 Apr 2002 16:05:11 -0000 Received: from unknown (HELO localhost.redhat.com) (24.112.240.27) by sources.redhat.com with SMTP; 12 Apr 2002 16:05:11 -0000 Received: from cygnus.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 84DF93CD9; Fri, 12 Apr 2002 12:05:12 -0400 (EDT) Message-ID: <3CB705B8.8070001@cygnus.com> Date: Fri, 12 Apr 2002 09:05:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:0.9.9) Gecko/20020328 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Kevin Buettner Cc: Richard.Earnshaw@arm.com, gdb@sources.redhat.com Subject: Re: [rfc] frame->frame => frame->addr && frame->base() References: <200204121249.NAA02782@cam-mail2.cambridge.arm.com> <3CB6E371.6050801@cygnus.com> <1020412155238.ZM7138@localhost.localdomain> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2002-04/txt/msg00216.txt.bz2 > If the value returned by frame->base() is debug-info dependent, then > that would suggest that it could have different values for different > types of debug info. That in turn suggests that you have to know what > type of debug info you're dealing with at frame creation time so that > frame->base can be initialized correctly. yes. > Of course, it could be done lazily. You could just initialize frame->base > to lazy_base() (or whatever). lazy_base() would determine the function > that's really required for that frame + debug info, reset the ->base > field, and then invoke the function it's just calculated to obtain the > desired value. > > Implementation details aside, this dependency causes me to wonder if it's > really a good idea make this operation a member of the frame struct. I'm still working through that. If different frames have different debug info then they would need different functions. Initially, I suspect a frame->frame => frame->addr change will go through but not a new frame->base() method. It may not be necessary - FRAME_ARGS_ADDRESS_CORRECT appears to be equivalent. Unfortunatly, frame_args_address_correct is bound to the ABI/ISA and not, also, the debug info. Andrew