This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: How do I set breakpoints on all lines for a particular file.
- From: Ramana Radhakrishnan <ramana dot radhakrishnan at codito dot com>
- To: "Kotian, Deepak" <Deepak dot Kotian at patni dot com>, "Andrew Cagney" <cagney at gnu dot org>
- Cc: <gdb at sources dot redhat dot com>
- Date: Sun, 29 Feb 2004 16:03:37 +0530
- Subject: Re: How do I set breakpoints on all lines for a particular file.
- Organization: Codito Technologies
- References: <374639AB1012AA4C840022842AA95BC2015ABFE8@ruby.patni.com>
- Reply-to: ramana at codito dot com
On Sunday 29 February 2004 13:45, Kotian, Deepak wrote:
> Break at all functions in a particular file(.c file), can it be done?
If you have the corresponding object file , maybe you can write a shell / awk
/ perl script to generate this using objdump -t and finding out the function
symbols and using that in a gdb script and then include that using the source
command.
Dont know of any other way of setting breakpoints with respect to all
functions in the file you need.
cheers
ramana
>
> Thanks and Regards
> Deepak
>
>
> -----Original Message-----
> From: Andrew Cagney [mailto:cagney@gnu.org]
> Sent: Sunday, February 29, 2004 9:34 AM
> To: Kotian, Deepak
> Cc: gdb@sources.redhat.com
> Subject: Re: How do I set breakpoints on all lines for a particular
> file.
>
> > How do I set breakpoints in gdb on all lines for a a target program file.
> > Basically, I need to know if any code segment is executed from
> > that file.
>
> Other than explicitly setting a breakpoint on every line, I don't know.
>
> Andrew