Basics
Applications that are entirely built from Java or Kotlin code, including all the libraries and SDKs they use, don't care about which of armv7a and armv8a a device supports. However, quite a few apps include "native code", aka "machine code", usually compiled from C or C++ code using the Android Native Development Kit ("NDK").
A given piece of machine code is either 32-bit (armv7a) or 64-bit (armv8a). It cannot be both.
Running native code
Applications that support both armv7a and armv8a have two sets of machine code included in their APK files:
- One set for armv7a
- One set for armv8a
Your armv7a device can happily run the code that's intended for it. It can understand that, and has the libraries and other software it needs to run it. It can't understand armv8a code at all, and is thus unable to run it. Applications that only support armv8a thus can't be run, so Android prevents you from installing them. If it let you install them, you'd waste data and storage finding out that they crashed when run.
Forthcoming complexities
The ARMv9 architecture Is gradually appearing in Android devices. The Qualcomm Snapdragon 8 Gen 1 was one of the first v9 chips announced, in November 2021. Most ARMv9 cores can't run armv7a code, because they don't implement that 32-bit instruction set (or any other). The 2023 generation of new core designs from ARM is the first with no cores at all that can run armv7a code. They can run armv8a code.
This means that devices with ARMv9 processors:
- Can run apps that support armv7a and armv8a.
- Can run apps that only support armv8a.
- Can't run apps that only support armv7a.
It's a good thing that Google have been demanding that new and updated apps for the Play Store include armv8a code since August 2019 if they include any native code.
If and when the Android NDK acquires an option to build for armv9a, such code won't run on armv7a or armv8a devices. I presume that Google will require APKs with armv9a code to provide armv8a code as well, at least for a few years.
Why is there any armv7a machine code in use?
Android has quite a long history, and when it started, neither armv7a nor armv8a had been standardised. So there's been a gradual process of upgrading native code to newer standards.
In more detail, the original NDK in June 2009 only supported "armeabi" machine code, using the ARMv5TE instruction set. Armv7a was added in June 2010, x86 in June 2011 and MIPS in May 2012. Armv8a, along with 64-bit x86 and MIPS was added in July 2014. Armeabi, MIPS and MIPS64 were removed in June 2018.
Someone starting on Android NDK work today would support armv7a and armv8a, or maybe only armv8a if they were only interested in newer, faster devices, or their app needed to use lots of memory.
There have been a few Android devices that had 64-bit processors and a 64-bit Android kernel, but didn't have 64-bit Java/Kotlin run-times. The one I encountered was a 2017 model of the Amazon Kindle Fire HD 10, which is now discontinued. I bought it for the 64-bit Android 5, and the lack of 64-bit Java run-times was no problem for the native code I needed to test in the ADB shell.
The main benefit of 64-bit Java/Kotlin run-times is that they allow apps running on them to access more memory. This is only significant on devices with at least 4GB of RAM, so providing those run-times on devices with smaller memories has little value. As of 2023, 4GB seems to be becoming the standard for new low-end Android devices.