From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31587 invoked by alias); 27 Jun 2004 02:12:52 -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 31578 invoked from network); 27 Jun 2004 02:12:51 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 27 Jun 2004 02:12:51 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.10/8.12.10) with ESMTP id i5R2Coe3021346 for ; Sat, 26 Jun 2004 22:12:51 -0400 Received: from localhost.redhat.com (porkchop.devel.redhat.com [172.16.58.2]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i5R2Cm028750; Sat, 26 Jun 2004 22:12:48 -0400 Received: from gnu.org (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id E8CF72B9D; Sat, 26 Jun 2004 22:12:43 -0400 (EDT) Message-ID: <40DE2D1B.4070003@gnu.org> Date: Sun, 27 Jun 2004 02:12:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-GB; rv:1.4.1) Gecko/20040217 MIME-Version: 1.0 To: Nick Roberts Cc: Daniel Jacobowitz , gdb@sources.redhat.com Subject: Re: How does GDB/MI give the current frame References: <16603.23348.569889.284030@nick.uklinux.net> <20040624231659.GA16577@nevyn.them.org> <16605.15641.474398.42157@nick.uklinux.net> In-Reply-To: <16605.15641.474398.42157@nick.uklinux.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-06/txt/msg00261.txt.bz2 > Daniel Jacobowitz writes: > DJ> > DJ> Why not use -stack-info-frame? > > Because AFAIK this MI command has not been implemented (yet). > > Andrew Cagney writes: > > AC> When the user does "up", "down", the debugger should generate a selected > AC> CLI frame changed event (it currently doesn't). If the GUI so chooses, > AC> it can track the users "selected" frame, by responding to these events. > > I don't know what a selected CLI frame changed event is but up, down, and > frame generate MI output, so I imagine its just a case of hooking > -stack-info-frame and -stack-select-frame to that output. I will try to do > this if you think it's appropriate. For the CLI, something like this: -> -interpreter cli "up" <- ~"info on new frame..." <- *select-frame,... <- done with similar for -stack-select-frame: -> -stack-select-frame 1 <- *select-frame,,.... <- done Where, yes, would be constructed by calling frame code. -stack-info-frame would just be just: -> -stack-info-frame <- done, The important thing is that, in both cases, the GUI is being driven by the select-frame event. Andrew PS: Better / more consistent event name welcome.