I have been running a bunch of tests with Apple M1 and wanted to share my results.
Here are the test results.
Now for some explanation:
-
all the tests are using VST3 SDK 3.7.1 which is the most recent SDK at the time I ran the tests
-
Intel
is a (“old”) MacBook pro running macOS Mojave v10.14.6 and Xcode 11.3.1 and is of course using the intel / chipset [x86_64
] -
M1
is a new MacBook Air running macOS Big Sur v11.0 and Xcode 12.3 and is using the new Apple M1 arm chipset [arm64
] -
The first column (column A) shows the hardware running the test (rows 3-6 are on Intel, 8-11 are on M1)
-
I have then built the
validator
tool and a test plugin 4 different ways:
-
intel x86_64
means it was built on the Intel hardware using thex86_64
architecture (note that this is the only possible way of building for this platform) -
m1 x86_64
means it was built on the M1 hardware using thex86_64
architecture -
m1 arm64
means it was built on the M1 hardware using thearm64
architecture (which is native for this platform) -
m1 univeral
means it was built on the M1 hardware using thex86_64
andarm64
architectures so it contains both
In order to build for a specific architecture I have used this CMake variable (defined before project()
) (see this forum thread Looking for someone willing verify a minimal Xcode project on Apple Silicon - Code - CMake Discourse):
set(CMAKE_OSX_ARCHITECTURES "x86_64" CACHE STRING "") # for x86_64
set(CMAKE_OSX_ARCHITECTURES "arm64" CACHE STRING "") # for arm64
set(CMAKE_OSX_ARCHITECTURES "x86_64;amr64" CACHE STRING "") # for universal
-
Columns are for the validator and Rows are for the plugin.
-
For example cell C6 represents running the test on the Intel hardware, test consisting of running the
validator
which was built on M1 hardware with universal architecture and using the test plugin which was built on the Intel hardware with x86_64 architecture. -
Row 5 is all N/A because you cannot run the validator with architecture arm64 on an Intel hardware… Technically E3, E4 and E6 falls under the same category: an arm64 plugin cannot run on Intel platform. I marked it as
N
because it fails gracefully and cannot load it due to not being the correct platform (but at least it doesn’t core dumps…).
I think the results are a bit puzzling:
-
I do not understand why I am getting core dumps. For example Cell C3 which is all the same architecture generates a core dump when the plugin is built on the M1 hardware with x86_64 architecture and ran on Intel hardware. In other words, if you build a plugin on Apple M1, even with x86_64 architecture it does not run on Intel platform.
-
Cell C11 seems to show that the validator (which would be a DAW) if recompiled as a universal binary will not load any of the plugins that have been built with Intel (which at this time is 100% of them…)
From a plugin developer point of view I would like to produce a universal built plugin, but F3 shows that it core dumps when loaded on Intel platform.
From a host developer point of view I would like to produce a universal built host which shows that it works on intel platform (C6) but unfortunately does not load Intel plugins (C11).
The “good” news is that staying x86_64 on the new platform on both sides (which goes through the Rosetta 2 translation layer) works.
Disclaimer: What I am stating here is based on the tests I have ran based on my knowledge of how things work. There may be different compiler options to provide that would trigger a different outcome (core dumps are definitely puzzling). Also I have used the validator
as-is from SDK 3.7.1 and I do not know if there are changes in the code that need to be made so that Cell C11 is a Y
instead of a N