JIT-enabled equivalent of the JavaScriptCore framework
| Originator: | radexpl | ||
| Number: | rdar://27762108 | Date Originated: | 09-Aug-2016 10:43 AM |
| Status: | Open | Resolved: | |
| Product: | iOS SDK | Product Version: | |
| Classification: | Feature (New) | Reproducible: | Not Applicable |
There are many applications for using the JavaScript virtual machine in native apps, independently from web views. It can be used for scripting, prototyping, runtime switches, cross-platform code, and other use cases. Currently we have access to the JavaScriptCore framework on iOS, and it’s very powerful, except for the fact that it’s limited to the lowest tier of JSC performance. Since the JSC code runs within app process, it cannot be allowed to write new executable code, and so Just-In-Time Compilation is not possible. This problem was solved with web views by adding WKWebView, a new framework that uses an out-of-process WebKit machinery, running with system privileges, to allow for fast JIT-enabled JavaScript. It ought to be possible to create an analog to WKWebView, without the web view. An equivalent of JSC, that runs out of process to enable fast JIT JS. Such a framework would inevitably be limited in some ways compared to JSC (as WKWebView is to UIWebView) because of the XPC latency. However, there are use cases in which the trade-off would be worth it and the extra performance of “Fast JSC” highly desirable.
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!