In order to make the Android emulator run faster and be more responsive, you can configure it to take advantage of hardware acceleration, using a combination of configuration options, specific Android system images and hardware drivers.


Using SDK manager to download/install x86 system image

1.Configuring Graphics Acceleration

Graphics acceleration for the emulator takes advantage of your development computer's graphics hardware, specifically its graphics processing unit (GPU), to make screen drawing faster.


SDK Tool version >= 17

SDK Platform API version >= 15 (i.e. >= android 4.0.3)

In avd, specify "Use Host GPU", note not to specify snapshot

Plus, you canspecify to use GPU acceleration (specify "-gpu on" in target's additional emulator command line options) at runtime

2.Configuring Virtual Machine Acceleration

Caution:As of SDK Tools Revision 17, the virtual machine acceleration feature for the emulator is experimental; be alert for incompatibilities and errors when using this feature.

Many modern CPUs provide extensions for running virtual machines (VMs) more efficiently. Taking advantage of these extensions with the Android emulator requires some additional configuration of your development system, but cansignificantly improve the execution speed. Before attempting to use this type of acceleration, you should first determine if your development system’s CPU supports one of the following virtualization extensions technologies:

  • Intel Virtualization Technology (VT, VT-x, vmx) extensions

  • AMD Virtualization (AMD-V, SVM) extensions (only supported for Linux)

Note: Retina MAC Book Pro (i7-3635QM) supports VT


Note:Virtualization extensions are typically enabled through your computer's BIOS and are frequently turned off by default. Check the documentation for your system's motherboard to find out how to enable virtualization extensions.


To use virtual machine acceleration with the emulator, you need the following version of Android development tools. Use theAndroid SDK Managerto install these components:

  • Android SDK Tools, Revision 17 or higher

  • Android x86-based system image

Virtual machine acceleration on a Mac requires the installation of the Intel Hardware Accelerated Execution Manager (Intel HAXM) kernel extension to allow the Android emulator to make use of CPU virtualization extensions.

  • Configuring VM Acceleration on Mac

    To install the Intel HAXM kernel extension:

    1. Start the Android SDK Manager, select

      Extras

      and then select

      Intel Hardware Accelerated Execution Manager.

    2. After the download completes, execute

      /extras/intel/Hardware_Accelerated_Execution_Manager/IntelHAXM.dmg.

    3. Double click the

      IntelHAXM.mpkg

      icon to begin installation.

    4. Follow the on-screen instructions to complete installation.


    5. After installation completes, confirm that the new kernel extension is operating correctly by opening a terminal window and running the following command:


    6. kextstat | grep intel

    7. You should see a status message containing the following extension name, indicating that the kernel extension is loaded:

    8. com.intel.kext.intelhaxm


    9. Restart ECLIPSE

    10. recreate avd to "Use Host GPU" in x86 system image

    11. start avd



更多相关文章

  1. 代码中设置drawableleft
  2. android 3.0 隐藏 系统标题栏
  3. Android开发中activity切换动画的实现
  4. Android(安卓)学习 笔记_05. 文件下载
  5. Android中直播视频技术探究之—摄像头Camera视频源数据采集解析
  6. 技术博客汇总
  7. android 2.3 wifi (一)
  8. AndRoid Notification的清空和修改
  9. Android中的Chronometer

随机推荐

  1. 如何同时启动两个Android 模拟器
  2. Android图像处理(一)色调、饱和度、亮度
  3. 地图相关
  4. Android获取天气预报
  5. Android(安卓)OpenGLES2.0(十五)——利用EG
  6. android 动态改变控件大小的方法
  7. Android关机重启分析
  8. 【30篇突击 android】源码统计 十一
  9. Backtrace in Android
  10. 如何提高Android代码的安全性