> On ARM we’d also run into alignment issues...
Just don't use ARMv5 or older. ARMv6+ supports unaligned access.
Just don't use ARMv5 or older. ARMv6+ supports unaligned access.
By the way, you can also opt to crash on x86. Just need to enable bit AM (Alignment Mask) bit 18) in CR0 (kernel stuff) and AC (Alignment Check, also bit 18) in EFLAGS.
After that point, unaligned accesses trap. I use this in my CPU JIT/dynamic compiler to trap target unaligned accesses.