Releases of the Box86 0.2.6 and Box64 0.1.8 emulators have been published, designed to run Linux programs compiled for x86 and x86_64 architectures on hardware with ARM, ARM64, PPC64LE, and RISC-V processors. The projects are developed synchronously by the same team of developers — Box86 is limited to running 32-bit x86 applications, while Box64 supports 64-bit executable files. The project pays special attention to organizing the launch of gaming applications, including the ability to run Windows builds through wine and Proton. The source code of the project is written in C and is distributed (Box86, Box64) under the MIT license.
A distinctive feature of the project is the use of a hybrid execution model, where emulation is applied only to the machine code of the application itself and specific libraries. Standard system libraries, including libc, libm, GTK, SDL, Vulkan, and OpenGL, are replaced with versions native to the target platforms. Thus, library calls are executed without emulation, allowing for significant performance increases.
Code emulation, where native replacements for the target platform are unavailable, is performed using dynamic recompilation (DynaRec) techniques from one set of machine instructions to another. Compared to interpreting machine instructions, dynamic recompilation demonstrates 5-10 times higher performance.
In performance tests, the Box86 and Box64 emulators significantly outperformed the QEMU and FEX-emu projects on Armhf and Aarch64 platforms, achieving performance in certain tests (glmark2, openarena) comparable to running a native build for the target platform. In tests with 7-zip and dav1d, which perform intensive calculations, the performance of Box64 ranged from 27% to 53% of the native application performance (in comparison, QEMU showed results of 5-16%, while FEX-emu showed 13-26%). Additionally, a comparison was made with the Rosetta 2 emulator used by Apple to run x86 code on systems with the M1 ARM chip. Rosetta 2 achieved a performance of 71% of the native build for the 7zip test, while Box64 achieved 57%.

Regarding application compatibility, out of 165 tested games, around 70% worked successfully. About 10% work, but with certain caveats and limitations. Supported games include WorldOfGoo, Airline Tycoon Deluxe, FTL, Undertale, A Risk of Rain, Cook Serve Delicious, and most games from GameMaker. Among the games noted for issues are those based on the Unity3D engine, which relies on the Mono package, the emulation of which does not always work due to the JIT compilation used in Mono, and it has quite high graphical requirements that are not always achievable on ARM platforms. Library replacements for GTK applications are currently limited to GTK2 (replacement for GTK3/4 is not fully implemented).
The main changes in the new releases:
- A wrapper for the Vulkan library has been added. Support for the Vulkan graphics API and DXVK (implementation of DXGI, Direct3D 9, 10, and 11 over Vulkan) has been added.
- Improved wrappers for GTK libraries. Wrappers for gstreamer and libraries commonly used in GTK applications have been added.
- Initial support (currently only interpretation mode) for RISC-V and PPC64LE architectures has been added.
- Fixes aimed at improving SteamPlay and the Proton layer have been implemented. Many Linux and Windows games from Steam can now be run on AArch64 boards, such as Raspberry Pi 3 and 4.
- Memory management has been improved, with better mmap functionality and memory protection violation tracking.
- Support for the clone system call in libc has been enhanced. New system calls have been added.
- Improvements in the dynamic recompilation engine with regard to SSE/x87 registers, support for new machine codes, optimization of float and double transformations, enhanced handling of internal jumps, and simplified addition of support for new architectures have been made.
- The ELF file loader has been improved.
Source: opennet.ru
