From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21405 invoked by alias); 26 Aug 2008 11:59:54 -0000 Received: (qmail 21379 invoked by uid 22791); 26 Aug 2008 11:59:52 -0000 X-Spam-Check-By: sourceware.org Received: from mail-gx0-f10.google.com (HELO mail-gx0-f10.google.com) (209.85.217.10) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 26 Aug 2008 11:55:16 +0000 Received: by gxk3 with SMTP id 3so3455728gxk.0 for ; Tue, 26 Aug 2008 04:54:37 -0700 (PDT) Received: by 10.151.156.12 with SMTP id i12mr8877320ybo.182.1219743786123; Tue, 26 Aug 2008 02:43:06 -0700 (PDT) Received: by 10.150.92.14 with HTTP; Tue, 26 Aug 2008 02:43:06 -0700 (PDT) Message-ID: <724307610808260243t5dcdd49ax4d01f0352244c124@mail.gmail.com> Date: Tue, 02 Sep 2008 09:45:00 -0000 From: "Tommy Lin" To: "Keith Seitz" Subject: Re: Problems with SrcWin Cc: insight@sourceware.org In-Reply-To: <48B2EA09.2080608@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <724307610808250023p50d88eddr7fd5b097ca4f0076@mail.gmail.com> <48B2EA09.2080608@redhat.com> Mailing-List: contact insight-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: insight-owner@sourceware.org X-SW-Source: 2008-q3/txt/msg00047.txt.bz2 Message-ID: <20080902094500.4czvi9dFYFz9-68iniAdFKygveI03eDk1_oQ-nt3DAk@z> >> (1) after Insight is connected to target, the Control menu and >> button items are still disabled. They'll be enabled after some actions >> are done (ex. execute 'stepi' from ConsoleWindow.) > > This is usually caused by inferior code not setting a fake ptid for the UI. > This is a very common problem with non-native targets. You can check this by > inspecting the function gdb_target_has_execution. Check out what the remote > target does in extended_remote_create_inferior_1 (it sets inferior_ptid to > some made up non-NULL entity). The value does not matter -- that it is > non-NULL is all that is required. I found my target's xxxx_create_inferior() isn't called before gdb_target_has_execution(). Maybe it's not a good port. So, I fix this issue by removing the inferior_ptid part from gdb_target_has_execution() directly. It seems can be fixed in srcbar.itcl:do_connect by setting Control $Menu and $Tool into 'normal'. >> (2) after Insight is connected to target, the SrcWin displays >> nothing... (there is no 'file', 'load', and 'symbol-file' command >> executed.) I think, if there is no corresponding symbolic info, it >> should fetch memory contents near $PC and display disassembled >> instructions. > > Open a console window and type "list". If gdb does not return something, > than Insight cannot, either. Insight will disassemble around $PC *if* gdb > can find a function containing the PC (so that it knows the bounds of the > function to disassemble). This is a gdb limitation that Insight has not > worked around yet (and probably never will). Yes, I tried it out. Thanks!