Increasing the Android SDK emulator speed

旧城冷巷雨未停 提交于 2019-11-28 18:49:47

Method I've found which has worked on both my laptop and desktop that I use for development is when you create or edit the Android Emulator (AVD) there is an option near the bottom that says use Host GPU.

I've have found this to work on all Android versions

UPDATE I missed the bit about the RAM problem. You haven't said if there is an error regarding the memory issue, but if you seeing failed to allocate memory: 8 then you need to modify the AVD config.

Go to C:\Users\your_name.android\avd\avd_name\config.ini and find hw.ramSize and make sure that MB is on the end of the number.

If you use an Android virtual device with Intel system image, you can enable HAXM(Hardware Accelerated Execution Manager) to speed up code execution. Take a look at this article: http://developer.android.com/tools/devices/emulator.html#acceleration

android developer

I would suggest to lower the resolution of the emulator to 320x480 and remove the skin of it (and learn the hotkeys).

If the hardware acceleration can work with your machine, try it. I've enabled it but never noticed any difference.

If that doesn't fit your needs, you can use other alternatives, which are faster, but have less features and I haven't tested them much:

  1. VirtualBox together with androidx86 - only one I've tested and debugged an app on, but it was a long time ago.
  2. Bluestacks - had lots of bugs, but seems promising.
  3. WindowsAndroid - new, works, but I can't find out how to connect via adb.
  4. Same as #1, but with androidvm instead of androidx86.
  5. Genymotion - alternative emulator.

Try using Genymotion. I think that it would be a good choice. https://cloud.genymotion.com/page/customer/login/?next=/page/launchpad/download/

You can change it to least :

also : and change the Screen coordinates from here :

note : in first step choose the Edit ,and the second step choose the start

mira

Complete speed up android emulator sollution step by step cań be found also for beginners here:

Speeds Up the Slow Android Emulator

This sollution worked on my i3 machine very well. I have tested many sollutions and emulators for days, but this one is fastest and best for me.

Follow the following steps to make android emulation almost as fast as a real device.

  • Start the AVD Manager and create a new AVD with the Target value of Android 4.0.3 (API Level 15), revision 3 or higher (And choose the other settings like usual).

    1. In Eclipse, click your Android project folder and then select Run > Run Configurations...

    2. In the left panel of the Run Configurations dialog, select your Android project run configuration or create a new configuration.

    3. Click the Target tab.

    4. Select the AVD you created in the previous procedure.
    5. In the Additional Emulator Command Line Options field, enter: -gpu on
    6. Run your Android project using this run configuration.

I have tried this and i confirm the result is a noticeably fast emulator (sometimes faster than a real device).

Ref - http://developer.android.com/tools/devices/emulator.html#acceleration

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!