Would have posted exactly this if you hadn't already. So many pitfalls with M1 in the way Apple subtly veers from normal ARM64 conventions and the published spec. This guy has already figured them out for you. Also helpful to look at the XNU source code to see how they implement syscalls.