-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
iOS: Should fail gracefully when JIT is not available #14196
Comments
You can use the web debugger to get logging, although that won't work until after you connect. -[Unknown] |
Yeah, that does seem to work. Don't know why I keep forgetting that one. Anyway, it's kinda weird - it seems to happily allow you to mmap and mprotect memory as EXEC, no bad return codes, it just blows up as soon as you try to execute anything. So it seems to be hard to detect, unless I'm missing something of course. Maybe a fork() would do it. I think I'm just gonna have it check for iOS 14.3 or higher, and block attempts to use JIT if the debugger isn't attached (which we do seem to be able to detect). |
Is this "resolved" now, given comments in #14240? -[Unknown] |
I think there are still combinations of states between jailbroken and jit that we don't handle exactly right because we can't detect whether we can execute code or not reliably. although I'm quite thoroughly confused about it all at this point.. |
Currently, when JIT is selected but unavailable on iOS (that means, not running from the debugger, as of iOS 14.4), the app just crashes and instantly exits. This is not ideal as it's confusing for users what happened. We should probably just automatically switch to IR interpreter instead, and maybe display a message.
(A minor challenge when fixing this will be that logging is not available when the debugger isn't attached, AFAIK....)
The text was updated successfully, but these errors were encountered: