From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28977 invoked by alias); 28 Jun 2003 15:20:19 -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 28969 invoked from network); 28 Jun 2003 15:20:19 -0000 Received: from unknown (HELO crack.them.org) (146.82.138.56) by sources.redhat.com with SMTP; 28 Jun 2003 15:20:19 -0000 Received: from dsl093-172-017.pit1.dsl.speakeasy.net ([66.93.172.17] helo=nevyn.them.org ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 19WHVq-0006vu-00 for ; Sat, 28 Jun 2003 10:21:15 -0500 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 19WHUu-000263-00 for ; Sat, 28 Jun 2003 11:20:16 -0400 Date: Sat, 28 Jun 2003 15:21:00 -0000 From: Daniel Jacobowitz To: gdb@sources.redhat.com Subject: Re: source with inlined assembly Message-ID: <20030628152016.GA8004@nevyn.them.org> Mail-Followup-To: gdb@sources.redhat.com References: <20030628150159.GA2774@white> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030628150159.GA2774@white> User-Agent: Mutt/1.5.1i X-SW-Source: 2003-06/txt/msg00525.txt.bz2 On Sat, Jun 28, 2003 at 11:01:59AM -0400, Bob Rossi wrote: > Hi, > > I am investigating the best way to show the user assembly code via my > front end called cgdb. It appears that there is a disassemble function > that will get the assembly code. > > Is there any way to nicely show to the user the source with the assembly > inlined between the source lines? Can I ask gdb for the assembly for 1 > source line of code? Then can I ask it the assembly for every source > line of code in a file? > > What is the mechanism for doing this with a front end? I really want to > stay away from parsing the output of the disassemble command to try to > guess which assembly lines go with the source code. > > Also, if up till now there is only a disassemble function and this > doesn't supply a front end with what I am asking for, does this seem > like a good feature to add to the mi command set? Please look at the GDB/MI manual, at the "-data-disassemble" command. It should be exactly what you're looking for. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer