Difference between iPhone Simulator and Android Emulator

What is the difference between iPhone Simulator and Android emulator? I have heard people saying that Emulator really emulates the target device which is not true in case of simulator.

I think Android emulator mimics the processing speed of the target device, the memory usage, but a simulator does not emulate the device.


Disclaimer: I'm only an iPhone developer, not an Android developer.

You are correct, the difference between emulators and simulators is that emulators mimic the software and hardware environments found on actual devices. Simulators, on the other hand, only mimic the software environment; they otherwise have access to all of the host system's hardware resources such as disk space, memory and processor speed.

Apple always harps on the importance of device testing because iPhone Simulator does not emulate an iPhone processor, disk drive, memory constraints and whatnot. You hardly ever get memory warnings unless your Mac is struggling to manage resources itself, unless you simulate (again) memory warnings from the Simulator's menu item.

In fact, if you go to Settings > General > About , you'll see that the Simulator's disk capacity is the same as the filesystem of the Mac it's installed on:


Though android emulator emulates the ARM processors and certain hardware, it still doesn't do a good job of matching the CPU performance.

Being an emulator it can match Memory consumption well, it can emulate certain simple devices well but fails when the devices gets complicated for example mobile GPU and HW media decoders. And as the emulation logic works on translating each ARM instruction to X86 instruction and executing its a performance hog and by design not cycle accurate.

With programming model being Java this design doesn't buy anything to the Application developer as the performance on emulator doesn't reflect performance on device (due to speed of emulation and due to missing HW devices) and more often is is an inconvenience as debug cycles are slow. The only advantage being Application complied for emulator work as it is on devices (no recompilation).

In the simulator model of iPhone Apple realized they are not going to match device perfectly, so they do not even try and in return give developers a fast cycle time and enhanced tool support to develop applications effectively.

链接地址: http://www.djcxy.com/p/50576.html

上一篇: 仿真和仿真有什么区别?

下一篇: iPhone模拟器和Android模拟器的区别