This is the mail archive of the
gdb-prs@sources.redhat.com
mailing list for the GDB project.
gdb/329: stack tracing and breakpoints don't work properly if no debugging symbols
- From: don at sandvine dot com
- To: gdb-gnats at sources dot redhat dot com
- Date: 2 Feb 2002 21:36:22 -0000
- Subject: gdb/329: stack tracing and breakpoints don't work properly if no debugging symbols
- Reply-to: don at sandvine dot com
>Number: 329
>Category: gdb
>Synopsis: stack tracing and breakpoints don't work properly if no debugging symbols
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Feb 02 13:38:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator: don@sandvine.com
>Release: 5.1.1
>Organization:
>Environment:
target=mips-wrs-vxworks
cross from cygwin
>Description:
vxWorks target image is comprised of many source files. Some are compiled with -g, some are not.
If I take a symbol which is not compiled with -g (e.g. printf), and from the gdb shell put a breakpoint, I get an incorrect address for the breakpoint.
The error seems to come from linespec.c:1212, in the decode_line_1(). It looks up the symbol with lookup_minimal_symbol(), which is correct, and it gets
a correct result. It then calls find_pc_sect_line(), which returns an incorrect address (from some other module with -g on). This address is then used for the breakpoint.
>How-To-Repeat:
Build an image with a file without -g. Put a breakpoint on a function in this non-g file, check that the address matches expected.
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted: