[compiler-rt] Do not use ldrexd or strexd on v7M
authorOliver Stannard <oliver.stannard@arm.com>
Mon, 29 Sep 2014 10:23:20 +0000 (10:23 +0000)
committerOliver Stannard <oliver.stannard@arm.com>
Mon, 29 Sep 2014 10:23:20 +0000 (10:23 +0000)
commit609e2e6a6e001bcbe3da469a0c117fa570ca71aa
tree5b7cee154cc654f932f325f7b46845e4326f301d
parent6cbf43167bf33689e8b02920cde6758f8dba8d8d
[compiler-rt] Do not use ldrexd or strexd on v7M

The ldrexd and strexd instructions are undefined for the ARMv7M
architecture, so we cannot use them to implement the
__sync_fetch_and_*_8 builtins. There is no other way to implement
these without OS support, so this patch #ifdef's these functions out
for M-class architectures.

There are no tests as I cannot find any existing tests for these
builtins.

I used the __ARM_ARCH_PROFILE predefine because __ARM_FEATURE_LDREX is
deprecated and not set by clang.

llvm-svn: 218601
compiler-rt/lib/builtins/arm/sync_fetch_and_add_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_and_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_max_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_min_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_nand_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_or_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_sub_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_umax_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_umin_8.S
compiler-rt/lib/builtins/arm/sync_fetch_and_xor_8.S