From: Rene Limberger <rlimberger@mac.com>
To: gdb@sourceware.org
Subject: implementation of backtrace on OSX?
Date: Tue, 16 Oct 2007 04:39:00 -0000 [thread overview]
Message-ID: <BB68D0D3-D1CD-4C06-BCDD-7A2CA2F98E73@mac.com> (raw)
hi,
can anyone give me some pointers to where in the source code the gdb
backtrace is generated? ion linux, there is backtrace() via
execinfo.h, unfortunately this is not available on OSX and i would
like to take a peak at how gdb implements what we get when we type
"bt". so for example:
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000000
[Switching to process 31347 thread 0x3303]
0x001e9f1d in somefnc ()
(gdb) bt
#0 0x001e9f1d in somefnc ()
#1 0x003291ac in call_something (n=0x611ca0, something=0xb02267b4) at
somefile.c:47
...
#11 0x93b853a1 in _pthread_start ()
#12 0x93b8525e in thread_start ()
i am specifically interested in how gdb resolves the file and line
number from the debug info.
thanks,
-r
next reply other threads:[~2007-10-16 4:39 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-16 4:39 Rene Limberger [this message]
2007-10-16 11:43 ` Daniel Jacobowitz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=BB68D0D3-D1CD-4C06-BCDD-7A2CA2F98E73@mac.com \
--to=rlimberger@mac.com \
--cc=gdb@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox