Search results for

“LLDB crash”

30,529 results found

Post

Replies

Boosts

Views

Activity

Reply to XPC as plain IPC, no launchd involved
Incidentally — I am playing with the login item to test the hack, and I have found that there's some pretty convenient trickery, probably at lldb level:if my login item is launched properly (i.e., through SMLoginItemSetEnabled), it works as expected;if my login item is launched manually (e.g., by running its executable from Terminal), it does not work, the service is invalidated — fully as expected, of course;if my login item is run by Xcode (or manually in lldb) though, the XPC communication does work!That's a really nice surprise; I have expected to debug, I would have to launch the login item through SMLoginItemSetEnabled, and to connect lldb to its pid. Kudos to whomever designed/implemented this little trick!
Jun ’18
Reply to Xcode breaks with SIGCONT before OpenURL handler is called
Well, if I set process handle -s false SIGCONT At application load, then the test continues without entering the debugger. That doesn't help by itself because it still requires manual intervention at multiple points during the test suite. I haven't found any good documentation on custom LLDB settings, especially settings that take effect after the process is running. I've verified that .lldbinit is read on start of the testing and again when the process enters the SIGCONT break point. The problem is that the process handle . . . command is target-specific, and can't be run without a target. Even when breaking for SIGCONT I get an error about an invalid target for that command. Is there any documentation on how to override LLDB behavior from a configuration file, including commands which only take effect in a specific process? For example when LLDB attaches to a target do X. A way to change global LLDB behavior would also be good if one exists.
Topic: UI Frameworks SubTopic: AppKit Tags:
Mar ’21
Reply to Can't add category method in SKPhysicsWorld
Duh, I assumed that PKPhysicsWorld was a typo, but I just tried adding the category and found out this is the class name. It turns out that Sprite Kit is playing shenanigans with classes:(lldb) po [self.physicsWorld className] PKPhysicsWorld (lldb) po self.physicsWorld.superclass NSObject (lldb) p [self.physicsWorld isKindOfClass: [SKPhysicsWorld class]] (char) $1 = 'x01'So it's not a SKPhysicsWorld class cluster, and PKPhysicsWorld is not a subclass of SKPhysicsWorld, but it does pose as a SKPhysicsWorld!If you must add the method, you might be able to do so by manipulating the Obj-C runtime metadata directly, but it doesn't seem like a good way, going forward.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Feb ’18
Reply to UITextField asserts in console on keyboard long press
@frameworksengineer I'm also running into this in iOS 15 in a UIKit app. When it happens the textField isn't visible anymore, although I still see it in the View Debugger. I think it happens when I enter some text and then tap outside the textField. I see the Assert warnings a number of times and also this one: WARNING: Calling updateFocusIfNeeded while a focus update is in progress. This call will be ignored. I did what you ask and the UITextField.interactions[UITextInteraction].textInput property is simply the UITextField. (lldb) po (UITextField*)0x7f9fd7c2d200 ; text = '1.99'; borderStyle = None; background = <_UITextFieldNoBackgroundProvider: 0x7f9fe29e0120: textfield=>; layer = > (lldb) po ((UITextField*)0x7f9fd7c2d200).interactions <__NSArrayI 0x7f9fccbb1600>( , , <_UITextMenuLinkInteraction: 0x7f9fc6880dd0>, , <_UIClickPresentationInteraction: 0x7f9fc68819e0>, , <_UIKeyboardBasedTextSelectionInteraction: 0x7f9fc4b71ef0>, , , , , , , ) (lldb)
Topic: UI Frameworks SubTopic: UIKit Tags:
Jan ’22
Single-Stepping in LLDB Doesn't Work on M1 Hardware
The instruction pointer jumps all over the place when single-stepping through iOS Objective-C code on M1 hardware (Big Sur 11.2, Xcode 12.4). I tested on an M1 MacBook Air and an M1 MacMini and get the same behavior (running my app on a simulator or iPad hardware). All compiler, linker, etc. optimizations (that I know about) are turned off. Anyone else having this problem? Anyone have a work-around?
0
0
1.3k
Feb ’21
Reply to XCode 13.3 stuck when input Chinese in lldb console
I already had a radar: FB9958917 Thanks for filing that. Some notes: We can definitely reproduce it in-house. It seems to be related to Xcode’s console pane, not LLDB itself. If running lldb from the command-line is an option for you, that’s a simple workaround. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Apr ’22
Attach lldb debugger to the compiled program's executable when the main executable is not the compiled program
I am building an MPI C project in Xcode. In order to do run it, I had to: Specify /path/to/mpiexec in Edit Scheme -> Run -> Info -> Executable, instead of the default one, say myprogram if my target is called myprogram. Specify the following arguments in Edit Scheme -> Run -> Arguments -> Arguments Passed On Launch: -np 4, ${BUILT_PRODUCTS_DIR}/${EXECUTABLE_NAME} This is clearly analogous to a mpiexec -np 4 a.out command launched on terminal. The problem is, when I want to debug my application, the execution doesn't stop on the breakpoints. I instantly thought that it is because of the check box Debug Executable in Edit Scheme -> Run -> Info -> Executable. Indeed (as I have just said), the Executable specified in there is mpiexec and not myprogram. Thus, is there an option or some command I could set in Xcode to attach the lldb to myprogram?
2
0
626
Oct ’24
Xcode debugger crashes on breakpoint
Hello,We are having a systematic crash of the lldb-rpc-server when debugging our project, so we are unable to use the debugger. The crash is as follow:https://gist.github.com/bvirlet/89ecb0388c659932f5b572fa0d79e4f5I have submitted a crash report to Apple (FB7671116) but in the meantime I would be interested in a possible workaround.The problem is present for several developers, on different machines.Thanks!Bruno
0
0
782
Apr ’20
How to get my extension’s process ID of the dext for debugging with lldb
I've asked this question in Stackoverflow, but no response, so I ask for help in here. I follow this guide Debugging and testing system extensions, and try to debug my dext code. In the Attach the debugger to your system extension, it said After your system extension launches, run the ps command-line tool and note your extension’s process ID. This is the current output for my dext status % systemextensionsctl list 1 extension(s) --- com.apple.system_extension.driver_extension enabled active teamID bundleID (version) name [state] * * K3TDMD9Y6B com.accusys.scsidriver (1.0/1) com.accusys.scsidriver [activated enabled] and I used the ps command but nothing happen, I can not get my extension’s process ID. ps aux | grep com.accusys.scsidriver or ps -ef | grep com.accusys.scsidriver How to do that? Any suggestion is appreciated.
1
0
712
Dec ’24
Reply to Can't change background task identifier
My understanding is that you’re doing this: Run app with identifier A. Test it from LLDB. It works. Change the app to use identifier B. Test it from LLDB. It fails. If you delete the app from the device between steps 3 and 4, does that help? Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Topic: App & System Services SubTopic: Core OS Tags:
Jan ’24
Reply to Under stress tests, our Network Extension crashed due to QOS?
Anything I should look for or do, other than telling lldb to attach to the correct pid, and wait for a crash? That’s the obvious place to start. If you want to write more code you could: Investigate core dumps. Install a SIGABRT signal handler than stops the process to allow you to attach. Disable SIP and start messing around with DTrace. We might get to that point, but they all see like overkill right now. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Feb ’24
Reply to XCode15 debugger is working really slow with iOS 17.0.2
After spending several hours profiling lldb, I have identified the reason behind the high CPU usage and slow app launch and breakpoints. It turns out that a custom xcconfig file was disabling dSYM for the Debug build. However, once I restored the dSYM in the Derived Data Xcode, both lldb and our app started up quickly again.
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Nov ’23
Xcode15.2 LLDB 太慢了,简直无法工作
Xcode15.2 LLDB 太慢了,简直无法工作,好几分钟才断点出变量传,然后断点无法跳出继续执行。Xcode14.1则不会有这些问题,望修复。
Replies
2
Boosts
0
Views
1.2k
Activity
Feb ’24
Reply to XPC as plain IPC, no launchd involved
Incidentally — I am playing with the login item to test the hack, and I have found that there's some pretty convenient trickery, probably at lldb level:if my login item is launched properly (i.e., through SMLoginItemSetEnabled), it works as expected;if my login item is launched manually (e.g., by running its executable from Terminal), it does not work, the service is invalidated — fully as expected, of course;if my login item is run by Xcode (or manually in lldb) though, the XPC communication does work!That's a really nice surprise; I have expected to debug, I would have to launch the login item through SMLoginItemSetEnabled, and to connect lldb to its pid. Kudos to whomever designed/implemented this little trick!
Replies
Boosts
Views
Activity
Jun ’18
Reply to Xcode breaks with SIGCONT before OpenURL handler is called
Well, if I set process handle -s false SIGCONT At application load, then the test continues without entering the debugger. That doesn't help by itself because it still requires manual intervention at multiple points during the test suite. I haven't found any good documentation on custom LLDB settings, especially settings that take effect after the process is running. I've verified that .lldbinit is read on start of the testing and again when the process enters the SIGCONT break point. The problem is that the process handle . . . command is target-specific, and can't be run without a target. Even when breaking for SIGCONT I get an error about an invalid target for that command. Is there any documentation on how to override LLDB behavior from a configuration file, including commands which only take effect in a specific process? For example when LLDB attaches to a target do X. A way to change global LLDB behavior would also be good if one exists.
Topic: UI Frameworks SubTopic: AppKit Tags:
Replies
Boosts
Views
Activity
Mar ’21
Reply to Can't add category method in SKPhysicsWorld
Duh, I assumed that PKPhysicsWorld was a typo, but I just tried adding the category and found out this is the class name. It turns out that Sprite Kit is playing shenanigans with classes:(lldb) po [self.physicsWorld className] PKPhysicsWorld (lldb) po self.physicsWorld.superclass NSObject (lldb) p [self.physicsWorld isKindOfClass: [SKPhysicsWorld class]] (char) $1 = 'x01'So it's not a SKPhysicsWorld class cluster, and PKPhysicsWorld is not a subclass of SKPhysicsWorld, but it does pose as a SKPhysicsWorld!If you must add the method, you might be able to do so by manipulating the Obj-C runtime metadata directly, but it doesn't seem like a good way, going forward.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Replies
Boosts
Views
Activity
Feb ’18
Reply to UITextField asserts in console on keyboard long press
@frameworksengineer I'm also running into this in iOS 15 in a UIKit app. When it happens the textField isn't visible anymore, although I still see it in the View Debugger. I think it happens when I enter some text and then tap outside the textField. I see the Assert warnings a number of times and also this one: WARNING: Calling updateFocusIfNeeded while a focus update is in progress. This call will be ignored. I did what you ask and the UITextField.interactions[UITextInteraction].textInput property is simply the UITextField. (lldb) po (UITextField*)0x7f9fd7c2d200 ; text = '1.99'; borderStyle = None; background = <_UITextFieldNoBackgroundProvider: 0x7f9fe29e0120: textfield=>; layer = > (lldb) po ((UITextField*)0x7f9fd7c2d200).interactions <__NSArrayI 0x7f9fccbb1600>( , , <_UITextMenuLinkInteraction: 0x7f9fc6880dd0>, , <_UIClickPresentationInteraction: 0x7f9fc68819e0>, , <_UIKeyboardBasedTextSelectionInteraction: 0x7f9fc4b71ef0>, , , , , , , ) (lldb)
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
Boosts
Views
Activity
Jan ’22
Reply to Is my copy of lldb up-to-date?
Latest release version appears to be: lldb-340.4.119OSX 10.11.2, Xcode 7.2 release
Replies
Boosts
Views
Activity
Dec ’15
Single-Stepping in LLDB Doesn't Work on M1 Hardware
The instruction pointer jumps all over the place when single-stepping through iOS Objective-C code on M1 hardware (Big Sur 11.2, Xcode 12.4). I tested on an M1 MacBook Air and an M1 MacMini and get the same behavior (running my app on a simulator or iPad hardware). All compiler, linker, etc. optimizations (that I know about) are turned off. Anyone else having this problem? Anyone have a work-around?
Replies
0
Boosts
0
Views
1.3k
Activity
Feb ’21
Reply to XCode 13.3 stuck when input Chinese in lldb console
I already had a radar: FB9958917 Thanks for filing that. Some notes: We can definitely reproduce it in-house. It seems to be related to Xcode’s console pane, not LLDB itself. If running lldb from the command-line is an option for you, that’s a simple workaround. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Replies
Boosts
Views
Activity
Apr ’22
Attach lldb debugger to the compiled program's executable when the main executable is not the compiled program
I am building an MPI C project in Xcode. In order to do run it, I had to: Specify /path/to/mpiexec in Edit Scheme -> Run -> Info -> Executable, instead of the default one, say myprogram if my target is called myprogram. Specify the following arguments in Edit Scheme -> Run -> Arguments -> Arguments Passed On Launch: -np 4, ${BUILT_PRODUCTS_DIR}/${EXECUTABLE_NAME} This is clearly analogous to a mpiexec -np 4 a.out command launched on terminal. The problem is, when I want to debug my application, the execution doesn't stop on the breakpoints. I instantly thought that it is because of the check box Debug Executable in Edit Scheme -> Run -> Info -> Executable. Indeed (as I have just said), the Executable specified in there is mpiexec and not myprogram. Thus, is there an option or some command I could set in Xcode to attach the lldb to myprogram?
Replies
2
Boosts
0
Views
626
Activity
Oct ’24
Xcode debugger crashes on breakpoint
Hello,We are having a systematic crash of the lldb-rpc-server when debugging our project, so we are unable to use the debugger. The crash is as follow:https://gist.github.com/bvirlet/89ecb0388c659932f5b572fa0d79e4f5I have submitted a crash report to Apple (FB7671116) but in the meantime I would be interested in a possible workaround.The problem is present for several developers, on different machines.Thanks!Bruno
Replies
0
Boosts
0
Views
782
Activity
Apr ’20
How to get my extension’s process ID of the dext for debugging with lldb
I've asked this question in Stackoverflow, but no response, so I ask for help in here. I follow this guide Debugging and testing system extensions, and try to debug my dext code. In the Attach the debugger to your system extension, it said After your system extension launches, run the ps command-line tool and note your extension’s process ID. This is the current output for my dext status % systemextensionsctl list 1 extension(s) --- com.apple.system_extension.driver_extension enabled active teamID bundleID (version) name [state] * * K3TDMD9Y6B com.accusys.scsidriver (1.0/1) com.accusys.scsidriver [activated enabled] and I used the ps command but nothing happen, I can not get my extension’s process ID. ps aux | grep com.accusys.scsidriver or ps -ef | grep com.accusys.scsidriver How to do that? Any suggestion is appreciated.
Replies
1
Boosts
0
Views
712
Activity
Dec ’24
Ios10 beta nightmare crash on keychain and keyboard crash crash crash crash
iiOS 10 crash crash crash ****
Replies
0
Boosts
0
Views
356
Activity
Jul ’16
Reply to Can't change background task identifier
My understanding is that you’re doing this: Run app with identifier A. Test it from LLDB. It works. Change the app to use identifier B. Test it from LLDB. It fails. If you delete the app from the device between steps 3 and 4, does that help? Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Jan ’24
Reply to Under stress tests, our Network Extension crashed due to QOS?
Anything I should look for or do, other than telling lldb to attach to the correct pid, and wait for a crash? That’s the obvious place to start. If you want to write more code you could: Investigate core dumps. Install a SIGABRT signal handler than stops the process to allow you to attach. Disable SIP and start messing around with DTrace. We might get to that point, but they all see like overkill right now. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Replies
Boosts
Views
Activity
Feb ’24