diff options
Diffstat (limited to 'newlib/libc/machine/arm/strcmp-armv4.S')
-rw-r--r-- | newlib/libc/machine/arm/strcmp-armv4.S | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/newlib/libc/machine/arm/strcmp-armv4.S b/newlib/libc/machine/arm/strcmp-armv4.S index 05e3df675..e8d0e2468 100644 --- a/newlib/libc/machine/arm/strcmp-armv4.S +++ b/newlib/libc/machine/arm/strcmp-armv4.S @@ -43,6 +43,18 @@ #define tmp1 r12 #define syndrome r12 /* Overlaps tmp1 */ +/* For armv4t and newer, toolchains will transparently convert + 'bx lr' to 'mov pc, lr' if needed. GCC has deprecated support + for anything older than armv4t, but this should handle that + corner case in case anyone needs it anyway */ +.macro RETURN +#if __ARM_ARCH <= 4 && __ARM_ARCH_ISA_THUMB == 0 + mov pc, lr +#else + bx lr +#endif +.endm + .arm def_fn strcmp .cfi_sections .debug_frame |