How can I get the Xcode debugger to step into the assembly of a function?

Viewed 358

Whenever I try to step into a function for which I don't have the source code, e.g. anything in an Apple library, the debugger just skips to the next line. How can I have it go into the assembly instead? I can workaround this by setting a symbolic breakpoint for the function that I want to step into, but this is less convenient.

1 Answers

Hold Control when pressing the step controls. Works for me in Xcode 12.

The stepping controls have alternative operations for working with disassembly or threads. You use the Control and Control-Shift modifier keys to call these alternatives. Press Control to step by assembly language instruction instead of by statement (the step icons change to show a dot rather than a line under the arrow) or Control-Shift to step into or over the active thread only while holding other threads stopped (the step icons show a dashed rather than solid line below the arrow).

https://developer.apple.com/library/archive/documentation/DeveloperTools/Conceptual/debugging_with_xcode/chapters/debugging_tools.html

Related