Around a week ago, we reported about the implications that iOS & iPadOS 18.4 developer beta 1 had on the use of just-in-time (JIT) compilation for iPhone and iPad apps used outside of the native debugger, which would affect its use inside of sideloaded apps with the help of utilities like AltJIT, SideJIT, and Jitterbug, among others.
But as we alluded to in that piece, the only possible workaround would be for developers to somehow utilize the debugger for JIT on iOS & iPadOS platforms, and that’s exactly what hacker and tinkerer Duy Tran (@TranKha50277352) has done, according to a post shared this past week on 𝕏 (formerly Twitter).
The post shows a screenshot of the popular Minecraft video game playing within the iOS debugger. In the linked GitHub page, we learn that this method works on iOS & iPadOS 18.4 developer beta 1 and that it uses split rx/rw regions to make it happen.
According to the comments, this code makes an executable region into a debug map. For it to work, the debugger simply needs to write to any memory pages that you want to run through JIT compilation. Yes, it’s a hacky workaround, but it works.
As the post explains, the approach is both tedious and may stop working in the very near future. That’s because if Apple is hellbent on ending JIT support in sideloaded apps, then it will be very easy for them to patch this hack out before the official public iOS & iPadOS 18.4 release.
Why all the noise about JIT recently? As opposed to ahead-of-time (AOT) compilation, JIT compilation offers a much more performant way of executing programming code on a non-native system by utilizing a universal machine code. While there are lots of plus-sides to this, such as its use in emulation, Apple has identified it as a possible security threat, as malware can take advantage of JIT just as well as good software can.
When iPhone and iPad users eventually lose access to JIT through software updates, sideloaded apps will still run without it, but not as smoothly and performant as they did with JIT. This will result in a worse user experience.
In any case, it’s neat to see this little workaround, but we’re sure that it won’t be around for long given the early stages of Apple’s developer beta releases for iOS & iPadOS 18.4.
Are you upset to see that Apple is targeting JIT in sideloaded apps now? Let us know in the comments section down below.