From 65938d6d04aa2d14194d485cafaaaa12f508855a Mon Sep 17 00:00:00 2001 From: Adolfo Delorenzo Date: Thu, 14 May 2026 15:15:45 -0600 Subject: [PATCH] fix(qemu): use -cpu max so piCore64 binaries don't hit instruction aborts piCore64's BusyBox segfaults under QEMU virt with -cpu cortex-a72, generating an EL0 Instruction Abort (el0_ia in the panic call trace). The binary is built with ARMv8 extensions (likely +lse atomics, +crypto, or +fp16) that the cortex-a72 model doesn't enable by default. Switch to -cpu max which enables all emulated ARMv8 features. This is fine for dev testing; the actual production hosts (Graviton, Ampere, real ARM64 hardware) all have these features natively. Co-Authored-By: Claude Opus 4.7 (1M context) --- hack/dev-vm-arm64.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/hack/dev-vm-arm64.sh b/hack/dev-vm-arm64.sh index 40be3f2..c262110 100755 --- a/hack/dev-vm-arm64.sh +++ b/hack/dev-vm-arm64.sh @@ -120,9 +120,13 @@ if [ "$MODE" = "disk" ]; then echo " Press Ctrl+A X to exit QEMU" echo "" + # -cpu max enables all emulated ARMv8 features (atomics, crypto, fp16). + # piCore64's BusyBox is built with -march=armv8-a+crypto+lse and segfaults + # under -cpu cortex-a72 because some required extensions aren't on by + # default in that model. qemu-system-aarch64 \ -machine virt \ - -cpu cortex-a72 \ + -cpu max \ -m 2048 \ -smp 2 \ -nographic \ @@ -186,7 +190,7 @@ echo "" qemu-system-aarch64 \ -machine virt \ - -cpu cortex-a72 \ + -cpu max \ -m 2048 \ -smp 2 \ -nographic \