From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13707 invoked by alias); 16 Sep 2003 20:05:26 -0000 Mailing-List: contact insight-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: insight-owner@sources.redhat.com Received: (qmail 13676 invoked from network); 16 Sep 2003 20:05:24 -0000 Received: from unknown (HELO exchwenz01.smtp.dmcwave.co.nz) (202.27.34.1) by sources.redhat.com with SMTP; 16 Sep 2003 20:05:24 -0000 Received: by exchwenz01.dmcwave.co.nz with Internet Mail Service (5.5.2656.59) id ; Wed, 17 Sep 2003 08:00:39 +1200 Message-ID: <8D7C5F56B409554D9D46AC22195807F3061D1C@exchwenz01.dmcwave.co.nz> From: Rod Boyce To: 'Mike Smith' , 'Keith Seitz' Cc: insight@sources.redhat.com Subject: RE: Problems with remote debugging Date: Tue, 16 Sep 2003 20:05:00 -0000 MIME-Version: 1.0 Content-Type: text/plain X-SW-Source: 2003-q3/txt/msg00168.txt.bz2 Mike, I do this all the time. I start up insight (compiled for debug my target processor) and load the program I want to debug into insight using file open and select the program to debug. I then copy the program to my NFS root drive my target is using and start gdbserver with the following parameters. #gdbserver tcp:2001 I then connect to my target and unselect the download program add breakpoints and any other setting I don't want to use. A which point I set a break point in the program I'm wanting to debug and click the run button on the insight GUI. The code will hit the breakpoint and I start debugging. I use a similar process then I'm debugging using my BDM. I have never had a problem using either gdbserver or my BDM with insight. Insight was the first debugger I learnt to use and I still prefer to use it if I can. I don't know if this will help any and I'm using a different processor but this is how I use insight to debug my target. Rod > -----Original Message----- > From: Mike Smith [mailto:msmith@trinityconvergence.com] > Sent: Wednesday, 17 September 2003 3:08 a.m. > To: 'Keith Seitz' > Cc: insight@sources.redhat.com > Subject: RE: Problems with remote debugging > > > What is "my_prog"? Is this your debug executable? If so, it appears > that > > gdb is attempting to run it natively. What host are you on? > > Yes, 'my_prog' is the executable (I just didn't bother with the entire > path and name). My host is a PC running linux 7.3. Insight is compiled > for host i686-pc-linux-gnu. I agree it looks like it could be trying to > run the executable on the host. > > > > Can you show me a gdb session (command line) of what you're doing (the > > part that works)? Any messages in the debug window? (Open console, > type > > "tk ManagedWin::open DebugWin" to open.) > > See below. > > > > Are you using a stub -- err, debug agent -- or gdbserver. I wasn't > aware > > that gdbserver worked on anything other than native targets. Even if > it > > did, it would almost certainly require a download. > > I'm running gdbserver on the target. This seems to work fine as I've > had success using just gdb with it, plus also with ddd. When I get > Insight to download the program I get similar problems. > > > Here's the gdb session: > > (ManagedWin::_open) TargetSelection -exportcancel 1 -center -transient > (ManagedWin::_create) win=targetselection args=-exportcancel 1 -center > -transient > (TargetSelection::change_target) remotetcp > (ManagedWin::find) SrcWin > (ModalDialog::post) POST ::.targetselection0.targetselection > (ModalDialog::destructor) UNPOST ::.targetselection0.targetselection > (iwidgets::Labeledframe::destructor) In Labeledframe destructor for > ::.targetselection0.targetselection.f.lab, reposition is > (iwidgets::Labeledframe::destructor) In Labeledframe destructor for > ::.targetselection0.targetselection.moreoptionsframe.frame.lf.childsite. > run_method, reposition is > (iwidgets::Labeledframe::destructor) In Labeledframe destructor for > ::.targetselection0.targetselection.moreoptionsframe.frame, reposition > is > (SrcWin::_set_state) gdb_running l=0 d=0 r=0 > (global::gdbtk_attach_remote) Attaching.... > (ManagedWin::find) SrcWin > (SrcBar::enable_ui) 2 - Browsing=0 > (GDBMenuBar::set_class_state) Enable list is: Control disabled Trace > disabled Other normal Attach normal Detach disabled > (GDBToolBar::set_class_state) Enable list is: Control disabled Trace > disabled Other normal Attach normal Detach disabled > (global::set_target) CONNECTING TO TARGET: remote 192.168.0.191:10000 > (SrcWin::_set_state) gdb_loaded l=0 d=0 r=0 > (global::gdbtk_locate_main) Searching MAIN___ MAIN__ main cyg_user_start > cyg_start > (global::run_executable) Setting new BP at main > (GDBEventHandler::GDBEventHandler::dispatch) posting event "breakpoint" > to "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "breakpoint" > to "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "breakpoint" > to "::.srcwin0.srcwin.container.pane0.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "breakpoint" > to "::.srcwin0.srcwin" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "breakpoint" > to "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "breakpoint" > to "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "breakpoint" > to "::.srcwin0.srcwin.container.pane0.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "breakpoint" > to "::.srcwin0.srcwin" > (global::run_executable) Continuing target... > (GDBEventHandler::GDBEventHandler::dispatch) posting event "busy" to > "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "busy" to > "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "busy" to > "::.srcwin0.srcwin.container.pane0.childsite.con" > (SrcBar::enable_ui) 0 - Browsing=0 > (GDBMenuBar::set_class_state) Enable list is: Control disabled Other > disabled Trace disabled Attach disabled Detach disabled > (GDBToolBar::set_class_state) Enable list is: Control disabled Other > disabled Trace disabled Attach disabled Detach disabled > (GDBEventHandler::GDBEventHandler::dispatch) posting event "busy" to > "::.srcwin0.srcwin" > (SrcBar) configuring runstop running > (SrcBar::_set_runstop) running > (global::gdbtk_signal) caught signal SIGSEGV Segmentation fault > (ManagedWin::find) SrcWin > (ManagedWin::_open) WarningDlg -center -transient -message {{Program > received signal SIGSEGV, Segmentation fault}} -ignorable signal > (ManagedWin::_create) win=warningdlg args=-center -transient -message > {{Program received signal SIGSEGV, Segmentation fault}} -ignorable > signal > (WarningDlg::constructor) -message {Program received signal SIGSEGV, > Segmentation fault} -ignorable signal > (ManagedWin::find) SrcWin > (ModalDialog::post) POST ::.warningdlg0.warningdlg > (ModalDialog::destructor) UNPOST ::.warningdlg0.warningdlg > (GDBEventHandler::GDBEventHandler::dispatch) posting event "update" to > "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "update" to > "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "update" to > "::.srcwin0.srcwin.container.pane0.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "update" to > "::.srcwin0.srcwin" > (SrcWin::choose_and_update) chose window ::.srcwin0.srcwin > (SrcWin::_update) loc={} {} {} 0 0x1 0x1 {} > (SrcWin::location) running=0 tag= linespec={} {} {} 0 0x1 0x1 {} > (SrcWin::_set_state) gdb_running l=0 d=0 r=1 > (SrcTextWin::FillSource) no source file; switch to assembly > (GDBEventHandler::GDBEventHandler::dispatch) posting event "busy" to > "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "busy" to > "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "busy" to > "::.srcwin0.srcwin.container.pane0.childsite.con" > (SrcBar::enable_ui) 0 - Browsing=0 > (GDBMenuBar::set_class_state) Enable list is: Control disabled Other > disabled Trace disabled Attach disabled Detach disabled > (GDBToolBar::set_class_state) Enable list is: Control disabled Other > disabled Trace disabled Attach disabled Detach disabled > (GDBEventHandler::GDBEventHandler::dispatch) posting event "busy" to > "::.srcwin0.srcwin" > (SrcBar) configuring runstop running > (SrcBar::_set_runstop) running > (SrcTextWin::mode_set) ASSEMBLY > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.srcwin0.srcwin.container.pane0.childsite.con" > (SrcBar::enable_ui) 1 - Browsing=0 > (GDBMenuBar::set_class_state) Enable list is: Trace disabled Control > normal Other normal Attach disabled Detach normal > (GDBToolBar::set_class_state) Enable list is: Trace disabled Control > normal Other normal Attach disabled Detach normal > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.srcwin0.srcwin" > (SrcBar) configuring runstop normal > (SrcBar::_set_runstop) normal > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.srcwin0.srcwin.container.pane0.childsite.con" > (SrcBar::enable_ui) 1 - Browsing=0 > (GDBMenuBar::set_class_state) Enable list is: Trace disabled Control > normal Other normal Attach disabled Detach normal > (GDBToolBar::set_class_state) Enable list is: Trace disabled Control > normal Other normal Attach disabled Detach normal > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.srcwin0.srcwin" > (SrcBar) configuring runstop normal > (SrcBar::_set_runstop) normal > (global::run_executable) RUNNING > (SrcWin::_set_state) gdb_running l=0 d=0 r=1 > (GDBEventHandler::GDBEventHandler::dispatch) posting event "update" to > "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "update" to > "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "update" to > "::.srcwin0.srcwin.container.pane0.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "update" to > "::.srcwin0.srcwin" > (SrcWin::choose_and_update) chose window ::.srcwin0.srcwin > (SrcWin::_update) loc={} {} {} 0 0x1 0x1 {} > (SrcWin::location) running=1 tag= linespec={} {} {} 0 0x1 0x1 {} > (SrcWin::_set_state) gdb_running l=0 d=0 r=1 > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.srcwin0.srcwin.container.pane2.childsite.con" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.console0.console" > (GDBEventHandler::GDBEventHandler::dispatch) posting event "idle" to > "::.srcwin0.srcwin.container.pane0.childsite.con" > (SrcBar::enable_ui) 1 - Browsing=0 > (GDBMenuBar::set_class_state) Enable list is: Trace disabled Control > normal Other normal Attach disabled Detach normal > (GDBToolBar::set_class_state) Enable list is: Trace disabled Control > normal Other normal Attach disabled Detach normal > (GDBEventHandler::GDBEventHandler::dispatch) posting event "