Hacker News new | ask | show | jobs
by shoo_pl 1539 days ago
Literally second paragraph of the article mention QEMU-based app that allows you to virtualise x64 machines on M1 - UTM:

https://mac.getutm.app/

The thing is, it only supports windows xp + windows 7, and not 8/10/11 (those are supported as arm64). Apparently the amount of work is massive (so are performance hits for the Windows XP/7 when you run it).

It's one thing to emulate apps, another entirely to emulate whole advanced OS.

1 comments

Yes, I read the article and was in fact aware of UTM, also noted:

> the performance penalty is significant

I was asking the genuine question as to if it would be theoretically possible to use Rosetta as part of the emulation for a VM to potentially help it to perform better?

For example could a tool be installed within a guest OS that effectively send binaries to Rosetta for translation before execution?

It just seems to me that if Apple have done such an incredible job with Rosetta wouldn’t it be brilliant if it was possible to use that within an emulated VM on Apple silicone.

No rosetta doesn't do system level emulation. System vs app level are distinctly different problems.

Att the app level rosetta can operate at link time (yes it does AoT, but that's essentially just caching), where it knows things like what things are text regions, what the entry points are, it can assume that the code is "correct" (if your code is buggy natively, then rosetta won't stop it going wrong), etc.

System level emulation means rosetta (or whatever) loses that transparency, so can't precompile, and can't make any assumptions about code behaving properly. To get an idea of what the performance impact is you should check the performance of JIT compiled code under rosetta. Rosetta ensures that the JIT will work, but the perf hit is staggering. System level emulation basically means treating everything as being JIT code.

I'm sure a system level emulator (Qemu?) could do better than for example just slapping a system emulator mode into rosetta, but that would be because rosetta is optimized for app level emulation.