summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/ARM/ARMSubtarget.h
diff options
context:
space:
mode:
authorRenato Golin <renato.golin@linaro.org>2015-11-09 12:40:30 +0000
committerRenato Golin <renato.golin@linaro.org>2015-11-09 12:40:30 +0000
commit6d435f12f0ef0be987476a3e18215fbcd182bcd1 (patch)
tree13895dabeb67795d69a68a8c65e4e27e6851aa38 /llvm/lib/Target/ARM/ARMSubtarget.h
parent1d8a2c952f9073b5ee06d262704aec03e3b25c56 (diff)
downloadbcm5719-llvm-6d435f12f0ef0be987476a3e18215fbcd182bcd1.tar.gz
bcm5719-llvm-6d435f12f0ef0be987476a3e18215fbcd182bcd1.zip
[EABI] Add LLVM support for -meabi flag
"GCC requires the freestanding environment provide memcpy, memmove, memset and memcmp": https://gcc.gnu.org/onlinedocs/gcc-5.2.0/gcc/Standards.html Hence in GNUEABI targets LLVM should not convert 'memops' to their equivalent '__aeabi_memops'. This convertion violates GCC contract. The -meabi flag controls whether or not LLVM will modify 'memops' in GNUEABI targets. Without -meabi: use the triple default EABI. With -meabi=default: use the triple default EABI. With -meabi=gnu: use 'memops'. With -meabi=4 or -meabi=5: use '__aeabi_memops'. With -meabi set to an unknown value: same as -meabi=default. Patch by Vinicius Tinti. llvm-svn: 252462
Diffstat (limited to 'llvm/lib/Target/ARM/ARMSubtarget.h')
-rw-r--r--llvm/lib/Target/ARM/ARMSubtarget.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Target/ARM/ARMSubtarget.h b/llvm/lib/Target/ARM/ARMSubtarget.h
index 66b56d10faa..530aa63fff4 100644
--- a/llvm/lib/Target/ARM/ARMSubtarget.h
+++ b/llvm/lib/Target/ARM/ARMSubtarget.h
@@ -380,6 +380,11 @@ public:
TargetTriple.getEnvironment() == Triple::EABIHF) &&
!isTargetDarwin() && !isTargetWindows();
}
+ bool isTargetGNUAEABI() const {
+ return (TargetTriple.getEnvironment() == Triple::GNUEABI ||
+ TargetTriple.getEnvironment() == Triple::GNUEABIHF) &&
+ !isTargetDarwin() && !isTargetWindows();
+ }
// ARM Targets that support EHABI exception handling standard
// Darwin uses SjLj. Other targets might need more checks.
OpenPOWER on IntegriCloud