From 8795ffb03c1bb84a0d93e4ece153ceaa86118594 Mon Sep 17 00:00:00 2001 From: Georgios Pinitas Date: Fri, 1 Dec 2017 16:13:40 +0000 Subject: COMPMID-700: Adds CPPPermute function Change-Id: I8f6adc67f6e6157710fca540f217d70e6f297217 Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/111721 Tested-by: BSG Visual Compute Jenkins server to access repositories on http://mpd-gerrit.cambridge.arm.com Reviewed-by: Anthony Barbier --- src/core/NEON/kernels/NEMinMaxLocationKernel.cpp | 35 ++++++------------------ 1 file changed, 8 insertions(+), 27 deletions(-) (limited to 'src/core/NEON/kernels/NEMinMaxLocationKernel.cpp') diff --git a/src/core/NEON/kernels/NEMinMaxLocationKernel.cpp b/src/core/NEON/kernels/NEMinMaxLocationKernel.cpp index c7dc03c8c8..ad66acd8fa 100644 --- a/src/core/NEON/kernels/NEMinMaxLocationKernel.cpp +++ b/src/core/NEON/kernels/NEMinMaxLocationKernel.cpp @@ -32,6 +32,7 @@ #include "arm_compute/core/Types.h" #include "arm_compute/core/Validate.h" #include "arm_compute/core/Window.h" +#include "arm_compute/core/utils/misc/utility.h" #include #include @@ -319,34 +320,14 @@ bool NEMinMaxLocationKernel::is_parallelisable() const return false; } -template -struct index_seq -{ - index_seq() = default; - index_seq(const index_seq &) = default; - index_seq &operator=(const index_seq &) = default; - index_seq(index_seq &&) noexcept = default; - index_seq &operator=(index_seq &&) noexcept = default; - virtual ~index_seq() = default; -}; -template -struct gen_index_seq : gen_index_seq < N - 1, N - 1, S... > -{ -}; -template -struct gen_index_seq<0u, S...> : index_seq -{ - using type = index_seq; -}; - -template -struct NEMinMaxLocationKernel::create_func_table> +template +struct NEMinMaxLocationKernel::create_func_table> { static const NEMinMaxLocationKernel::MinMaxLocFunction func_table[sizeof...(N)]; }; -template -const NEMinMaxLocationKernel::MinMaxLocFunction NEMinMaxLocationKernel::create_func_table>::func_table[sizeof...(N)] = +template +const NEMinMaxLocationKernel::MinMaxLocFunction NEMinMaxLocationKernel::create_func_table>::func_table[sizeof...(N)] = { &NEMinMaxLocationKernel::minmax_loc... }; @@ -378,13 +359,13 @@ void NEMinMaxLocationKernel::configure(const IImage *input, void *min, void *max switch(input->info()->data_type()) { case DataType::U8: - _func = create_func_table::type>::func_table[table_idx]; + _func = create_func_table>::func_table[table_idx]; break; case DataType::S16: - _func = create_func_table::type>::func_table[table_idx]; + _func = create_func_table>::func_table[table_idx]; break; case DataType::F32: - _func = create_func_table::type>::func_table[table_idx]; + _func = create_func_table>::func_table[table_idx]; break; default: ARM_COMPUTE_ERROR("Unsupported data type"); -- cgit v1.2.1