darwin/arm64: fix SIMD detection and improve ARM feature probing (#160)
* darwin/arm64: fix SIMD detection and improve ARM feature probing Detection of Advanced SIMD (NEON) on M1 Macs was broken due to querying the wrong sysctl identifier. Apple's documentation lists "hw.optional.AdvSIMD" as the correct identifier, but in reality, it's "hw.optional.arm.AdvSIMD" as confirmed by `sysctl -a`. This patch corrects the identifier and adds support for its alias, "hw.optional .neon," ensuring proper detection across all models. Additionally, this patch revisits all ARM features detected by the package, cross-referencing identifiers (and aliases) against both Apple's official sysctl documentation: https://developer.apple.com/documentation/kernel/1387446-sysctlbyname/determining_instruction_set_characteristics and the ARM architecture reference manual: https://developer.arm.com/documentation/ddi0487/latest Each ARM feature now maps to all known sysctl aliases, preventing false negatives and improving detection accuracy on Apple Silicon. * nit * fix typo
H
Hippolyte Barraud committed
462c017bbfc200ee42e8fb92410c244b8d3bf71e
Parent: 668c84e
Committed by GitHub <noreply@github.com>
on 5/14/2025, 7:35:32 AM