On 25 May 2013, at 5:02 AM, Martin Hewitson <martin.hewit...@aei.mpg.de> wrote:

> On May 24, 2013, at 08:15 PM, Chris Ridd <chrisr...@mac.com> wrote:
> …
>> Try setting a breakpoint on strtoull_l and see what kind of arguments it is 
>> getting.
> 
> OK, I far from being expert on using lldb, so how to I do this? I made a 
> symbolic breakpoint on strtoull_l but Xcode doesn't show any local variables 
> - how do I get to see the arguments being passed?

You want TN2124, "Mac OS X Debugging Magic" 
<http://developer.apple.com/library/mac/#technotes/tn2124/_index.html>, in the 
Some Assembly Required section. It shows how you can use the ABI to pull 
arguments.

There will probably be a lot of calls, so I'd set the breakpoint to not pause 
the program, and attach debugger commands to print the argument values. The 
transcript will be huge, but the only report you're interested in is the last 
one.

There's probably something awesome you can do with DTrace, which I'd turn to if 
the lldb approach didn't work, but I don't have the chops to suggest a script 
off the top of my head.

        — F

-- 
Fritz Anderson
Xcode 4 Unleashed: 4.5 supplement for free!
http://www.informit.com/store/xcode-4-unleashed-9780672333279


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to