Re: Stack trace for i386 yet?
Re: Stack trace for i386 yet?
- Subject: Re: Stack trace for i386 yet?
- From: Steve Checkoway <email@hidden>
- Date: Mon, 17 Jul 2006 00:36:18 -0700
On Jul 16, 2006, at 11:52 PM, Andy Wiese wrote:
Is there a commonly known solution for constructing a backtrace for
i386? With the tips generously provided by Rush Manbert on
2006/04/21, I tried using gcc __builtin_return_address, but just as
the documentation implies, the results are wacky for anything but a
very simple demo application. We have previously used the
MoreBackTrace code from the MoreIsBetter library, but the most
current word I can find in list archives is that Quinn has been
working on an intel port but it is not released yet.
I've found that __builtin_return_address(0) was failing on ppc. I
couldn't produce a test case that exhibited the problem so instead I
have this in my code:
/* __builtin_frame_address is broken on OS X; it sometimes
returns bogus results. */
register void *r1 __asm__ ("r1");
which does work.
As for i386, I've got code that will produce a backtrace for both
windows and linux i386 but I haven't been able to get it to work for
OS X yet. (Actually, I don't have any way to test.)
Just wondering if there is any common lore out there that I have
missed on the subject,
I haven't heard anything new, but I'm also interested.
--
Steve Checkoway
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden