November 10, 2023
arm64EC on Windows 11
Oh hi there, I guess it's been a while! REAPER v7 has launched. Right on.
I've spent some time on and off occasionally getting REAPER to run natively on Windows/arm64. There's practically
no demand for such a thing, but the platform exists so it's worth thinking about. I read various reviews of some arm
laptops that ran Windows and the real issue seemed to be lack of native software.
Anyway, in trying to finish these builds, I learned about something new in Windows 11/arm: the "arm64ec" ABI. This allows emulating x86_64 on native arm64 processes, with the ability for arm64 code to load/call x86_64 code without having to do any process bridging or anything like that. It's pretty much designed for DAWs, which need to load plug-ins in process for performance.
I posted a build of REAPER to our pre-release site which uses this. What cool is that there are a few libraries we ship with which we don't have ARM versions, but REAPER happily loads the x86_64 versions and they work! (one is libmp3lame.dll, haven't gotten around to making a native build of that.
The only real hiccups were porting the dynamic code generation of EEL2: symbols get a # prefix, there are a few registers you can't use, and you have to use VirtualAlloc2() to allocate code memory and tag it as being arm code rather than x86_64.
Not sure if this stuff will ever be worth releasing, but it's fun, and if you're interested you can play with it.
P.S. the new code signing requirement that the key needs to be stored in a hardware security module (e.g. Yubikey) is completely misguided. The Yubikey always wants you to enter the PIN, too. SMH. Additionally, if you remote desktop into a Windows 10 computer, you can't use the locally-installed HSM! So alas, I've installed TightVNC for the first time in more than a decade (not sure if that's a security win...).