Intel provides a virtual hardware acceleration technology called HAXM, all known as: Intel Hardware Accelerated Execution Manager.
As long as your CPU is Intel's product and supports VT (virtualization technology), you can use HAXM technology to elevate the speed of your simulator to the level of the real machine. This technology currently supports Apple's Mac and Windows systems, but not the Linux platform.
To know the Android build environment Google first push Linux platform (64-bit Ubuntu) and Mac system ranked second. So how does hardware accelerate under the Linux platform?
That is the legendary KVM (kernel-based virtual machine), which, again, requires hardware support, such as Intel's VT and AMD V, which is hardware-based full virtualization.
To make sure your CPU meets the requirements first, here are a few commands to refer to:
$ egrep -c ‘(vmx|svm)‘ /proc/cpuinfo 4
The printed value is not 0.
Install KVM below:
$ sudo apt-get install qemu-kvm $ sudo adduser linc kvm $ sudo apt-get install libvirt-bin ubuntu-vm-builder bridge-utils $ sudo adduser linc libvirtd
Verify the installation is successful:
$ sudo virsh -c qemu:///system list Id Name State ----------------------------------------------------
All goes well, the next step is to create a x86 or x86_64 emulator, which is not supported by other emulators. Such as:
Start this emulator with the command line:
$ /opt/sdk/tools/emulator -avd Nexus5API21 -qemu -m 2047 -enable-kvm
It's really fast to use and it's amazing how quickly you can open a webpage. Of course, if you do not start the command line, directly in the Android Studio to launch the x86_64 architecture Simulator, the speed is very fast, but the ARM architecture simulator startup speed is extremely slow. Then again, since there is a relatively good CPU, then the other configuration of the machine must not be poor, such a configuration run simulator to certainly be stronger than the original.
The simulator is handy, so enjoy the fun of the development below.
If you feel that using your own simulator does not meet your requirements, then you can use a third-party simulator Genymotion, web developers respond well.
Reference:
http://www.mobibrw.com/?p=291
Emulator hardware acceleration under Linux