LLDB has the concept of parent and child breakpoints. This is necessary because the breakpoint specification (what to actually break on) can match multiple locations in memory, and that list of locations can vary over time as code is loaded and unloaded.
The parent breakpoint is identified by a number (1, 2, and so on) and the child breakpoints are identified by a pair of numbers (1.1, 1.2, 1.3, 2.1, and so on).
For an extreme example of this, use the Xcode user interface to set a symbolic breakpoint on open. When you run your program, it’ll hit a breakpoint almost immediately. Now dump the list of breakpoints using
br list
:
(lldb) br list
Current breakpoints:
1: name = 'open', locations = 132, resolved = 132, hit count = 1
1.1: where = xxst`Darwin.open(Swift.UnsafePointer<Swift.Int8>, Swift.Int32, Swift.UInt16) -> Swift.Int32, address = 0x0000000100008b20, resolved, hit count = 0
1.2: where = xxst`Darwin.open(Swift.UnsafePointer<Swift.Int8>, Swift.Int32) -> Swift.Int32, address = 0x0000000100008b10, resolved, hit count = 0
1.3: where = libc++.1.dylib`std::__1::messages<char>::open(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::locale const&) const, address = 0x00007fff69658af0, resolved, hit count = 0
1.4: where = libc++.1.dylib`std::__1::messages<wchar_t>::open(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::locale const&) const, address = 0x00007fff69658cfe, resolved, hit count = 0
1.5: where = Foundation`-[NSStream(NSStream) open], address = 0x00007fff4127bcd5, resolved, hit count = 0
1.6: where = Foundation`-[NSCFInputStream open], address = 0x00007fff4127bf1f, resolved, hit count = 0
1.7: where = Foundation`-[NSCFOutputStream open], address = 0x00007fff4127c260, resolved, hit count = 0
1.8: where = CoreFoundation`-[__NSCFOutputStream open], address = 0x00007fff3edab3e7, resolved, hit count = 0
1.9: where = CoreFoundation`-[__NSCFInputStream open], address = 0x00007fff3edbf88e, resolved, hit count = 0
1.10: where = libsystem_kernel.dylib`__open, address = 0x00007fff6c539148, resolved, hit count = 1
1.11: where = CFNetwork`std::__1::basic_ifstream<char, std::__1::char_traits<char> >::open(char const*, unsigned int), address = 0x00007fff3dbc7c82, resolved, hit count = 0
… lots of other entries elided …
(lldb)
That’s a lot of breakpoints!
This list is also reflected in Xcode. If you go to the breakpoints navigator and disclose the twiddle triangle next to open, you’ll see 132 items. Normally I just collapse the twiddle triangle to hide all of these items and move on, but in some cases it’s nice to work with specific ones. To continue the example above, I’d probably want to disable all of the breakpoints except 1.10.
As to what’s going on in your specific case, it’s hard to say without knowing more details. I suspect that the above might be enough to get you going, but if not you should post the result from
br list
and I’ll take a look.
Share and Enjoy
—
Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware
let myEmail = "eskimo" + "1" + "@apple.com"