Situation: I have android x86 accelerated emulator on Mac OS X. It starts normally (and shows HAX is working and emulator runs in fast virt mode
line) and I can run programs. After program being launched emulator works some time and freezes, so I cannot interact with it.
Example: if I call adb shell ls -l /sdcard/
(or many other adb commands) nothing is printed in console and I must press control+C to return control.
After emulator restart problem vanishes and after time it occurs again.
Works right on not-accelerated emulator. Works wrong only with HAXM turned on.
I have tried to
I need to make emulator working all the time (not only first N minutes).
That's not a duplicate to this question because of:
Possibly relates to this question, but
System information:
Model Identifier:iMac10,1
Memory:8 GB
System Version:Mac OS X 10.6.8 (10K549)
Kernel Version:Darwin 10.8.0
HAXM release 1.0.6
It met Intel requirements
Supported Operating Systems:
Mac OS X* 10.6 Snow Leopard and 10.7 Lion (32/64-bit)
Making setup I followed instructions from developer.android. I allocated 2048 Mb during HAXM install and created emulator with 512 Mb RAM.
There are some messages in dmesg
in the meantime. History:
1) After emulator was started (it works)
Kext com.intel.kext.intelhaxm not found for unload request.
13
possible map ffffffffffffffff cpu_online_map 3
haxm_error: fc_msr haxm_error: fc_msr 5
5
haxm_error: vt_enablhaxm_error: vt_enable e 1
haxm_error: nx_enable 1
haxm_error: nx_enable 2048
2048
haxm_error: ---- HAXM release 1.0.6 --------
haxm_error: This log collects runnging status of HAXM driver.
haxm_error: set memlimit 0x80000000
2) After some time passed (it still works!)
23
possible map ffffffffffffffff cpu_online_map 3
haxm_error: fc_msr h5
axm_error: fc_msr h5
ahaxm_error: vt_enable xm_error: vt_enable 1
1
haxm_error: nx_haxm_error: nx_enable ena2048
ble 2048
haxm_error: ---- HAXM release 1.0.6 --------
haxm_error: This log collects runnging status of HAXM driver.
.......hax_vm_create_ui 0
cvcpu 0x1d803000 vmid 0 vcpu_id 0
minor id 1000before the crate node
setup hax tunnel request for already setup one
haxm_error: hax_vm_alloc_ram: size 0x20000000
haxm_error: !VM_STATE_FLAGS_MEM_ALLOC
haxm_error: Memory allocation, va:123787000, size:20000000
haxm_error: !VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error: hax_vm_alloc_ram: size 0x20000
haxm_error: spare alloc: mem_limit 0x0, size 0x20000, spare_ram 0x5800000
haxm_error: VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error: hax_vm_alloc_ram: size 0x20000
haxm_error: spare alloc: mem_limit 0x0, size 0x20000, spare_ram 0x5800000
haxm_error: VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error:
...........hax_teardown_vm
.......hax_vm_create_ui 0
cvcpu 0x1d585800 vmid 0 vcpu_id 0
minor id 1000before the crate node
setup hax tunnel request for already setup one
haxm_error: hax_vm_alloc_ram: size 0x20000000
haxm_error: !VM_STATE_FLAGS_MEM_ALLOC
haxm_error: Memory allocation, va:123637000, size:20000000
haxm_error: !VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error: hax_vm_alloc_ram: size 0x20000
haxm_error: spare alloc: mem_limit 0x0, size 0x20000, spare_ram 0x5800000
haxm_error: VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error: hax_vm_alloc_ram: size 0x20000
haxm_error: spare alloc: mem_limit 0x0, size 0x20000, spare_ram 0x5800000
haxm_error: VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error:
...........hax_teardown_vm
.......hax_vm_create_ui 0
cvcpu 0x1d7a8800 vmid 0 vcpu_id 0
minor id 1000before the crate node
setup hax tunnel request for already setup one
haxm_error: hax_vm_alloc_ram: size 0x20000000
haxm_error: !VM_STATE_FLAGS_MEM_ALLOC
haxm_error: Memory allocation, va:123637000, size:20000000
haxm_error: !VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error: hax_vm_alloc_ram: size 0x20000
haxm_error: spare alloc: mem_limit 0x0, size 0x20000, spare_ram 0x5800000
haxm_error: VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error: hax_vm_alloc_ram: size 0x20000
haxm_error: spare alloc: mem_limit 0x0, size 0x20000, spare_ram 0x5800000
haxm_error: VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
3) After emulator hung
.......hax_vm_create_ui 0
cvcpu 0xf5e5000 vmid 0 vcpu_id 0
minor id 1000before the crate node
setup hax tunnel request for already setup one
haxm_error: hax_vm_alloc_ram: size 0x20000000
haxm_error: !VM_STATE_FLAGS_MEM_ALLOC
haxm_error: Memory allocation, va:123641000, size:20000000
haxm_error: !VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error: hax_vm_alloc_ram: size 0x20000
haxm_error: spare alloc: mem_limit 0x0, size 0x20000, spare_ram 0x5800000
haxm_error: VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
haxm_error: hax_vm_alloc_ram: size 0x20000
haxm_error: spare alloc: mem_limit 0x0, size 0x20000, spare_ram 0x5800000
haxm_error: VM_STATE_FLAGS_MEM_ALLOC: spare_ram 0x5800000
Please excuse me for all these similar logs but I do hope they can help in diagnostics. I didn't find other output facing with freezes.
Am I doing something wrong here? Can I somehow fix/workaround these freezes?
P.S.
$ top
PID COMMAND %CPU TIME #TH #WQ #POR #MREG RPRVT RSHRD RSIZE VPRVT VSIZE PGRP PPID STATE UID FAULTS COW MSGSENT MSGRECV SYSBSD SYSMACH CSW PAGEINS
35308 emulator64-x 99.9 93:35.44 2/1 1 67 114 13M 18M- 179M 297M 3459M 35303 35303 running 503 180922 477 134488 1390 604431027+ 1732 83769+ 7
Not sure if you still running into this issue or not but your on an older release of Intel's HAXM. The current release is: HAX 1.0.8 Download
I saw your post and kept getting a crash.
When tailing the /var/log/system.log on Mac OSX 10.9 I would see your above messages. When I tried to reinstall the HAX I would see the below:
Aug 19 12:03:55 3c15c2cf84fe kernel[0]: haxm_error: -------- HAXM release 1.0.7 --------
Aug 19 12:03:55 3c15c2cf84fe kernel[0]: haxm_error: This log collects runnging status of HAXM driver.
Aug 19 12:03:55 3c15c2cf84fe kernel[0]: haxm_error: set memlimit 0x80000000
I was able to resolve my issue by removing all of the AVD's that I created with Android Studio. From the AVD (Android Virtual Devices) just "Delete" all the emulators in your Virtual devices. Then start over.
If you get the below ERROR:
Do the following:
I hope that helps someone.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With