Search results for

“LLDB crash”

30,536 results found

Post

Replies

Boosts

Views

Activity

Reply to lldb: argument starting with hash disappears.
It’s better to reply as a reply, rather than in the comments; see Quinn’s Top Ten DevForums Tips for this and other titbits. so the -X shell processing in lldb is different to the actual shell. Yes. This is LLDB’s idea of shell processing; it doesn’t invoke an actual shell. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Feb ’25
Reply to Error when debugging: Cannot create Swift scratch context
Trying to learn Swift and use debugging. On Xcode Version 12.3 (12C33) any time debugger is entered (on device simulator, or an actual device): Cannot create Swift scratch context (couldn't create a ClangImporter) (lldb) po symbol in the (lldb) prompt doesn't work. And so no Swift objects or symbols are available; only an Objective C-type view of them. This is very annoying! and makes the debugger and debugging basically worthless in Xcode for Swift. On an M1 Mac mini. I completely uninstalled Xcode and deleted preferences and other developer directories from ~/Library. and re-installed Xcode (from app store). I scoured here and stack overflow for workarounds or diagnoses and nothing has worked. $ system_profiler SPSoftwareDataType Software: ttSystem Software Overview: tttSystem Version: macOS 11.1 (20C69) tttKernel Version: Darwin 20.2.0 tttBoot Volume: Macintosh HD tttBoot Mode: Normal tttComputer Name: * tttUser Name: * tttSecure Virtual Memory: Enabled tttSystem Integrity Protection: Ena
Jan ’21
Reply to mac-to-mac remote debugging
When folks talk about remote debugging they usually mean one of three things: Remote debugging using Xcode (A) Remove debugging using lldb and debugserver (B) Remove debugging using lldb over SSH (C) There is currently no supported way to do A (r. 7476048 ). With regards B, it’s possible to do and you’ll find various instructions out there on the ’net. My experience, however, is that it’s not worth the effort. Given that you have to use command-line LLDB anyway, you end up with a much nicer debugging experience if you do C. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Jun ’21
Reply to Why aren't negative generic parameters possible in Swift?
The following should answer your question:protocol X { } extension X { func foo() { print(I'm an X foo) } } protocol Y { } extension Y { func foo() { print(I'm a Y foo) } } protocol Z { func foo() } struct Foo: Z, X, Y { }For your conveniece, is the playground output:Playground execution failed: /var/folders/rv/mwcdgk492x7g23_0byfwyjtw0000gn/T/./lldb/1444/playground261.swift:44:8: error: type 'Foo' does not conform to protocol 'Z' struct Foo: Z, X, Y ^ /var/folders/rv/mwcdgk492x7g23_0byfwyjtw0000gn/T/./lldb/1444/playground261.swift:41:10: note: multiple matching functions named 'foo()' with type '() -> ()' func foo() ^ /var/folders/rv/mwcdgk492x7g23_0byfwyjtw0000gn/T/./lldb/1444/playground261.swift:33:10: note: candidate exactly matches func foo() ^ /var/folders/rv/mwcdgk492x7g23_0byfwyjtw0000gn/T/./lldb/1444/playground261.swift:20:10: note: candidate exactly matches func foo() ^
Topic: Programming Languages SubTopic: Swift Tags:
Jul ’15
Reply to Problem when trying to debug with lldb on new arm64 M1
You should be able to set up a command-line build environment without GUI access to the machine. Here’s the process I used… I set up a victim machine that had never seen Apple’s developer tools. This was a VM running macOS 11.1 (this is Intel, but I don’t believe that Apple silicon would change this story). I used my main machine to download the Command Line Tools for Xcode 12.4 package from the Downloads area - https://developer.apple.com/download/ on the developer web site Note Click More (at the top right) to get to the archive. I copied the resulting disk image to the victim VM. % scp Command_Line_Tools_for_Xcode_12.4.dmg virtual-big.local.: On the victim VM I mounted the disk image: % hdiutil attach Command_Line_Tools_for_Xcode_12.4.dmg IMPORTANT I’m using an admin account here. If you don’t have an admin account, see below. I then installed the package: % sudo installer -pkg /Volumes/Command Line Developer Tools/Command Line Tools.pkg -target / I ran DevToolsSecurity to enable developer mode: % sudo Dev
Apr ’21
Reply to Xcode 12.2 Beta 3 on macOS 11 Beta 11: SIGCONT when debugging projects
This has been bugging me all afternoon. I had also just installed macOS 11b10 (20A5395g). In a post from 9 months ago, Quinn shows that - https://developer.apple.com/forums/thread/127650 lldb will stop at SIGCONT by default and suggests a temporary workaround: (lldb) process handle -n false -s false SIGCONT I tried and failed to get this to work in my .lldbinit, then found this old SO post - https://stackoverflow.com/a/16993602/1034477: At present the suggestion of doing this in a breakpoint command on main is the most elegant solution available. I added a symbolic breakpoint for main that runs the above debugger command and continues. It fixes the annoying issue of the debugger pausing immediately, although lldb-rpc-server will still use an entire CPU core while doing nothing…
Oct ’20
Help! lldb po command suddenly stopped working
For no apparent reason the po command has stopped working. It simply produces no output, no errors, nowt! I haven't changed Xcode (I am using v12 beta 3 for new work and v12.2 for production. Both are failing. The problem began today with v12.2 while I was working with the Test App. I've tried a clean build, restarting Xcode and rebooting. I've even tried it on a production app with the same results. So, at this point in time I am scuppered. Any suggestions most welcome.
1
0
1.5k
Dec ’20
Reply to Xcode breaks with SIGCONT before OpenURL handler is called
Hmmm, the SIGCONT is weird. I’m not entirely sure what that’s about. It is, however, innocuous at runtime, meaning that this is the main issue: This causes automated tests to break, and is generally a pain in the you-know-where. Does disabling this in LLDB work? For more on this, see: (lldb) help process handle Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Topic: UI Frameworks SubTopic: AppKit Tags:
Mar ’21
Reply to lldb error import six
Does LLDB behave itself when you invoke it from Xcode? That is, if you create a new Mac project and do a Product > Run, does the debugger function?In Terminal, if you do a printenv, do you see anything obvious that might affect the copy of Python running with LLDB (like a PYTHONPATH environment variable pointing)? Share and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Jan ’20
Reply to Not sure where to start with Accessibility crash
I added a category method to UIView called floating to see if I could get any information about the caller or the context. Every time, I get a view with no superview, and a single UILabel subview (textless, unfortunately). (lldb) po self <UIView: 0x7f7fc7f02160; frame = (0 0; 320 10); layer = <CALayer: 0x618000629020>> (lldb) po self.subviews <__NSArrayM 0x618000a44350>( <UILabel: 0x7f7fc7f02810; frame = (10 0; 310 10); opaque = NO; userInteractionEnabled = NO; layer = <_UILabelLayer: 0x618000482940>> ) (lldb) po self.superview 0x0000000000000000I'm getting four calls to this method per UITableViewCell in my table, and it happens regardless of whether I'm in a table with standard or custom UITableView cells. Anyone know what -[UITableViewAccessibility _accessibilitySortedElementsWithin] might be doing with such a view?
Nov ’16
Reply to lldb: argument starting with hash disappears.
It’s better to reply as a reply, rather than in the comments; see Quinn’s Top Ten DevForums Tips for this and other titbits. so the -X shell processing in lldb is different to the actual shell. Yes. This is LLDB’s idea of shell processing; it doesn’t invoke an actual shell. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Replies
Boosts
Views
Activity
Feb ’25
Reply to how do i fix the sigabrt error?
Yes. Type that command right after the blue (lldb) prompt and post what prints out.
Replies
Boosts
Views
Activity
Aug ’15
Reply to Unable to properly attach to executable with lldb running under Rosetta
For some reason i'm unable to attach lldb log, so will add it as a link https://pastebin.com/nWZEwV0p
Replies
Boosts
Views
Activity
Jul ’23
Reply to Debug Failed in Xcode Simulator
same for me, on 15.4 Beta (24E5222f) (converted to TXT) lldb-rpc-server-2025-03-10-104310.txt
Replies
Boosts
Views
Activity
Mar ’25
Reply to Error when debugging: Cannot create Swift scratch context
Trying to learn Swift and use debugging. On Xcode Version 12.3 (12C33) any time debugger is entered (on device simulator, or an actual device): Cannot create Swift scratch context (couldn't create a ClangImporter) (lldb) po symbol in the (lldb) prompt doesn't work. And so no Swift objects or symbols are available; only an Objective C-type view of them. This is very annoying! and makes the debugger and debugging basically worthless in Xcode for Swift. On an M1 Mac mini. I completely uninstalled Xcode and deleted preferences and other developer directories from ~/Library. and re-installed Xcode (from app store). I scoured here and stack overflow for workarounds or diagnoses and nothing has worked. $ system_profiler SPSoftwareDataType Software: ttSystem Software Overview: tttSystem Version: macOS 11.1 (20C69) tttKernel Version: Darwin 20.2.0 tttBoot Volume: Macintosh HD tttBoot Mode: Normal tttComputer Name: * tttUser Name: * tttSecure Virtual Memory: Enabled tttSystem Integrity Protection: Ena
Replies
Boosts
Views
Activity
Jan ’21
Reply to mac-to-mac remote debugging
When folks talk about remote debugging they usually mean one of three things: Remote debugging using Xcode (A) Remove debugging using lldb and debugserver (B) Remove debugging using lldb over SSH (C) There is currently no supported way to do A (r. 7476048 ). With regards B, it’s possible to do and you’ll find various instructions out there on the ’net. My experience, however, is that it’s not worth the effort. Given that you have to use command-line LLDB anyway, you end up with a much nicer debugging experience if you do C. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Replies
Boosts
Views
Activity
Jun ’21
Reply to Why aren't negative generic parameters possible in Swift?
The following should answer your question:protocol X { } extension X { func foo() { print(I'm an X foo) } } protocol Y { } extension Y { func foo() { print(I'm a Y foo) } } protocol Z { func foo() } struct Foo: Z, X, Y { }For your conveniece, is the playground output:Playground execution failed: /var/folders/rv/mwcdgk492x7g23_0byfwyjtw0000gn/T/./lldb/1444/playground261.swift:44:8: error: type 'Foo' does not conform to protocol 'Z' struct Foo: Z, X, Y ^ /var/folders/rv/mwcdgk492x7g23_0byfwyjtw0000gn/T/./lldb/1444/playground261.swift:41:10: note: multiple matching functions named 'foo()' with type '() -> ()' func foo() ^ /var/folders/rv/mwcdgk492x7g23_0byfwyjtw0000gn/T/./lldb/1444/playground261.swift:33:10: note: candidate exactly matches func foo() ^ /var/folders/rv/mwcdgk492x7g23_0byfwyjtw0000gn/T/./lldb/1444/playground261.swift:20:10: note: candidate exactly matches func foo() ^
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Jul ’15
Reply to Problem when trying to debug with lldb on new arm64 M1
You should be able to set up a command-line build environment without GUI access to the machine. Here’s the process I used… I set up a victim machine that had never seen Apple’s developer tools. This was a VM running macOS 11.1 (this is Intel, but I don’t believe that Apple silicon would change this story). I used my main machine to download the Command Line Tools for Xcode 12.4 package from the Downloads area - https://developer.apple.com/download/ on the developer web site Note Click More (at the top right) to get to the archive. I copied the resulting disk image to the victim VM. % scp Command_Line_Tools_for_Xcode_12.4.dmg virtual-big.local.: On the victim VM I mounted the disk image: % hdiutil attach Command_Line_Tools_for_Xcode_12.4.dmg IMPORTANT I’m using an admin account here. If you don’t have an admin account, see below. I then installed the package: % sudo installer -pkg /Volumes/Command Line Developer Tools/Command Line Tools.pkg -target / I ran DevToolsSecurity to enable developer mode: % sudo Dev
Replies
Boosts
Views
Activity
Apr ’21
Reply to Xcode 12.2 Beta 3 on macOS 11 Beta 11: SIGCONT when debugging projects
This has been bugging me all afternoon. I had also just installed macOS 11b10 (20A5395g). In a post from 9 months ago, Quinn shows that - https://developer.apple.com/forums/thread/127650 lldb will stop at SIGCONT by default and suggests a temporary workaround: (lldb) process handle -n false -s false SIGCONT I tried and failed to get this to work in my .lldbinit, then found this old SO post - https://stackoverflow.com/a/16993602/1034477: At present the suggestion of doing this in a breakpoint command on main is the most elegant solution available. I added a symbolic breakpoint for main that runs the above debugger command and continues. It fixes the annoying issue of the debugger pausing immediately, although lldb-rpc-server will still use an entire CPU core while doing nothing…
Replies
Boosts
Views
Activity
Oct ’20
XCode13.3 po freezes in lldb ,using Chinese input
Device 2021 MacBook Pro 16' MacOS 12.2 RAM 32G M1 Max
Replies
4
Boosts
0
Views
1.7k
Activity
Mar ’22
Help! lldb po command suddenly stopped working
For no apparent reason the po command has stopped working. It simply produces no output, no errors, nowt! I haven't changed Xcode (I am using v12 beta 3 for new work and v12.2 for production. Both are failing. The problem began today with v12.2 while I was working with the Test App. I've tried a clean build, restarting Xcode and rebooting. I've even tried it on a production app with the same results. So, at this point in time I am scuppered. Any suggestions most welcome.
Replies
1
Boosts
0
Views
1.5k
Activity
Dec ’20
Reply to TVOS UITextView is not scrolling
Hmmm yeah the result is NO despite being checked in the IB storyboard.(lldb) po [_moveArea isSelectable]NO
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Sep ’15
Reply to Xcode breaks with SIGCONT before OpenURL handler is called
Hmmm, the SIGCONT is weird. I’m not entirely sure what that’s about. It is, however, innocuous at runtime, meaning that this is the main issue: This causes automated tests to break, and is generally a pain in the you-know-where. Does disabling this in LLDB work? For more on this, see: (lldb) help process handle Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Topic: UI Frameworks SubTopic: AppKit Tags:
Replies
Boosts
Views
Activity
Mar ’21
Reply to lldb error import six
Does LLDB behave itself when you invoke it from Xcode? That is, if you create a new Mac project and do a Product > Run, does the debugger function?In Terminal, if you do a printenv, do you see anything obvious that might affect the copy of Python running with LLDB (like a PYTHONPATH environment variable pointing)? Share and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Replies
Boosts
Views
Activity
Jan ’20
Reply to Not sure where to start with Accessibility crash
I added a category method to UIView called floating to see if I could get any information about the caller or the context. Every time, I get a view with no superview, and a single UILabel subview (textless, unfortunately). (lldb) po self <UIView: 0x7f7fc7f02160; frame = (0 0; 320 10); layer = <CALayer: 0x618000629020>> (lldb) po self.subviews <__NSArrayM 0x618000a44350>( <UILabel: 0x7f7fc7f02810; frame = (10 0; 310 10); opaque = NO; userInteractionEnabled = NO; layer = <_UILabelLayer: 0x618000482940>> ) (lldb) po self.superview 0x0000000000000000I'm getting four calls to this method per UITableViewCell in my table, and it happens regardless of whether I'm in a table with standard or custom UITableView cells. Anyone know what -[UITableViewAccessibility _accessibilitySortedElementsWithin] might be doing with such a view?
Replies
Boosts
Views
Activity
Nov ’16