Performance Regression in Android 14 Debuggable Runtime Caused by Interpreter Switch and Its Fixes
The article analyzes why Android 14's debuggable runtime became significantly slower due to a change from the nterp interpreter to the switch interpreter, explains the underlying ART modifications, and presents the Google‑provided fixes that restore performance to Android 13 levels.
Developers noticed that a debuggable version of an app ran smoothly on Android 13 but became extremely sluggish on Android 14, prompting an investigation into the Android runtime.
A community comment revealed that the execution mode of the interpreter changed: Android 13 used the nterp (new interpreter) while Android 14 switched to the switch interpreter , leading to severe performance loss.
The root cause was a commit that removed instrumentation stubs, which were required for supporting nterp in debuggable builds. Without these stubs, the runtime could no longer use nterp and fell back to the slower switch interpreter .
Further analysis showed that only two interpreters exist after Android 12: the switch interpreter and nterp . In debuggable mode, nterp is replaced by switch interpreter , degrading performance, while JIT still works for most hot methods but fails to trigger for boot image and zygote methods.
Google's fix restores the original JIT thresholds for boot methods and avoids unnecessary copy‑on‑write updates, allowing those methods to be JIT‑compiled as before. Additional optimizations were also introduced.
Performance tests on Kuaishou and Futu apps show that after applying the two patches, launch times on Android 14 drop to values comparable to Android 13, confirming the effectiveness of the fixes.
The article concludes that while the issue is not fatal, it significantly impacts developer productivity, and the fixes must be back‑ported to Chinese Android 14 devices by OEMs since Google’s OTA cannot reach them directly.
Rare Earth Juejin Tech Community
Juejin, a tech community that helps developers grow.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.