A new fan project, bo2-mac, enables Call of Duty: Black Ops II to run natively on Apple Silicon by converting the game's original x86 machine code into ARM64 code ahead of time. Unlike traditional compatibility layers like Wine, which translate Windows calls at runtime, this project ensures the game runs as native code in a single process, achieving 51–60 frames per second on an Apple M1 chip.
This image provides a high-level overview of the project's goals and the performance benchmarks achieved on Apple M1 hardware.
This visual illustrates the first step of the recompilation pipeline mentioned in the technical overview.
The Recompilation Pipeline
The bo2-mac project transforms three x86 Windows executables—the campaign, Zombies, and multiplayer—into native ARM64 code. The process involves five steps: verifying the Steam build via SHA-256, cataloging and lifting functions to LLVM IR using Remill, 'folding' that IR to inline guest memory accesses, implementing a Win32 runtime, and managing guest threads as coroutines.
Chart drawn by HN Digest from figures reported by github.com; values are shown as written in the source.
To maintain performance, the project rewrites the lifted IR before passing it to clang -O2. This ensures that guest reads and writes are inlined and that lock sequences are converted into hardware atomics. Because ARM is not Total Store Order (TSO) compliant, the project uses real memory barriers to manage these operations.
“There is no Wine and no JIT: the game runs as native code, in one process.”
— GitHub - adrbn/bo2-mac: Call of Duty: Black Ops II statically recompiled from 32-bit x86 Windows to native ARM64 macOS:
Graphics and Runtime Translation
Because the game relies on Direct3D 11, the project implements a fake-COM layer that translates these calls to Apple's Metal framework. Shader translation is handled by HLSLcc, a C++ library that converts DXBC shaders into Metal-compatible code.
This diagram explains the graphics translation mechanism described in the Graphics and Runtime Translation section.
Other system components are also ported to native macOS frameworks. XAudio2 is mapped to CoreAudio, and videos are decoded using libvpx. The project also includes a local responder to simulate the Demonware service, allowing the game to handle lobby and storage requests without an internet connection.
Technical Trade-offs and Limitations
While the game runs natively, it is currently limited to local play. There is no support for online services, LAN, or co-op modes, as the project relies on a local responder to simulate the game's backend. Additionally, the match rules for Zombies and multiplayer are custom-written in a 'clean room' environment, meaning behavior may differ slightly from the original game.
The project also faces hardware constraints; the developer reported that the Mac runs very hot during long sessions, reaching temperatures between 111–116 °C on an M1 chip. Furthermore, while the conversion is successful, the game remains a local experience that requires the user to own the original Steam copy to build the app.