News for hackers. Stuff that matters.
Re:Friday Facts #371 - Apple Silicon by lloeki on Friday November 25, 2022 @11:38AM (#33744074)
> I believe Rosetta 2 also has a JIT mode

It does have JIT translation (not a JIT "mode" though, as it always use AOT translation, only relying on JIT translation at runtime for the parts that need it)

> which is a bit more like conventional emulators

Not at all (unless you've been meaning dynarec†, but I would not call that "conventional" although it is a well-known technique), Rosetta 2 does the same†† translation step, whose arm64 output can be reused afterwards

> But it's used infrequently, eg when dealing with x86_64 apps that themselves use a JIT

Yes, although it's more like "exceedingly rarely" in practice since usually those interpreters are up to date enough to have a native arm64 release.

See there for details: https://dougallj.wordpress.com/2022/11/09/why-is-rosetta-2-f...

† https://en.wikipedia.org/wiki/Dynamic_recompilation

†† IIUC minus a few things that can't be done when just-in-time because some assumptions are not guaranteed to be satisfied.

There are no comments on this comment yet.