Snapdragon LLVM Compiler for Android
LLVM is a C/C++ compiler that is becoming increasingly popular. It enables use of compilers in a broader range of configurations, providing for better performance and power usage – particularly on Snapdragon micro-architectures. Beginning with the Jellybean MR1 release, Google has included LLVM as an alternative compiler as part of the Android toolchain and the Android NDK. LLVM is suitable wherever you use native code (C/C++) in your Android application.
As a key supporter of LLVM, Qualcomm has been working on optimizing this mobile-friendly compiler for Snapdragon and we are pleased to make it available to you.
Download the Snapdragon LLVM Compiler v3.5 for Android NDK:
- Snapdragon LLVM Compiler - Windows (readme)
- Snapdragon LLVM Compiler - Linux 32bit (readme)
- Snapdragon LLVM Compiler - Linux 64bit (readme)
Looking for a prior version? Contact us.
We have seen performance gains to a variety of Android applications and libraries when compiling with LLVM. For example, in our tests the C version of the Android jpeg library performs 10% faster on Snapdragon-based devices when built with the Snapdragon LLVM compiler compared to the latest NDK GCC version. We also observe performance improvement in the libpng library using the Snapdragon LLVM compiler compared to the LLVM or GCC compilers included in the Android NDK.
Work In Progress
The Snapdragon LLVM compiler team is actively working on optimizations targeting typical Android scenarios, focusing on delivering high performance on Snapdragon cores by exploiting capabilities such as the 128-bit Neon engine. Please share with us your results using the Snapdragon LLVM compiler; and if there are workloads that you are interested in seeing accelerated for Snapdragon, please contact us.
Note that LLVM integration with Android is still in early days and it is difficult to predict if it will bring a benefit to your app – although we encourage you to give it a try. You may be pleasantly surprised.