Search code examples
armcpu-architecturebackwards-compatibilityarmv7binary-compatibility

What parts of ARMv4/5/6 code will not work on ARMv7?


It is my understanding that ARMv7 processors, such as the Cortex-A9, are mostly backwards-compatible with code for older ARM architecture versions. However, I've read reports of segfaults trying to run ARM9 code on a Cortex-A8, for example.

What parts of ARMv4/5/6 (ARM7TDMI/ARM9/ARM11) code will not work on an ARMv7 processor? What features or architectural characteristics exist in these older ARM architecture versions that can cause a program built for these versions to fail on ARMv7?


Solution

  • For application code the principal problem is unaligned memory accesses. Before ARMv4 and configurable on ARMv4 to ARMv6 a LDR load from an unaligned address would result in the read data being rotated, and other memory access act as if the least significant 2 bits of the address are zero.