news.volyx.in

Why is Rosetta 2 fast? (dougallj.wordpress.com)

650 points by pantalaimon · 1398 days ago · 358 comments on HN

Article summary

The article explores the reasons behind the speed of Rosetta 2, an emulator that translates x86 code to run on Apple's ARM-based M1 chips. It attributes the speed to a combination of ahead-of-time translation, efficient use of ARM instructions, and hardware features such as total store ordering. The emulator's design also prioritizes simplicity and maintainability over optimization, which contributes to its performance. The article concludes that while there is room for improvement, Rosetta 2's tradeoffs have been effective in achieving its goals.

Main themes

  • Rosetta 2 performance
  • Emulation technology
  • ARM architecture
  • RISC-V adoption
  • Apple hardware and software strategy
  • Legacy software support

What commenters say

  • Rosetta 2's speed is largely due to the fast hardware of the M1 chips, rather than the emulator itself.
  • The emulator's design prioritizes simplicity and maintainability over optimization, which is a deliberate tradeoff.
  • Rosetta 2 may not be a permanent fixture and could be removed by Apple once the need for it diminishes.
  • The knowledge gained from developing Rosetta 2 could be applied to other architectures, such as RISC-V.
  • Apple may eventually switch to RISC-V for certain cores or applications, given its flexibility and customizability.
  • The removal of Rosetta 2 would not significantly impact most users, as few important Intel-only macOS software will exist in the future.
  • Rosetta 2's ability to run 32-bit software and its potential use in Linux VMs could extend its lifespan.
  • The development of Rosetta 2 has implications for the broader industry, including the potential for RISC-V adoption and the evolution of emulation technology.