The latest release of the emulator Box64 0.4.0 has been published, aimed at running Linux programs compiled for x86_64 architecture on devices with ARM64, RISC-V processors, and Loongarch64. The project focuses on facilitating the launch of gaming applications and provides the capability to run Windows builds through Wine and Proton. The source code of the project is written in C and available under the MIT license.
One key feature of the project is its hybrid execution model, where emulation is restricted to the application’s machine code and specific libraries. System libraries like libc, libm, GTK, SDL, Vulkan, and OpenGL are substituted with native variants on the target platforms. This approach enables library calls to be executed without emulation, resulting in significant performance enhancements.
For code without native replacements on the target platform, dynamic recompilation (DynaRec) is utilized to convert one set of machine instructions to another. Compared to interpreting machine instructions, dynamic recompilation offers 5-10 times higher performance.
A unified prefix decoder for operation codes has been introduced, serving in the interpreter and all dynamic backend recompilations (DynaRec). This new decoder efficiently handles rare combinations of opcode prefixes, eliminating the need for specific “hacks” and code duplication in the DynaRec interpreter and backends. The decoder overhaul has led to code simplification, easier maintenance, and improved handling of atypical opcode prefix combinations by DynaRec.
- Progress has commenced on a mechanism to remove from memory code blocks that have been converted to native code but are no longer in use. This optimization is beneficial in reducing memory consumption during the operation of applications that execute numerous operations upon startup, such as Steam and applications utilizing libcef.
- Enhanced support for the ARM64 architecture includes the implementation of a assembly profile for the NVIDIA GB10 CPU. The dynamic recompilation backend (DynaRec) continues to incorporate loop optimization techniques like eliminating operations for setting XMM/YMM registers from the loop body.