public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* Way for examining executing code in a different obj file
@ 2005-10-06  1:06 gsaxena
  2005-10-06  1:20 ` Daniel Jacobowitz
  0 siblings, 1 reply; 3+ messages in thread
From: gsaxena @ 2005-10-06  1:06 UTC (permalink / raw)
  To: gdb

Dear folks at GDB,
I have the following program str:

[TXT] Makefile                05-Oct-2005 20:37  646
[TXT] common.h                05-Oct-2005 15:09  213
[TXT] control.cpp             30-Sep-2005 23:42  112
[TXT] control.h               03-Oct-2005 14:21  524
[IMG] image                   29-Sep-2005 20:03   48K
[TXT] init.c                  02-Oct-2005 02:39  4.6K
[TXT] init.h                  29-Sep-2005 20:03  784
[TXT] initfile                02-Oct-2005 02:33  554
[TXT] main.cxx                05-Oct-2005 20:38  5.2K
[   ] main                    05-Oct-2005 20:40  564K
[TXT] node.c                  05-Oct-2005 20:40  2.2K
[TXT] node.h                  03-Oct-2005 14:16  113
[   ] node                    05-Oct-2005 20:40  888K
[TXT] ppm.c                   29-Sep-2005 20:03  3.2K
[TXT] ppm.h                   29-Sep-2005 20:03  310
[DIR] public_html/            05-Oct-2005 18:40    -
[TXT] rand.cpp                02-Oct-2005 00:44  1.0K
[TXT] rand.h                  02-Oct-2005 00:46  122
[TXT] script

main.cxx is the main UserInterface code running libraries from fltk.
node.c is also compiled into an object called node. The node is using
libraries from lam-mpi for parallel operations. When I run the program in
gdb, I can see lines from main.cxx but occasionally the code in node.c is
also executed. I haven't understood how I can access the line nos. I'm not
even sure if it is possible. Could someone let me know what I must do ?

Thanks,
G

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Way for examining executing code in a different obj file
  2005-10-06  1:06 Way for examining executing code in a different obj file gsaxena
@ 2005-10-06  1:20 ` Daniel Jacobowitz
       [not found]   ` <1239.131.123.12.11.1128697249.squirrel@webmail.cs.kent.edu>
  0 siblings, 1 reply; 3+ messages in thread
From: Daniel Jacobowitz @ 2005-10-06  1:20 UTC (permalink / raw)
  To: gsaxena; +Cc: gdb

On Wed, Oct 05, 2005 at 09:06:43PM -0400, gsaxena@cs.kent.edu wrote:
> main.cxx is the main UserInterface code running libraries from fltk.
> node.c is also compiled into an object called node. The node is using
> libraries from lam-mpi for parallel operations. When I run the program in
> gdb, I can see lines from main.cxx but occasionally the code in node.c is
> also executed. I haven't understood how I can access the line nos. I'm not
> even sure if it is possible. Could someone let me know what I must do ?

Have you tried "list file:line", e.g. "list node.c:30"?

-- 
Daniel Jacobowitz
CodeSourcery, LLC

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Way for examining executing code in a different obj file
       [not found]   ` <1239.131.123.12.11.1128697249.squirrel@webmail.cs.kent.edu>
@ 2005-10-07 15:09     ` Daniel Jacobowitz
  0 siblings, 0 replies; 3+ messages in thread
From: Daniel Jacobowitz @ 2005-10-07 15:09 UTC (permalink / raw)
  To: gsaxena; +Cc: gdb

On Fri, Oct 07, 2005 at 11:00:49AM -0400, gsaxena@cs.kent.edu wrote:
> 
> >> main.cxx is the main UserInterface code running libraries from fltk.
> >> node.c is also compiled into an object called node. The node is using
> >> libraries from lam-mpi for parallel operations. When I run the program
> >> in
> >> gdb, I can see lines from main.cxx but occasionally the code in node.c
> >> is
> >> also executed. I haven't understood how I can access the line nos. I'm
> >> not
> >> even sure if it is possible. Could someone let me know what I must do ?
> 
> 
> > Have you tried "list file:line", e.g. "list node.c:30"?
> 
> I think list would only list it for me. I was interested in stepping
> through the other binary, as it does get executed through the main program
> via a system() call. Is there a way to do this ? The node program uses
> lam-mpi libraries in C and the main userinterface code uses C++ library
> from fltk.

You have to run it by hand or attach to it while it's running using the
attach command.

-- 
Daniel Jacobowitz
CodeSourcery, LLC

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-10-07 15:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-10-06  1:06 Way for examining executing code in a different obj file gsaxena
2005-10-06  1:20 ` Daniel Jacobowitz
     [not found]   ` <1239.131.123.12.11.1128697249.squirrel@webmail.cs.kent.edu>
2005-10-07 15:09     ` Daniel Jacobowitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).