How to use Android Emulator on AMD Ryzen (Android Studio)?

31,224

Solution 1

For Ryzen on Windows 10, use the latest stable instead of canary.

  1. Enable virtualization in BIOS.
  2. Remove HAXM.
  3. Turn off Hyper-V, Windows Hypervisor platform, Windows Sandbox(depends on your windows version, old versions may not have all). REBOOT

screenshot

  1. Launch SDK Manager via Android Studio and you should see "Android Emulator Hypervisor Driver for AMD Processors". Check and click "Apply". The SDK Manager will download the installer package and unpack it to $ANDROID_SDK_ROOT\extras\google\Android_Emulator_Hypervisor_Driver. driver

Then,

  1. Open a Windows command console with administrator privileges.
  2. Go to $ANDROID_SDK_ROOT\extras\google\Android_Emulator_Hypervisor_Driver.
  3. Run silent_install.bat. Make sure you see the desired output from the installer: STATE: 4 RUNNINGresult

Solution 2

I just purchased a Ryzen 5 laptop with Vega 8 video and was having alot of problems running the Android Studio emulator; in the end the problem was resolved and it was very simple.

  1. Enable SVM or other virtual machine setting in the BIOS.

  2. Disable all hypervisor and virtual machine features by going to "Turn features on / off" in windows.

  3. Ensure you checkmark the AMD driver and uncheck HAXM in "SDK Tools" is SDK Manager.

    And most important:

    It is said that the latest update of Android Studio automatically installs the AMD driver once selected, however I found this not to be the case so the last step you need to do manually just to make sure.

  4. Run: C:\users\username\AppData\Local\Android\Sdk\extras\google\Android_Emulator_Hypervisor_Driver\silent_install.bat

Solution 3

Late to the party but if there are more like me who never got this to work, this got it to work: https://www.py4u.net/discuss/646511

If you tried everything (turning windows features off, enabling svm in bios..etc) and still didn't work, type bcdedit in the command prompt, and press ENTER. If you see an entry for hypervisorlaunchtype set to Auto, Hyper-V is still enabled. You can try setting the launch type to Off by running the command below.

bcdedit /set hypervisorlaunchtype off
Share:
31,224
pirmax
Author by

pirmax

Updated on July 09, 2022

Comments

  • pirmax
    pirmax almost 2 years

    I try to build Android app from Android Studio.

    I tried to install HAXM from Android Studio installer but I've an error:

    enter image description here

    Intel Virtualization Technology is already enabled in my BIOS. And the Hyper-V is already disabled on Windows 10.

  • pirmax
    pirmax about 4 years
    Thanks, should have uninstall the current Android Studio ?
  • pablolucio
    pablolucio about 4 years
    OK, I uninstalled it and installed Android Studio Cannary, configured it according the video above and it run for me.
  • Doc
    Doc about 4 years
    I have the exact steps working on Ryzen 1600 windows 10 1809 version. The system is stable and butter smooth. Perf is on par with an intel machine.
  • Murillo Comino
    Murillo Comino almost 4 years
    Thank you, your solution was the only one that worked for me. I have windows 10 1909 version and Ryzen 5 2400g, Android Studio 3.6.3!
  • Doc
    Doc almost 4 years
    no biggie, I use a one-line script to launch emulator. Launches under 2 sec, ready to go. Ryzen + android studio is great now.
  • yeahman
    yeahman almost 4 years
    and what if I am using windows home with no hyper-v available?
  • Doc
    Doc almost 4 years
    @yeahman no problem. just make sure you have virtualization enabled in BIOS. Then install lastest version of Android Studio stable, get the stable version of emualtor. Install amd-hypervisior driver and you are good to go.
  • Nfff3
    Nfff3 over 3 years
    I tried everything and nothing worked, but running silent_install.bat worked for me. Android Studio 3.5.
  • Doc
    Doc over 3 years
    @Nfff3 upgrade to 4.0,driver installation is automatic.