diff options
author | Abderrazek Zaafrani <a.zaafrani@samsung.com> | 2017-06-20 18:54:57 +0000 |
---|---|---|
committer | Abderrazek Zaafrani <a.zaafrani@samsung.com> | 2017-06-20 18:54:57 +0000 |
commit | 6e3f80de39298b1ac410e59841c60853e807fa37 (patch) | |
tree | fdd670689cf908e64769e2f646d9e70baf7f17cb /lib/Basic/Targets.cpp | |
parent | c35b73c765d276f2433f2f89229022e5f08b003c (diff) |
[AArch64] ADD ARMv.2-A FP16 vector intrinsics
Differential Revision: https://reviews.llvm.org/D34161
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@305820 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Basic/Targets.cpp')
-rw-r--r-- | lib/Basic/Targets.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/Basic/Targets.cpp b/lib/Basic/Targets.cpp index a3b8330707..e23a93e8ce 100644 --- a/lib/Basic/Targets.cpp +++ b/lib/Basic/Targets.cpp @@ -6172,6 +6172,8 @@ class AArch64TargetInfo : public TargetInfo { unsigned Crypto; unsigned Unaligned; unsigned V8_1A; + unsigned V8_2A; + unsigned HasFullFP16; static const Builtin::Info BuiltinInfo[]; @@ -6303,6 +6305,8 @@ public: if (V8_1A) Builder.defineMacro("__ARM_FEATURE_QRDMX", "1"); + if (V8_2A && FPU == NeonMode && HasFullFP16) + Builder.defineMacro("__ARM_FEATURE_FP16_VECTOR_ARITHMETIC", "1"); // All of the __sync_(bool|val)_compare_and_swap_(1|2|4|8) builtins work. Builder.defineMacro("__GCC_HAVE_SYNC_COMPARE_AND_SWAP_1"); @@ -6330,6 +6334,8 @@ public: Crypto = 0; Unaligned = 1; V8_1A = 0; + V8_2A = 0; + HasFullFP16 = 0; for (const auto &Feature : Features) { if (Feature == "+neon") @@ -6342,6 +6348,10 @@ public: Unaligned = 0; if (Feature == "+v8.1a") V8_1A = 1; + if (Feature == "+v8.2a") + V8_2A = 1; + if (Feature == "+fullfp16") + HasFullFP16 = 1; } setDataLayout(); |