From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11780 invoked by alias); 24 Jul 2007 18:10:12 -0000 Received: (qmail 11771 invoked by uid 22791); 24 Jul 2007 18:10:11 -0000 X-Spam-Check-By: sourceware.org Received: from shell4.BAYAREA.NET (HELO shell4.bayarea.net) (209.128.82.1) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 24 Jul 2007 18:10:05 +0000 Received: (qmail 18111 invoked from network); 24 Jul 2007 11:10:03 -0700 Received: from 209-128-106-254.bayarea.net (HELO ?192.168.20.7?) (209.128.106.254) by shell4.bayarea.net with SMTP; 24 Jul 2007 11:10:03 -0700 Message-ID: <46A64079.2010704@eagercon.com> Date: Tue, 24 Jul 2007 18:19:00 -0000 From: Michael Eager User-Agent: Thunderbird 1.5.0.9 (X11/20070102) MIME-Version: 1.0 To: Michael Eager , gdb@sources.redhat.com Subject: Re: frame cache References: <46A63051.7060208@eagercon.com> <46A63209.4010405@eagercon.com> <20070724171711.GB15843@caradoc.them.org> In-Reply-To: <20070724171711.GB15843@caradoc.them.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-07/txt/msg00175.txt.bz2 Daniel Jacobowitz wrote: > On Tue, Jul 24, 2007 at 10:08:25AM -0700, Michael Eager wrote: >> And one more question: >> >> 3) In _skip_prologue(), an dummy _frame_cache is >> created to be passed to _analyze_prologue(). This >> dummy cache entry is discarded. Why not retain this info? > > I think the answers to your other two questions should clarify this. > We don't have anywhere to keep it, and the information is not quite > the same because it depends how far into the function we're allowed to > analyze (the PC "limit"). Also, many targets don't do it this way. This seems odd. The function is _analyze_prologue() not _analyze_part_of_a_prologue(). The prologue isn't going to change depending on where the program stopped. _skip_prologue() can return a pc based on whatever a complete analysis reveals. In i386, for example, the "pc limit" (called current_pc) passed to i386_analyze_prologue() is 0xffffffff. Sparc is similar. Neither seem to restrict how far the analyze_prologue function scans. I do see that some targets merge skip_prologue and analyze_prologue. Are there other methods? It would seem to me that for any function that has DWARF data, one can locate the end of the prologue without reading data from the target. I don't see any target which does this. -- Michael Eager eager@eagercon.com 1960 Park Blvd., Palo Alto, CA 94306 650-325-8077