31 ms·
As a slight correction, I believe Rosetta 2 also has a JIT mode, which is a bit more like conventional emulators. But it's used infrequently, eg when dealing w
by less_less 4y ago
As a slight correction, I believe Rosetta 2 also has a JIT mode, which is a bit more like conventional emulators. But it's used infrequently, eg when dealing with x86_64 apps that themselves use a JIT.
- lloeki 4y ago> 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†, Rosetta 2 does the same†† translation step on dynamic Intel code, 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-fast/ https://dougallj.wordpress.com/2022/11/09/why-is-rosetta-2-f... † Unless you've been meaning dynarec, but I would not call that "conventional" although it is a well-known technique https://en.wikipedia.org/wiki/Dynamic_recompilation 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.
- brookst 4y agoThanks, that is definitely correct. Rosetta 2 can do JIT, and it gets exercised for native JIT / dynamic code. I could probably extend the metaphor to an avant garde French novel that asks the reader to look up and include today’s headlines from Le Monde, but it was already stretched.