Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ


Choose your language

InfoQ Homepage News Jack & Jill: New Android Compilers for More Performance

Jack & Jill: New Android Compilers for More Performance

This item in japanese

Eric Lafortune, Technical Director of Saikoa, maker of DexGuard, has discovered new tools in the SDK for Android 5.0 Revision 1 (API 21.1), namely two compilers called Jack and Jill. These tools are meant to streamline the compilation process for Android.

Google introduced the Android RunTime (ART) as an experimental utility in KitKat, and made it the default runtime for Lollipop, replacing Dalvik. ART takes DEX bytecode and converts it to native code when applications are installed on the device, doing ahead-of-time compilation but considering the device’s characteristics. Now, Google seems to be enhancing the compilation process even further.

According to Lafortune, Jack is a tool based on the Eclipse Java compiler and ProGuard. ProGuard is an optimization tool that shrinks a codebase by removing unused code and obfuscates it by renaming classes, methods and fields. Even though ProGuard has been integrated into the Android build system, being recommended when generating release binaries, developers have the choice to use it or not. If Jack becomes official, they will have to use it but they will still have some control over it through the configuration files.

Jill, the other new tool, is used to convert Java library bytecode into an intermediary bytecode called Jayce. Jack compiles both Java source code and Jayce binary code, generating optimized DEX bytecode. The compilers “seem quite functional,” although Jack doesn't support “some of the advanced features of ProGuard (yet), for instance to remove logging code,” wrote Lafortune.

The compilers do not support Java 8 yet, but they strive for “backward compatibility and open up possibilities for future extension,” added Lafortune. Developers can try them out in a Gradle build using the Android plugin 1.0.0 RC.

Jack and Jill produce even more optimized code, smaller in size and possibly obfuscated, being another attempt from Google to increase the performance of their mobile operating system.

Rate this Article