57

I'm totally new to Android programming. I have Android Studio 3.0.1 running on Kubuntu Xenial 64-bit on a desktop with a Haswell processor.

I am configuring virtual devices. I am thinking of doing that corresponding to the physical Android devices I own. However, I notice that x86 images are placed in the "Recommended" pane:

enter image description here

compared to the x86_64 images of identical API version and target:

enter image description here

#4 of https://developer.android.com/studio/run/managing-avds.html#createavd seems to indicate that x86 images are recommended because they "run the fastest in the emulator."

A few of my old devices are x86 but the newer ones are x86_64. Should I choose x86_64 accordingly though it is not in the "Recommended" pane?

Does this make a difference when I am going to distribute APKs on Google Play Store in the future?

jamadagni
  • 1,214
  • 2
  • 13
  • 18
  • They are just AVD images for the slow Android emulator if you debug using the emulator. – ecle Nov 23 '17 at 07:47

1 Answers1

18

related to this answer By default, all 32-bit applications run without a glitch on 64-bit processors, but might run slower than applications tuned to run on 64-bit processors.

and according with this article

With Google’s recent release of its x86 64-bit Android 5.0 emulator image, developers can create 64-bit apps for Intel Atom processor-based devices.

Android 32-bit vs 64-bit

Many 64-bit platforms today, including Solaris, AIX*, HP-UX*, Linux*, OS X*, BSD, and IBM z/OS*, use an LP64 model. Since Android is based on the Linux kernel, Android 64-bit platforms also use the LP64 model.

Intel 64-bit CPUs have a 32-bit compatibility mode. While 32-bit applications will run on 64-bit processors, compiling with a 64-bit optimizing compiler allows them to take advantage of the architectural benefits of a 64-bit environment.

Android with 64-bit technologies for Intel Atom processor-based platforms can help developers to optimize their applications now. Building Android applications for 64-bit is just as easy as building traditional 32-bit Android applications. You can now use the official Android 64-bit emulator to run and debug 64-bit apps.

Maybe this articles can help you to understand the difference between this system images.

Update

Google now encourage to use x86 emulator like you can see in this image

enter image description here

The difference is that when using x86 images, it now uses fast, hardware-accelerated virtualization under the right conditions (HAXM) so it doesn't feel like there's a fat middle layer anymore.

Nawrez
  • 3,314
  • 8
  • 28
  • 42
  • 1
    Thanks for this reply. As I'm on Linux I have KVM i.o. your HAXM. Should I understand that these provide acceleration only for 32-bit and not 64-bit? – jamadagni Nov 23 '17 at 09:08
  • You're welcome ! yes, It's dedicated usually to accelerate traditional 32-bit Android applications – Nawrez Nov 23 '17 at 10:28
  • 19
    It is my understanding that the recommendation for "x86 based" is in contrast with the full non-Intel based emulator, not that it is 10x faster than using 64 bit. – neutromancer Jun 06 '18 at 16:52
  • How can I identify a 64-bit Android phone *before* purchase? I know how to determine after purchase. I need a 64-bit Android testing device. I can purchase a 64-bit phone but it may be running a 32-bit Android OS. – Ed of the Mountain Jun 11 '19 at 19:21
  • 3
    so the tl;dr is we should use x86 instead x86_64 right? – buncis Sep 06 '19 at 12:28
  • 6
    @buncis No. It is unclear based on information shared here so far which of x86 and x86_64 runs faster on a x86_64 development machine. – Carolus Oct 14 '19 at 17:25
  • 1
    @buncis apparently someone tested x86 vs x86_64 and found basic x86 10% faster https://stackoverflow.com/a/65615506/2301224 – Baker Apr 20 '22 at 19:12