Android模拟器有点迟钝。对于摩托罗拉Droid和Nexus One等设备,应用程序在实际设备上的运行速度比模拟器快。在测试游戏和视觉效果时,这是一个问题。
如何使模拟器尽可能快地运行?我一直在摆弄它的参数,但还没有发现一个配置显示出明显的改进。
Android模拟器有点迟钝。对于摩托罗拉Droid和Nexus One等设备,应用程序在实际设备上的运行速度比模拟器快。在测试游戏和视觉效果时,这是一个问题。
如何使模拟器尽可能快地运行?我一直在摆弄它的参数,但还没有发现一个配置显示出明显的改进。
当前回答
我最近从core 2 @ 2.5, 3gb内存换成了i7 @ 1.73, 8gb内存(两个系统都运行Ubuntu 10.10),现在模拟器的运行速度至少快了一倍。投入更多硬件当然会有所帮助。
其他回答
官方网页
~快50%
窗口:
Install "Intel x86 Emulator Accelerator (HAXM)" => SDK-Manager/Extras Install "Intel x86 Atom System Images" => SDK-Manager/Android 2.3.3 Go to the Android SDK root folder and navigate to extras\intel\Hardware_Accelerated_Execution_Manager. Execute file IntelHaxm.exe to install. (in Android Studio you can navigate to: Settings -> Android SDK -> SDK Tools -> Intel x86 Emulator Accelerator (HAXM installer)) Create AVD with "Intel atom x86" CPU/ABI Run emulator and check in console that HAXM running (open a Command Prompt window and execute the command: sc query intelhaxm)
别忘了安装这个
备注:在AVD创建过程中添加模拟内存:硬件/新/设备ram大小/设置值512或更多
Linux:
安装KVM:打开谷歌,写“KVM installation” 用“Intel atom x86”CPU/ABI创建AVD 从命令行运行:emulator -avd avd_name -qemu -m 512 -enable-kvm 或者从Eclipse运行:运行/运行配置/标签“目标”- >检查Intel x86 AVD,并在“附加模拟器命令行选项”窗口添加:-qemu -m 512 -enable-kvm(单击运行)
附注:对于Fedora,对于Ubuntu
OS-X:
在“Android SDK管理器”中安装Intel x86 Atom System Image 在Android SDK管理器中,安装Intel x86 Emulator Accelerator (HAXM) 在finder中,转到Intel Emulator Accelerator的安装位置并安装IntelHAXM(打开dmg并运行安装)。您可以通过将鼠标放在SDK管理器中的Emulator Accelerator条目上来查找位置。 创建或更新AVD并指定Intel Atom x86作为CPU。
p.s.:检查这个工具,非常方便甚至试用
I think it is because clr virtual machine uses cpu directly without code opcode translation. It may be optimization for clr application or may be windows mobile/window phone 7 started on INTEL proccessor. Android platform based on linux and theoretically you can start android on virtual machine in i686 environment. In this case virtual machines such as vmware could execute some opcodes direcly. But this option will be allowed only if you write on the Java. Because the Java interpret their byte-code or precompile it before execution. see: http://www.taranfx.com/how-to-run-google-android-in-virtualbox-vmware-on-netbooks
Thank you @zest! Worked like a charm. Some things of note: Need to apply Intel's hotfix for the HAXM to deal with kernel panic issue: http://software.intel.com/en-us/android/articles/intel-hardware-accelerated-execution-manager Also, note, if you have more than one abi, you need to uninstall one due to a bug in the latest version of the Android API (r19): https://code.google.com/p/android/issues/detail?id=66740 (remove armeabi-v7a in this case, since you want the x86 abi). Other than the 45-minutes it took me to resolve these, it was an very rewarding exercise in terms of the increased performance of the emulator.
只是想说,在我安装了英特尔HAXM加速器并使用英特尔Atom映像后,模拟器的运行速度似乎快了50倍。差别是惊人的,看看吧!
http://www.developer.com/ws/android/development-tools/haxm-speeds-up-the-android-emulator.html
如果你没有一个好的显卡(像我一样),选择一个低分辨率的模拟器(例如:Nexus S)