Commit 20a44f0
committed
compiler-rt: Exclude sync_fetch_and_* for any pre-ARMv6 targets
Sometimes builds may happen where ABI is not indidated by host_triple
e.g. on Yocto the compiler used is called arm-poky-linux-gnueabi-clang
for all arm32 cross compilers, it passed the ABI flags on cmdline in
addition. e.g.
-march=armv5te -mfloat-abi=soft
or
-march=armv7-a -mfloat-abi=hard
compiler-rt's makery tries to add arm to COMPILER_RT_SUPPORTED_ARCH
deducing it from triple name.
which ends up choosing `arm` as one of compiler-rt arch to build for.
This arch is however using armv7+ defaults and then tried to build sync
builtins using
arm-poky-linux-gnueabi-clang -march=armv5te -mfloat-abi=soft ...
Which does not compile correctly, in such cases it should simply
remove the sync builtins from list of things to build similar to what
is done when we use armv4t or armv5t
set(armv4t_SOURCES ${arm_min_SOURCES})
set(armv5te_SOURCES ${arm_min_SOURCES})
This lets compiler-rt build for arm architectures without depending
upong compiler triple, but instead of poking the compiler for what
it is building for
Upstream-Status: Submitted [llvm#139411]
Signed-off-by: Khem Raj <[email protected]>1 parent 62ffdae commit 20a44f0
1 file changed
+12
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
920 | 920 | | |
921 | 921 | | |
922 | 922 | | |
| 923 | + | |
| 924 | + | |
| 925 | + | |
| 926 | + | |
| 927 | + | |
| 928 | + | |
| 929 | + | |
| 930 | + | |
| 931 | + | |
| 932 | + | |
| 933 | + | |
| 934 | + | |
923 | 935 | | |
924 | 936 | | |
925 | 937 | | |
| |||
0 commit comments