diff options
author | Ioan-Cristian Szabo <ioan-cristian.szabo@arm.com> | 2017-11-13 13:34:08 +0000 |
---|---|---|
committer | Anthony Barbier <anthony.barbier@arm.com> | 2018-11-02 16:35:24 +0000 |
commit | 5edbd1c5dce43b66f30c903797a91e39369c5b62 (patch) | |
tree | d4c20c1a92ff9a7e26ffc9b1f6976ee12a2e2ae0 /src/core/NEON/kernels/NEActivationLayerKernel.cpp | |
parent | 84b51ad1aaa530d397761f2b6da65add9dc8a6b0 (diff) | |
download | ComputeLibrary-5edbd1c5dce43b66f30c903797a91e39369c5b62.tar.gz |
COMPMID-556: Add support to build arm64-v8.2-a for Android platform (clang compiler)
Change-Id: Ibb779dd3a8d10786da6d8f70590e654e14654d7b
Reviewed-on: http://mpd-gerrit.cambridge.arm.com/95530
Tested-by: Kaizen <jeremy.johnson+kaizengerrit@arm.com>
Reviewed-by: Pablo Tello <pablo.tello@arm.com>
Diffstat (limited to 'src/core/NEON/kernels/NEActivationLayerKernel.cpp')
-rw-r--r-- | src/core/NEON/kernels/NEActivationLayerKernel.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/core/NEON/kernels/NEActivationLayerKernel.cpp b/src/core/NEON/kernels/NEActivationLayerKernel.cpp index 8dfce0f7b5..94bd5f15e3 100644 --- a/src/core/NEON/kernels/NEActivationLayerKernel.cpp +++ b/src/core/NEON/kernels/NEActivationLayerKernel.cpp @@ -81,7 +81,7 @@ void NEActivationLayerKernel::configure(ITensor *input, ITensor *output, Activat { ActivationFunction::TANH, &NEActivationLayerKernel::activation<ActivationFunction::TANH, float> }, }; -#ifdef ARM_COMPUTE_AARCH64_V8_2 +#ifdef __ARM_FEATURE_FP16_VECTOR_ARITHMETIC // Activation functions : FP16 static std::map<ActivationFunction, ActivationFunctionExecutorPtr> act_map_f16 = { @@ -96,7 +96,7 @@ void NEActivationLayerKernel::configure(ITensor *input, ITensor *output, Activat { ActivationFunction::SQUARE, &NEActivationLayerKernel::activation<ActivationFunction::SQUARE, float16_t> }, { ActivationFunction::TANH, &NEActivationLayerKernel::activation<ActivationFunction::TANH, float16_t> }, }; -#endif /* ARM_COMPUTE_AARCH64_V8_2*/ +#endif /* __ARM_FEATURE_FP16_VECTOR_ARITHMETIC*/ // Activation functions : QS8 static std::map<ActivationFunction, ActivationFunctionExecutorPtr> act_map_qs8 = @@ -140,11 +140,11 @@ void NEActivationLayerKernel::configure(ITensor *input, ITensor *output, Activat case DataType::F32: _func = act_map_f32[activation_info.activation()]; break; -#ifdef ARM_COMPUTE_AARCH64_V8_2 +#ifdef __ARM_FEATURE_FP16_VECTOR_ARITHMETIC case DataType::F16: _func = act_map_f16[activation_info.activation()]; break; -#endif /* ARM_COMPUTE_AARCH64_V8_2 */ +#endif /* __ARM_FEATURE_FP16_VECTOR_ARITHMETIC */ default: ARM_COMPUTE_ERROR("Unsupported data type."); } @@ -174,7 +174,7 @@ void NEActivationLayerKernel::configure(ITensor *input, ITensor *output, Activat ICPPKernel::configure(win); } -#ifdef ARM_COMPUTE_AARCH64_V8_2 +#ifdef __ARM_FEATURE_FP16_VECTOR_ARITHMETIC template <ActivationLayerInfo::ActivationFunction F, typename T> typename std::enable_if<std::is_same<T, float16_t>::value, void>::type NEActivationLayerKernel::activation(const Window &window) { @@ -305,7 +305,7 @@ typename std::enable_if<std::is_same<T, float16_t>::value, void>::type NEActivat }, input, output); } -#endif /* ARM_COMPUTE_AARCH64_V8_2 */ +#endif /* __ARM_FEATURE_FP16_VECTOR_ARITHMETIC */ template <ActivationLayerInfo::ActivationFunction F, typename T> typename std::enable_if<std::is_same<T, float>::value, void>::type NEActivationLayerKernel::activation(const Window &window) |