From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12009 invoked by alias); 26 Sep 2002 13:49:57 -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 11999 invoked from network); 26 Sep 2002 13:49:55 -0000 Received: from unknown (HELO mailhub.lss.emc.com) (168.159.1.79) by sources.redhat.com with SMTP; 26 Sep 2002 13:49:55 -0000 Received: from popimap.lss.emc.com (vesta-ge.lss.emc.com [10.254.140.138]) by mailhub.lss.emc.com (Switch-2.2.0/Switch-2.2.0) with ESMTP id g8QDnk215409; Thu, 26 Sep 2002 09:49:47 -0400 (EDT) Received: from emc.com (lbn0048.lss.emc.com [168.159.22.48]) by popimap.lss.emc.com (Switch-2.2.0/Switch-2.2.0) with ESMTP id g8QDnkt09590; Thu, 26 Sep 2002 09:49:46 -0400 (EDT) Message-ID: <3D9310D8.3060401@emc.com> Date: Thu, 26 Sep 2002 06:49:00 -0000 From: Josef Ezra User-Agent: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; rv:1.0.0) Gecko/20020530 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Fernando Nasser CC: Michael Snyder , gdb-patches@sources.redhat.com Subject: Re: [RFA] new command: 'maintenance info lines' References: <02ea01c1e6eb$65f850c0$ad219fa8@lss.emc.com> <3CBEFC88.37807AEF@redhat.com> <3D08D15E.7030805@emc.com> <3D08DB87.A8119A1D@redhat.com> <3D0E39E6.5060701@emc.com> <3D0FA3CD.5681BF89@redhat.com> <3D789AF5.4020406@subdimension.com> <3D921C02.9020906@redhat.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2002-09/txt/msg00632.txt.bz2 Fernando Nasser wrote: > The maintenance commands are to be used to debug (or test) GDB only. > We could say you'd be dumping the line table but that is hardly what > is being done and we don't have a real need for that anyway. > well, WE have a real need for this command (is there a wrong way to use gdb?). but we sure don't need it to maintain gdb. > If you really want to use a CLI command, you need to add a set/show > variable to request that the source lines are included in the > 'disassemble' command output. do you mean something like: (gdb) set disassem dump-source-or-something 1 (gdb) disassemble main Dump of assembler code for function main: Line ../gdb/main.c:757 0x50ce4
: save %sp, -120, %sp 0x50ce8 : std %i0, [ %fp + -24 ] 0x50cec : sethi %hi(0x50000), %o0 0x50cf0 : or %o0, 0x16c, %o0 ! 0x5016c 0x50cf4 : sethi %hi(0x2a7c00), %o2 Line ../gdb/main.c:759 0x50cf8 : add %fp, -24, %o1 0x50cfc : or %o2, 0x3c0, %o2 0x50d00 : call 0xb2374 0x50d04 : mov 6, %o3 Line ../gdb/main.c:775 0x50d08 : ret 0x50d0c : restore %g0, 0, %o0 End of assembler dump. that would be a great solution for our needs. how about setting the dump-source to 1 to show line location, and 2 to try presenting the actual source lines (like mixed list and disassemble) > The newer disassembler code that handles mixed output is still in the > MI subdirectory (and in an older form in the gdbtk subdir) but it is > intended to replace the one in printcmd.c. It shouldn't be too > difficult and you can always ask if you have any doubts. ?? please explain thanks - jezra