Repository navigation
FEX-Emu on macOS arm64 | avx(2) #3267
|
I couldn't find any information on this topic. This lead me here. Is it possible to use FEX on macOS or would that require additional developing. While Rosetta works incredible great it does not feature AVX(2) support, which is required by more and more game titles. In my imagination there are two scenarios to mitigate this: Either FEX could be a drop-in replacement for Rosetta, or the AVX(2) translation parts could be an addition to Rosetta. Is either of this feasible? EDIT: |
Replies: 3 comments 7 replies
|
We still don't have plans to support MacOS, but our AVX/AVX2 emulation falls back to 128-bit ASIMD and uses SVE to supplement if available. The information below is old |
|
Just in case someone stumbles on this in the future. |
|
Late to this, but I measured the macOS side of it recently and wrote up the results, in case it saves anyone the work: https://github.com/shalaga44/rosetta-4k-pages The short version is that the 4 KiB page problem has a harder form on macOS than it does on Asahi. There's no 4K kernel to boot, and you can't get 4 KiB pages in a native ARM64 process at all. On Apple Silicon a process gets 4 KiB pages only if it's an x86-64 binary running under Rosetta, and such a process can't execute ARM64 instructions, even ones written into Both properties are selected by the same field: the Mach-O Four ways around it, all closed:
So it's hardware execution state, not a software gate. The repo has five runnable proofs (~200 lines of C, no root, no SIP changes) so anyone can check this on their own machine rather than take my word for it. Two side findings that might be more immediately useful here: CPUID under-reports AVX under Rosetta. Leaf 1 says Confirming the SVE point from upthread, by execution rather than by spec: Tested on macOS 27.0 (26A428), M1 Pro. Undocumented internal behaviour on one machine and one OS build, so corrections welcome. |
We still don't have plans to support MacOS, but our AVX/AVX2 emulation falls back to 128-bit ASIMD and uses SVE to supplement if available.
The information below is old
FEX only supports Linux. It doesn't have any plans to support MacOS.
Additionally our AVX emulation requires ARM64 hardware that supports SVE2 with 256-bit wide registers, which Apple Silicon doesn't support.