aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMoritz Pflanzer <moritz.pflanzer@arm.com>2017-06-29 14:51:57 +0100
committerAnthony Barbier <anthony.barbier@arm.com>2018-09-17 14:15:39 +0100
commitd0ae8b8ac8a371fd552c46d4b3be3db8628a5ade (patch)
treee4b035d01add61c37fcbeaf38a6a54e550235d8f
parent5cb4c42cb5d781a44409ebc97a408e1379ce182d (diff)
downloadComputeLibrary-d0ae8b8ac8a371fd552c46d4b3be3db8628a5ade.tar.gz
COMPMID-417: Extract common toolchain support file
The support file is needed as Android toolchains are missing some C++11 functions. It further includes functions that have been introduced in C++14 but which we already need. Eventually the support file might become unnecessary if the Android compilers improve and we switch to C++14. Change-Id: Ib5ec506f1a17c78149c315ab2096b901b852c180 Reviewed-on: http://mpd-gerrit.cambridge.arm.com/79247 Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com> Tested-by: Kaizen <jeremy.johnson+kaizengerrit@arm.com> Reviewed-by: Pablo Tello <pablo.tello@arm.com>
-rw-r--r--arm_compute/core/CL/CLHelpers.h5
-rw-r--r--arm_compute/core/Helpers.h40
-rw-r--r--arm_compute/runtime/Array.h4
-rw-r--r--src/runtime/CL/CLMultiHOG.cpp4
-rw-r--r--src/runtime/CL/CLPyramid.cpp4
-rw-r--r--src/runtime/CL/functions/CLAbsoluteDifference.cpp4
-rw-r--r--src/runtime/CL/functions/CLAccumulate.cpp8
-rw-r--r--src/runtime/CL/functions/CLActivationLayer.cpp4
-rw-r--r--src/runtime/CL/functions/CLArithmeticAddition.cpp4
-rw-r--r--src/runtime/CL/functions/CLArithmeticSubtraction.cpp4
-rw-r--r--src/runtime/CL/functions/CLBitwiseAnd.cpp4
-rw-r--r--src/runtime/CL/functions/CLBitwiseNot.cpp4
-rw-r--r--src/runtime/CL/functions/CLBitwiseOr.cpp4
-rw-r--r--src/runtime/CL/functions/CLBitwiseXor.cpp4
-rw-r--r--src/runtime/CL/functions/CLBox3x3.cpp4
-rw-r--r--src/runtime/CL/functions/CLCannyEdge.cpp8
-rw-r--r--src/runtime/CL/functions/CLChannelCombine.cpp6
-rw-r--r--src/runtime/CL/functions/CLChannelExtract.cpp6
-rw-r--r--src/runtime/CL/functions/CLColorConvert.cpp10
-rw-r--r--src/runtime/CL/functions/CLConvolution.cpp6
-rw-r--r--src/runtime/CL/functions/CLDepthConcatenate.cpp6
-rw-r--r--src/runtime/CL/functions/CLDepthConvert.cpp4
-rw-r--r--src/runtime/CL/functions/CLDerivative.cpp4
-rw-r--r--src/runtime/CL/functions/CLDilate.cpp4
-rw-r--r--src/runtime/CL/functions/CLErode.cpp4
-rw-r--r--src/runtime/CL/functions/CLFillBorder.cpp4
-rw-r--r--src/runtime/CL/functions/CLGEMMInterleave4x4.cpp4
-rw-r--r--src/runtime/CL/functions/CLGEMMTranspose1xW.cpp4
-rw-r--r--src/runtime/CL/functions/CLGaussian3x3.cpp4
-rw-r--r--src/runtime/CL/functions/CLGaussianPyramid.cpp12
-rw-r--r--src/runtime/CL/functions/CLHOGMultiDetection.cpp14
-rw-r--r--src/runtime/CL/functions/CLHarrisCorners.cpp10
-rw-r--r--src/runtime/CL/functions/CLLaplacianPyramid.cpp6
-rw-r--r--src/runtime/CL/functions/CLLaplacianReconstruct.cpp6
-rw-r--r--src/runtime/CL/functions/CLMagnitude.cpp4
-rw-r--r--src/runtime/CL/functions/CLMedian3x3.cpp4
-rw-r--r--src/runtime/CL/functions/CLNonLinearFilter.cpp4
-rw-r--r--src/runtime/CL/functions/CLNonMaximaSuppression3x3.cpp4
-rw-r--r--src/runtime/CL/functions/CLOpticalFlow.cpp22
-rw-r--r--src/runtime/CL/functions/CLPhase.cpp4
-rw-r--r--src/runtime/CL/functions/CLPixelWiseMultiplication.cpp4
-rw-r--r--src/runtime/CL/functions/CLPoolingLayer.cpp4
-rw-r--r--src/runtime/CL/functions/CLRemap.cpp4
-rw-r--r--src/runtime/CL/functions/CLScale.cpp4
-rw-r--r--src/runtime/CL/functions/CLScharr3x3.cpp4
-rw-r--r--src/runtime/CL/functions/CLSobel3x3.cpp4
-rw-r--r--src/runtime/CL/functions/CLTableLookup.cpp4
-rw-r--r--src/runtime/CL/functions/CLThreshold.cpp4
-rw-r--r--src/runtime/CL/functions/CLTranspose.cpp4
-rw-r--r--src/runtime/CL/functions/CLWarpAffine.cpp4
-rw-r--r--src/runtime/CL/functions/CLWarpPerspective.cpp4
-rw-r--r--src/runtime/Distribution1D.cpp4
-rw-r--r--src/runtime/HOG.cpp4
-rw-r--r--src/runtime/LutAllocator.cpp4
-rw-r--r--src/runtime/MultiHOG.cpp4
-rw-r--r--src/runtime/NEON/functions/NEAbsoluteDifference.cpp4
-rw-r--r--src/runtime/NEON/functions/NEAccumulate.cpp10
-rw-r--r--src/runtime/NEON/functions/NEActivationLayer.cpp4
-rw-r--r--src/runtime/NEON/functions/NEArithmeticAddition.cpp4
-rw-r--r--src/runtime/NEON/functions/NEArithmeticSubtraction.cpp4
-rw-r--r--src/runtime/NEON/functions/NEBitwiseAnd.cpp4
-rw-r--r--src/runtime/NEON/functions/NEBitwiseNot.cpp4
-rw-r--r--src/runtime/NEON/functions/NEBitwiseOr.cpp4
-rw-r--r--src/runtime/NEON/functions/NEBitwiseXor.cpp4
-rw-r--r--src/runtime/NEON/functions/NEBox3x3.cpp6
-rw-r--r--src/runtime/NEON/functions/NECannyEdge.cpp12
-rw-r--r--src/runtime/NEON/functions/NEChannelCombine.cpp6
-rw-r--r--src/runtime/NEON/functions/NEChannelExtract.cpp6
-rw-r--r--src/runtime/NEON/functions/NEColorConvert.cpp10
-rw-r--r--src/runtime/NEON/functions/NEConvolution.cpp6
-rw-r--r--src/runtime/NEON/functions/NEDepthConcatenate.cpp6
-rw-r--r--src/runtime/NEON/functions/NEDepthConvert.cpp5
-rw-r--r--src/runtime/NEON/functions/NEDilate.cpp4
-rw-r--r--src/runtime/NEON/functions/NEErode.cpp4
-rw-r--r--src/runtime/NEON/functions/NEGEMMInterleave4x4.cpp4
-rw-r--r--src/runtime/NEON/functions/NEGEMMTranspose1xW.cpp4
-rw-r--r--src/runtime/NEON/functions/NEGaussian3x3.cpp4
-rw-r--r--src/runtime/NEON/functions/NEGaussianPyramid.cpp14
-rw-r--r--src/runtime/NEON/functions/NEHOGDetector.cpp4
-rw-r--r--src/runtime/NEON/functions/NEHOGGradient.cpp6
-rw-r--r--src/runtime/NEON/functions/NEHOGMultiDetection.cpp15
-rw-r--r--src/runtime/NEON/functions/NEHarrisCorners.cpp22
-rw-r--r--src/runtime/NEON/functions/NEHistogram.cpp6
-rw-r--r--src/runtime/NEON/functions/NEIntegralImage.cpp4
-rw-r--r--src/runtime/NEON/functions/NELaplacianPyramid.cpp6
-rw-r--r--src/runtime/NEON/functions/NELaplacianReconstruct.cpp6
-rw-r--r--src/runtime/NEON/functions/NEMagnitude.cpp6
-rw-r--r--src/runtime/NEON/functions/NEMedian3x3.cpp4
-rw-r--r--src/runtime/NEON/functions/NENonLinearFilter.cpp4
-rw-r--r--src/runtime/NEON/functions/NENonMaximaSuppression3x3.cpp4
-rw-r--r--src/runtime/NEON/functions/NEOpticalFlow.cpp10
-rw-r--r--src/runtime/NEON/functions/NEPhase.cpp4
-rw-r--r--src/runtime/NEON/functions/NEPixelWiseMultiplication.cpp4
-rw-r--r--src/runtime/NEON/functions/NEPoolingLayer.cpp4
-rw-r--r--src/runtime/NEON/functions/NERemap.cpp4
-rw-r--r--src/runtime/NEON/functions/NEScale.cpp3
-rw-r--r--src/runtime/NEON/functions/NEScharr3x3.cpp4
-rw-r--r--src/runtime/NEON/functions/NESobel3x3.cpp4
-rw-r--r--src/runtime/NEON/functions/NETableLookup.cpp4
-rw-r--r--src/runtime/NEON/functions/NEThreshold.cpp4
-rw-r--r--src/runtime/NEON/functions/NETranspose.cpp4
-rw-r--r--src/runtime/NEON/functions/NEWarpAffine.cpp7
-rw-r--r--src/runtime/NEON/functions/NEWarpPerspective.cpp7
-rw-r--r--src/runtime/Pyramid.cpp4
-rw-r--r--support/ToolchainSupport.h310
-rw-r--r--tests/RawTensor.cpp7
-rw-r--r--tests/Utils.h277
-rw-r--r--tests/benchmark/PMUCounter.cpp3
-rw-r--r--tests/benchmark/WallClockTimer.cpp3
-rw-r--r--tests/benchmark/main.cpp5
-rw-r--r--tests/validation/FixedPoint.h3
-rw-r--r--tests/validation/TensorOperations.h9
-rw-r--r--tests/validation/UNIT/FixedPoint.cpp5
-rw-r--r--tests/validation/UNIT/Utils.cpp5
-rw-r--r--tests/validation/main.cpp5
115 files changed, 630 insertions, 614 deletions
diff --git a/arm_compute/core/CL/CLHelpers.h b/arm_compute/core/CL/CLHelpers.h
index 26253e3f38..7b3af33fee 100644
--- a/arm_compute/core/CL/CLHelpers.h
+++ b/arm_compute/core/CL/CLHelpers.h
@@ -26,6 +26,7 @@
#include "arm_compute/core/CL/OpenCL.h"
#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <string>
@@ -70,7 +71,7 @@ const std::string &string_from_target(GPUTarget target);
template <typename Kernel, typename... T>
std::unique_ptr<Kernel> create_configure_kernel(T &&... args)
{
- std::unique_ptr<Kernel> k = arm_compute::cpp14::make_unique<Kernel>();
+ std::unique_ptr<Kernel> k = arm_compute::support::cpp14::make_unique<Kernel>();
k->configure(std::forward<T>(args)...);
return k;
}
@@ -82,7 +83,7 @@ std::unique_ptr<Kernel> create_configure_kernel(T &&... args)
template <typename Kernel>
std::unique_ptr<Kernel> create_kernel()
{
- std::unique_ptr<Kernel> k = arm_compute::cpp14::make_unique<Kernel>();
+ std::unique_ptr<Kernel> k = arm_compute::support::cpp14::make_unique<Kernel>();
return k;
}
diff --git a/arm_compute/core/Helpers.h b/arm_compute/core/Helpers.h
index 07318eaf7a..dfcca96eec 100644
--- a/arm_compute/core/Helpers.h
+++ b/arm_compute/core/Helpers.h
@@ -46,46 +46,6 @@ class IKernel;
class ITensor;
class ITensorInfo;
-namespace cpp14
-{
-template <class T>
-struct _Unique_if
-{
- typedef std::unique_ptr<T> _Single_object;
-};
-
-template <class T>
-struct _Unique_if<T[]>
-{
- typedef std::unique_ptr<T[]> _Unknown_bound;
-};
-
-template <class T, size_t N>
-struct _Unique_if<T[N]>
-{
- typedef void _Known_bound;
-};
-
-template <class T, class... Args>
-typename _Unique_if<T>::_Single_object
-make_unique(Args &&... args)
-{
- return std::unique_ptr<T>(new T(std::forward<Args>(args)...));
-}
-
-template <class T>
-typename _Unique_if<T>::_Unknown_bound
-make_unique(size_t n)
-{
- typedef typename std::remove_extent<T>::type U;
- return std::unique_ptr<T>(new U[n]());
-}
-
-template <class T, class... Args>
-typename _Unique_if<T>::_Known_bound
-make_unique(Args &&...) = delete;
-}
-
template <typename T>
struct enable_bitwise_ops
{
diff --git a/arm_compute/runtime/Array.h b/arm_compute/runtime/Array.h
index c8a240e428..61e0953edd 100644
--- a/arm_compute/runtime/Array.h
+++ b/arm_compute/runtime/Array.h
@@ -24,9 +24,9 @@
#ifndef __ARM_COMPUTE_ARRAY_H__
#define __ARM_COMPUTE_ARRAY_H__
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/IArray.h"
#include "arm_compute/core/Types.h"
+#include "support/ToolchainSupport.h"
#include <memory>
@@ -47,7 +47,7 @@ public:
* @param[in] max_num_values Maximum number of values the array will be able to stored
*/
Array(size_t max_num_values)
- : IArray<T>(max_num_values), _values(arm_compute::cpp14::make_unique<T[]>(max_num_values))
+ : IArray<T>(max_num_values), _values(arm_compute::support::cpp14::make_unique<T[]>(max_num_values))
{
}
diff --git a/src/runtime/CL/CLMultiHOG.cpp b/src/runtime/CL/CLMultiHOG.cpp
index b9e8739454..88d45acd12 100644
--- a/src/runtime/CL/CLMultiHOG.cpp
+++ b/src/runtime/CL/CLMultiHOG.cpp
@@ -25,12 +25,12 @@
#include "arm_compute/core/CL/ICLHOG.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
CLMultiHOG::CLMultiHOG(size_t num_models)
- : _num_models(num_models), _model(arm_compute::cpp14::make_unique<CLHOG[]>(_num_models))
+ : _num_models(num_models), _model(arm_compute::support::cpp14::make_unique<CLHOG[]>(_num_models))
{
}
diff --git a/src/runtime/CL/CLPyramid.cpp b/src/runtime/CL/CLPyramid.cpp
index 41d81ea0f8..865f389f7f 100644
--- a/src/runtime/CL/CLPyramid.cpp
+++ b/src/runtime/CL/CLPyramid.cpp
@@ -24,10 +24,10 @@
#include "arm_compute/runtime/CL/CLPyramid.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PyramidInfo.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/TensorShape.h"
+#include "support/ToolchainSupport.h"
#include <array>
#include <cmath>
@@ -52,7 +52,7 @@ void CLPyramid::init_auto_padding(const PyramidInfo &info)
void CLPyramid::internal_init(const PyramidInfo &info, bool auto_padding)
{
_info = info;
- _pyramid = arm_compute::cpp14::make_unique<CLTensor[]>(_info.num_levels());
+ _pyramid = arm_compute::support::cpp14::make_unique<CLTensor[]>(_info.num_levels());
size_t w = _info.width();
size_t h = _info.height();
diff --git a/src/runtime/CL/functions/CLAbsoluteDifference.cpp b/src/runtime/CL/functions/CLAbsoluteDifference.cpp
index 5097dd4710..5613e6c78d 100644
--- a/src/runtime/CL/functions/CLAbsoluteDifference.cpp
+++ b/src/runtime/CL/functions/CLAbsoluteDifference.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLAbsoluteDifference.h"
#include "arm_compute/core/CL/kernels/CLAbsoluteDifferenceKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLAbsoluteDifference::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLAbsoluteDifferenceKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLAbsoluteDifferenceKernel>();
k->configure(input1, input2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLAccumulate.cpp b/src/runtime/CL/functions/CLAccumulate.cpp
index 56c519984c..78f25fc015 100644
--- a/src/runtime/CL/functions/CLAccumulate.cpp
+++ b/src/runtime/CL/functions/CLAccumulate.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLAccumulate.h"
#include "arm_compute/core/CL/kernels/CLAccumulateKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,21 +32,21 @@ using namespace arm_compute;
void CLAccumulate::configure(const ICLTensor *input, ICLTensor *accum)
{
- auto k = arm_compute::cpp14::make_unique<CLAccumulateKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLAccumulateKernel>();
k->configure(input, accum);
_kernel = std::move(k);
}
void CLAccumulateWeighted::configure(const ICLTensor *input, float alpha, ICLTensor *accum)
{
- auto k = arm_compute::cpp14::make_unique<CLAccumulateWeightedKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLAccumulateWeightedKernel>();
k->configure(input, alpha, accum);
_kernel = std::move(k);
}
void CLAccumulateSquared::configure(const ICLTensor *input, uint32_t shift, ICLTensor *accum)
{
- auto k = arm_compute::cpp14::make_unique<CLAccumulateSquaredKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLAccumulateSquaredKernel>();
k->configure(input, shift, accum);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLActivationLayer.cpp b/src/runtime/CL/functions/CLActivationLayer.cpp
index 0d0da0ca9a..b64739a008 100644
--- a/src/runtime/CL/functions/CLActivationLayer.cpp
+++ b/src/runtime/CL/functions/CLActivationLayer.cpp
@@ -24,13 +24,13 @@
#include "arm_compute/runtime/CL/functions/CLActivationLayer.h"
#include "arm_compute/core/CL/kernels/CLActivationLayerKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void CLActivationLayer::configure(ICLTensor *input, ICLTensor *output, ActivationLayerInfo act_info)
{
- auto k = arm_compute::cpp14::make_unique<CLActivationLayerKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLActivationLayerKernel>();
k->configure(input, output, act_info);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLArithmeticAddition.cpp b/src/runtime/CL/functions/CLArithmeticAddition.cpp
index 36bff4285c..5ca384d6a4 100644
--- a/src/runtime/CL/functions/CLArithmeticAddition.cpp
+++ b/src/runtime/CL/functions/CLArithmeticAddition.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLArithmeticAddition.h"
#include "arm_compute/core/CL/kernels/CLArithmeticAdditionKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLArithmeticAddition::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output, ConvertPolicy policy)
{
- auto k = arm_compute::cpp14::make_unique<CLArithmeticAdditionKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLArithmeticAdditionKernel>();
k->configure(input1, input2, output, policy);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLArithmeticSubtraction.cpp b/src/runtime/CL/functions/CLArithmeticSubtraction.cpp
index 97f0a1caf4..651f51a24a 100644
--- a/src/runtime/CL/functions/CLArithmeticSubtraction.cpp
+++ b/src/runtime/CL/functions/CLArithmeticSubtraction.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLArithmeticSubtraction.h"
#include "arm_compute/core/CL/kernels/CLArithmeticSubtractionKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLArithmeticSubtraction::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output, ConvertPolicy policy)
{
- auto k = arm_compute::cpp14::make_unique<CLArithmeticSubtractionKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLArithmeticSubtractionKernel>();
k->configure(input1, input2, output, policy);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLBitwiseAnd.cpp b/src/runtime/CL/functions/CLBitwiseAnd.cpp
index 7c85043206..f8a5a859bd 100644
--- a/src/runtime/CL/functions/CLBitwiseAnd.cpp
+++ b/src/runtime/CL/functions/CLBitwiseAnd.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLBitwiseAnd.h"
#include "arm_compute/core/CL/kernels/CLBitwiseAndKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLBitwiseAnd::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLBitwiseAndKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLBitwiseAndKernel>();
k->configure(input1, input2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLBitwiseNot.cpp b/src/runtime/CL/functions/CLBitwiseNot.cpp
index 17ae5dea3c..dc002e5cac 100644
--- a/src/runtime/CL/functions/CLBitwiseNot.cpp
+++ b/src/runtime/CL/functions/CLBitwiseNot.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLBitwiseNot.h"
#include "arm_compute/core/CL/kernels/CLBitwiseNotKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLBitwiseNot::configure(const ICLTensor *input, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLBitwiseNotKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLBitwiseNotKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLBitwiseOr.cpp b/src/runtime/CL/functions/CLBitwiseOr.cpp
index c84a279bae..4a10bb2f36 100644
--- a/src/runtime/CL/functions/CLBitwiseOr.cpp
+++ b/src/runtime/CL/functions/CLBitwiseOr.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLBitwiseOr.h"
#include "arm_compute/core/CL/kernels/CLBitwiseOrKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLBitwiseOr::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLBitwiseOrKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLBitwiseOrKernel>();
k->configure(input1, input2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLBitwiseXor.cpp b/src/runtime/CL/functions/CLBitwiseXor.cpp
index fd49c7d818..d23622ab01 100644
--- a/src/runtime/CL/functions/CLBitwiseXor.cpp
+++ b/src/runtime/CL/functions/CLBitwiseXor.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLBitwiseXor.h"
#include "arm_compute/core/CL/kernels/CLBitwiseXorKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLBitwiseXor::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLBitwiseXorKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLBitwiseXorKernel>();
k->configure(input1, input2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLBox3x3.cpp b/src/runtime/CL/functions/CLBox3x3.cpp
index 20d5dae94e..f28be44d72 100644
--- a/src/runtime/CL/functions/CLBox3x3.cpp
+++ b/src/runtime/CL/functions/CLBox3x3.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLBox3x3.h"
#include "arm_compute/core/CL/kernels/CLBox3x3Kernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLBox3x3::configure(ICLTensor *input, ICLTensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLBox3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLBox3x3Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, BorderSize(1), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLCannyEdge.cpp b/src/runtime/CL/functions/CLCannyEdge.cpp
index 1d018b8347..6c321ad69a 100644
--- a/src/runtime/CL/functions/CLCannyEdge.cpp
+++ b/src/runtime/CL/functions/CLCannyEdge.cpp
@@ -26,12 +26,12 @@
#include "arm_compute/core/CL/ICLTensor.h"
#include "arm_compute/core/CL/OpenCL.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/Validate.h"
#include "arm_compute/runtime/CL/CLScheduler.h"
#include "arm_compute/runtime/CL/functions/CLSobel3x3.h"
#include "arm_compute/runtime/CL/functions/CLSobel5x5.h"
#include "arm_compute/runtime/CL/functions/CLSobel7x7.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -86,19 +86,19 @@ void CLCannyEdge::configure(ICLTensor *input, ICLTensor *output, int32_t upper_t
// Configure/Init sobelNxN
if(gradient_size == 3)
{
- auto k = arm_compute::cpp14::make_unique<CLSobel3x3>();
+ auto k = arm_compute::support::cpp14::make_unique<CLSobel3x3>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
}
else if(gradient_size == 5)
{
- auto k = arm_compute::cpp14::make_unique<CLSobel5x5>();
+ auto k = arm_compute::support::cpp14::make_unique<CLSobel5x5>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
}
else if(gradient_size == 7)
{
- auto k = arm_compute::cpp14::make_unique<CLSobel7x7>();
+ auto k = arm_compute::support::cpp14::make_unique<CLSobel7x7>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLChannelCombine.cpp b/src/runtime/CL/functions/CLChannelCombine.cpp
index 79a3676bd7..11605cf95e 100644
--- a/src/runtime/CL/functions/CLChannelCombine.cpp
+++ b/src/runtime/CL/functions/CLChannelCombine.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLChannelCombine.h"
#include "arm_compute/core/CL/kernels/CLChannelCombineKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,14 +32,14 @@ using namespace arm_compute;
void CLChannelCombine::configure(const ICLTensor *plane0, const ICLTensor *plane1, const ICLTensor *plane2, const ICLTensor *plane3, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLChannelCombineKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLChannelCombineKernel>();
k->configure(plane0, plane1, plane2, plane3, output);
_kernel = std::move(k);
}
void CLChannelCombine::configure(const ICLImage *plane0, const ICLImage *plane1, const ICLImage *plane2, ICLMultiImage *output)
{
- auto k = arm_compute::cpp14::make_unique<CLChannelCombineKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLChannelCombineKernel>();
k->configure(plane0, plane1, plane2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLChannelExtract.cpp b/src/runtime/CL/functions/CLChannelExtract.cpp
index 2c6174b9ee..50903826d3 100644
--- a/src/runtime/CL/functions/CLChannelExtract.cpp
+++ b/src/runtime/CL/functions/CLChannelExtract.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLChannelExtract.h"
#include "arm_compute/core/CL/kernels/CLChannelExtractKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,14 +32,14 @@ using namespace arm_compute;
void CLChannelExtract::configure(const ICLTensor *input, Channel channel, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLChannelExtractKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLChannelExtractKernel>();
k->configure(input, channel, output);
_kernel = std::move(k);
}
void CLChannelExtract::configure(const ICLMultiImage *input, Channel channel, ICLImage *output)
{
- auto k = arm_compute::cpp14::make_unique<CLChannelExtractKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLChannelExtractKernel>();
k->configure(input, channel, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLColorConvert.cpp b/src/runtime/CL/functions/CLColorConvert.cpp
index 2fe465aeb8..65f8ac3740 100644
--- a/src/runtime/CL/functions/CLColorConvert.cpp
+++ b/src/runtime/CL/functions/CLColorConvert.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLColorConvert.h"
#include "arm_compute/core/CL/kernels/CLColorConvertKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,28 +32,28 @@ using namespace arm_compute;
void CLColorConvert::configure(const ICLTensor *input, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLColorConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLColorConvertKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
void CLColorConvert::configure(const ICLImage *input, ICLMultiImage *output)
{
- auto k = arm_compute::cpp14::make_unique<CLColorConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLColorConvertKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
void CLColorConvert::configure(const ICLMultiImage *input, ICLImage *output)
{
- auto k = arm_compute::cpp14::make_unique<CLColorConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLColorConvertKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
void CLColorConvert::configure(const ICLMultiImage *input, ICLMultiImage *output)
{
- auto k = arm_compute::cpp14::make_unique<CLColorConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLColorConvertKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLConvolution.cpp b/src/runtime/CL/functions/CLConvolution.cpp
index 21b5d47679..641044451d 100644
--- a/src/runtime/CL/functions/CLConvolution.cpp
+++ b/src/runtime/CL/functions/CLConvolution.cpp
@@ -26,13 +26,13 @@
#include "arm_compute/core/CL/ICLTensor.h"
#include "arm_compute/core/CL/kernels/CLConvolutionKernel.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Utils.h"
#include "arm_compute/core/Validate.h"
#include "arm_compute/runtime/CL/CLScheduler.h"
#include "arm_compute/runtime/ITensorAllocator.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -40,7 +40,7 @@ using namespace arm_compute;
void CLConvolution3x3::configure(ICLTensor *input, ICLTensor *output, const int16_t *conv, uint32_t scale, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLConvolution3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLConvolution3x3Kernel>();
k->configure(input, output, conv, scale, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
@@ -107,7 +107,7 @@ template class arm_compute::CLConvolutionSquare<9>;
void CLConvolutionRectangle::configure(ICLTensor *input, ICLTensor *output, const int16_t *conv, uint32_t rows, uint32_t cols, uint32_t scale, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLConvolutionRectangleKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLConvolutionRectangleKernel>();
k->configure(input, output, conv, rows, cols, scale, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLDepthConcatenate.cpp b/src/runtime/CL/functions/CLDepthConcatenate.cpp
index d967d9865f..34778c6980 100644
--- a/src/runtime/CL/functions/CLDepthConcatenate.cpp
+++ b/src/runtime/CL/functions/CLDepthConcatenate.cpp
@@ -27,10 +27,10 @@
#include "arm_compute/core/CL/kernels/CLDepthConcatenateKernel.h"
#include "arm_compute/core/CL/kernels/CLFillBorderKernel.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
#include "arm_compute/core/Types.h"
#include "arm_compute/runtime/CL/CLScheduler.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -47,8 +47,8 @@ void CLDepthConcatenate::configure(std::vector<ICLTensor *> inputs_vector, ICLTe
unsigned int depth_offset = 0;
- _concat_kernels_vector = arm_compute::cpp14::make_unique<CLDepthConcatenateKernel[]>(_num_inputs);
- _border_handlers_vector = arm_compute::cpp14::make_unique<CLFillBorderKernel[]>(_num_inputs);
+ _concat_kernels_vector = arm_compute::support::cpp14::make_unique<CLDepthConcatenateKernel[]>(_num_inputs);
+ _border_handlers_vector = arm_compute::support::cpp14::make_unique<CLFillBorderKernel[]>(_num_inputs);
for(unsigned int i = 0; i < _num_inputs; i++)
{
diff --git a/src/runtime/CL/functions/CLDepthConvert.cpp b/src/runtime/CL/functions/CLDepthConvert.cpp
index edcd4928ab..b64d05b8b1 100644
--- a/src/runtime/CL/functions/CLDepthConvert.cpp
+++ b/src/runtime/CL/functions/CLDepthConvert.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLDepthConvert.h"
#include "arm_compute/core/CL/kernels/CLDepthConvertKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLDepthConvert::configure(const ICLTensor *input, ICLTensor *output, ConvertPolicy policy, uint32_t shift)
{
- auto k = arm_compute::cpp14::make_unique<CLDepthConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLDepthConvertKernel>();
k->configure(input, output, policy, shift);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLDerivative.cpp b/src/runtime/CL/functions/CLDerivative.cpp
index 9357de52f1..ae49996f3e 100644
--- a/src/runtime/CL/functions/CLDerivative.cpp
+++ b/src/runtime/CL/functions/CLDerivative.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLDerivative.h"
#include "arm_compute/core/CL/kernels/CLDerivativeKernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLDerivative::configure(ICLTensor *input, ICLTensor *output_x, ICLTensor *output_y, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLDerivativeKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLDerivativeKernel>();
k->configure(input, output_x, output_y, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, BorderSize(1), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLDilate.cpp b/src/runtime/CL/functions/CLDilate.cpp
index 0a4abe30c2..59c5ea5439 100644
--- a/src/runtime/CL/functions/CLDilate.cpp
+++ b/src/runtime/CL/functions/CLDilate.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLDilate.h"
#include "arm_compute/core/CL/kernels/CLDilateKernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLDilate::configure(ICLTensor *input, ICLTensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLDilateKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLDilateKernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, BorderSize(1), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLErode.cpp b/src/runtime/CL/functions/CLErode.cpp
index c41371cf9e..eb1f6e4bd8 100644
--- a/src/runtime/CL/functions/CLErode.cpp
+++ b/src/runtime/CL/functions/CLErode.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLErode.h"
#include "arm_compute/core/CL/kernels/CLErodeKernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLErode::configure(ICLTensor *input, ICLTensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLErodeKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLErodeKernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, BorderSize(1), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLFillBorder.cpp b/src/runtime/CL/functions/CLFillBorder.cpp
index 172f09da1a..54c096e25d 100644
--- a/src/runtime/CL/functions/CLFillBorder.cpp
+++ b/src/runtime/CL/functions/CLFillBorder.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLFillBorder.h"
#include "arm_compute/core/CL/kernels/CLFillBorderKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLFillBorder::configure(ICLTensor *tensor, unsigned int border_width, BorderMode border_mode, const PixelValue &constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLFillBorderKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLFillBorderKernel>();
k->configure(tensor, BorderSize(border_width), border_mode, constant_border_value);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLGEMMInterleave4x4.cpp b/src/runtime/CL/functions/CLGEMMInterleave4x4.cpp
index 9dc77156ef..45547e4cb6 100644
--- a/src/runtime/CL/functions/CLGEMMInterleave4x4.cpp
+++ b/src/runtime/CL/functions/CLGEMMInterleave4x4.cpp
@@ -24,13 +24,13 @@
#include "arm_compute/runtime/CL/functions/CLGEMMInterleave4x4.h"
#include "arm_compute/core/CL/kernels/CLGEMMInterleave4x4Kernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void CLGEMMInterleave4x4::configure(const ICLTensor *input, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLGEMMInterleave4x4Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLGEMMInterleave4x4Kernel>();
k->configure(input, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLGEMMTranspose1xW.cpp b/src/runtime/CL/functions/CLGEMMTranspose1xW.cpp
index 8f8a19e709..d054e01611 100644
--- a/src/runtime/CL/functions/CLGEMMTranspose1xW.cpp
+++ b/src/runtime/CL/functions/CLGEMMTranspose1xW.cpp
@@ -25,14 +25,14 @@
#include "arm_compute/core/CL/ICLTensor.h"
#include "arm_compute/core/CL/kernels/CLGEMMTranspose1xWKernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/Types.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void CLGEMMTranspose1xW::configure(const ICLTensor *input, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLGEMMTranspose1xWKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLGEMMTranspose1xWKernel>();
k->configure(input, output);
_kernel = std::move(k);
} \ No newline at end of file
diff --git a/src/runtime/CL/functions/CLGaussian3x3.cpp b/src/runtime/CL/functions/CLGaussian3x3.cpp
index 362a3fe920..7ebabd756d 100644
--- a/src/runtime/CL/functions/CLGaussian3x3.cpp
+++ b/src/runtime/CL/functions/CLGaussian3x3.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLGaussian3x3.h"
#include "arm_compute/core/CL/kernels/CLGaussian3x3Kernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLGaussian3x3::configure(ICLTensor *input, ICLTensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLGaussian3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLGaussian3x3Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLGaussianPyramid.cpp b/src/runtime/CL/functions/CLGaussianPyramid.cpp
index 8a4279e99b..8450d5ee69 100644
--- a/src/runtime/CL/functions/CLGaussianPyramid.cpp
+++ b/src/runtime/CL/functions/CLGaussianPyramid.cpp
@@ -27,11 +27,11 @@
#include "arm_compute/core/CL/kernels/CLGaussianPyramidKernel.h"
#include "arm_compute/core/CL/kernels/CLScaleKernel.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
#include "arm_compute/core/Window.h"
+#include "support/ToolchainSupport.h"
#include "arm_compute/runtime/CL/CLPyramid.h"
#include "arm_compute/runtime/CL/CLScheduler.h"
@@ -70,9 +70,9 @@ void CLGaussianPyramidHalf::configure(ICLTensor *input, CLPyramid *pyramid, Bord
if(num_levels > 1)
{
- _border_handler = arm_compute::cpp14::make_unique<CLFillBorderKernel[]>(num_levels - 1);
- _horizontal_reduction = arm_compute::cpp14::make_unique<CLGaussianPyramidHorKernel[]>(num_levels - 1);
- _vertical_reduction = arm_compute::cpp14::make_unique<CLGaussianPyramidVertKernel[]>(num_levels - 1);
+ _border_handler = arm_compute::support::cpp14::make_unique<CLFillBorderKernel[]>(num_levels - 1);
+ _horizontal_reduction = arm_compute::support::cpp14::make_unique<CLGaussianPyramidHorKernel[]>(num_levels - 1);
+ _vertical_reduction = arm_compute::support::cpp14::make_unique<CLGaussianPyramidVertKernel[]>(num_levels - 1);
// Apply half scale to the X dimension of the tensor shape
TensorShape tensor_shape = pyramid->info()->tensor_shape();
@@ -141,8 +141,8 @@ void CLGaussianPyramidOrb::configure(ICLTensor *input, CLPyramid *pyramid, Borde
if(num_levels > 1)
{
- _gauss5x5 = arm_compute::cpp14::make_unique<CLGaussian5x5[]>(num_levels - 1);
- _scale_nearest = arm_compute::cpp14::make_unique<CLScaleKernel[]>(num_levels - 1);
+ _gauss5x5 = arm_compute::support::cpp14::make_unique<CLGaussian5x5[]>(num_levels - 1);
+ _scale_nearest = arm_compute::support::cpp14::make_unique<CLScaleKernel[]>(num_levels - 1);
PyramidInfo pyramid_info(num_levels - 1, SCALE_PYRAMID_ORB, pyramid->info()->tensor_shape(), Format::U8);
diff --git a/src/runtime/CL/functions/CLHOGMultiDetection.cpp b/src/runtime/CL/functions/CLHOGMultiDetection.cpp
index b8f2224ac8..6e864464a4 100644
--- a/src/runtime/CL/functions/CLHOGMultiDetection.cpp
+++ b/src/runtime/CL/functions/CLHOGMultiDetection.cpp
@@ -25,11 +25,11 @@
#include "arm_compute/core/CL/OpenCL.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/runtime/CL/CLArray.h"
#include "arm_compute/runtime/CL/CLScheduler.h"
#include "arm_compute/runtime/CL/CLTensor.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -114,12 +114,12 @@ void CLHOGMultiDetection::configure(ICLTensor *input, const ICLMultiHOG *multi_h
_num_block_norm_kernel = input_block_norm.size(); // Number of CLHOGBlockNormalizationKernel kernels to compute
_num_hog_detect_kernel = input_hog_detect.size(); // Number of CLHOGDetector functions to compute
- _orient_bin_kernel = arm_compute::cpp14::make_unique<CLHOGOrientationBinningKernel[]>(_num_orient_bin_kernel);
- _block_norm_kernel = arm_compute::cpp14::make_unique<CLHOGBlockNormalizationKernel[]>(_num_block_norm_kernel);
- _hog_detect_kernel = arm_compute::cpp14::make_unique<CLHOGDetector[]>(_num_hog_detect_kernel);
- _non_maxima_kernel = arm_compute::cpp14::make_unique<CPPDetectionWindowNonMaximaSuppressionKernel>();
- _hog_space = arm_compute::cpp14::make_unique<CLTensor[]>(_num_orient_bin_kernel);
- _hog_norm_space = arm_compute::cpp14::make_unique<CLTensor[]>(_num_block_norm_kernel);
+ _orient_bin_kernel = arm_compute::support::cpp14::make_unique<CLHOGOrientationBinningKernel[]>(_num_orient_bin_kernel);
+ _block_norm_kernel = arm_compute::support::cpp14::make_unique<CLHOGBlockNormalizationKernel[]>(_num_block_norm_kernel);
+ _hog_detect_kernel = arm_compute::support::cpp14::make_unique<CLHOGDetector[]>(_num_hog_detect_kernel);
+ _non_maxima_kernel = arm_compute::support::cpp14::make_unique<CPPDetectionWindowNonMaximaSuppressionKernel>();
+ _hog_space = arm_compute::support::cpp14::make_unique<CLTensor[]>(_num_orient_bin_kernel);
+ _hog_norm_space = arm_compute::support::cpp14::make_unique<CLTensor[]>(_num_block_norm_kernel);
// Allocate tensors for magnitude and phase
TensorInfo info_mag(shape_img, Format::S16);
diff --git a/src/runtime/CL/functions/CLHarrisCorners.cpp b/src/runtime/CL/functions/CLHarrisCorners.cpp
index e1c44416ae..87d573a7ad 100644
--- a/src/runtime/CL/functions/CLHarrisCorners.cpp
+++ b/src/runtime/CL/functions/CLHarrisCorners.cpp
@@ -27,7 +27,6 @@
#include "arm_compute/core/CL/kernels/CLFillBorderKernel.h"
#include "arm_compute/core/CL/kernels/CLHarrisCornersKernel.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
#include "arm_compute/runtime/CL/CLScheduler.h"
@@ -36,6 +35,7 @@
#include "arm_compute/runtime/CL/functions/CLSobel7x7.h"
#include "arm_compute/runtime/ITensorAllocator.h"
#include "arm_compute/runtime/Scheduler.h"
+#include "support/ToolchainSupport.h"
#include <cmath>
#include <utility>
@@ -69,28 +69,28 @@ void CLHarrisCorners::configure(ICLImage *input, float threshold, float min_dist
_score.allocator()->init(info_f32);
_nonmax.allocator()->init(info_f32);
- _corners_list = arm_compute::cpp14::make_unique<InternalKeypoint[]>(shape.x() * shape.y());
+ _corners_list = arm_compute::support::cpp14::make_unique<InternalKeypoint[]>(shape.x() * shape.y());
/* Set/init Sobel kernel accordingly with gradient_size */
switch(gradient_size)
{
case 3:
{
- auto k = arm_compute::cpp14::make_unique<CLSobel3x3>();
+ auto k = arm_compute::support::cpp14::make_unique<CLSobel3x3>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
break;
}
case 5:
{
- auto k = arm_compute::cpp14::make_unique<CLSobel5x5>();
+ auto k = arm_compute::support::cpp14::make_unique<CLSobel5x5>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
break;
}
case 7:
{
- auto k = arm_compute::cpp14::make_unique<CLSobel7x7>();
+ auto k = arm_compute::support::cpp14::make_unique<CLSobel7x7>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
break;
diff --git a/src/runtime/CL/functions/CLLaplacianPyramid.cpp b/src/runtime/CL/functions/CLLaplacianPyramid.cpp
index d7ce20653d..3fc93426ee 100644
--- a/src/runtime/CL/functions/CLLaplacianPyramid.cpp
+++ b/src/runtime/CL/functions/CLLaplacianPyramid.cpp
@@ -24,7 +24,6 @@
#include "arm_compute/runtime/CL/functions/CLLaplacianPyramid.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/IPyramid.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
@@ -33,6 +32,7 @@
#include "arm_compute/runtime/CL/functions/CLDepthConvert.h"
#include "arm_compute/runtime/CL/functions/CLGaussian5x5.h"
#include "arm_compute/runtime/CL/functions/CLGaussianPyramid.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -64,8 +64,8 @@ void CLLaplacianPyramid::configure(ICLTensor *input, CLPyramid *pyramid, ICLTens
// Create Gaussian Pyramid function
_gaussian_pyr_function.configure(input, &_gauss_pyr, border_mode, constant_border_value);
- _convf = arm_compute::cpp14::make_unique<CLGaussian5x5[]>(_num_levels);
- _subf = arm_compute::cpp14::make_unique<CLArithmeticSubtraction[]>(_num_levels);
+ _convf = arm_compute::support::cpp14::make_unique<CLGaussian5x5[]>(_num_levels);
+ _subf = arm_compute::support::cpp14::make_unique<CLArithmeticSubtraction[]>(_num_levels);
for(unsigned int i = 0; i < _num_levels; ++i)
{
diff --git a/src/runtime/CL/functions/CLLaplacianReconstruct.cpp b/src/runtime/CL/functions/CLLaplacianReconstruct.cpp
index 1dfab740d7..7fd2273230 100644
--- a/src/runtime/CL/functions/CLLaplacianReconstruct.cpp
+++ b/src/runtime/CL/functions/CLLaplacianReconstruct.cpp
@@ -24,11 +24,11 @@
#include "arm_compute/runtime/CL/functions/CLLaplacianReconstruct.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/IPyramid.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
+#include "support/ToolchainSupport.h"
#include <cstddef>
@@ -60,8 +60,8 @@ void CLLaplacianReconstruct::configure(const CLPyramid *pyramid, const ICLTensor
_tmp_pyr.init(pyramid_info);
// Allocate add and scale functions. Level 0 does not need to be scaled.
- _addf = arm_compute::cpp14::make_unique<CLArithmeticAddition[]>(num_levels);
- _scalef = arm_compute::cpp14::make_unique<CLScale[]>(num_levels - 1);
+ _addf = arm_compute::support::cpp14::make_unique<CLArithmeticAddition[]>(num_levels);
+ _scalef = arm_compute::support::cpp14::make_unique<CLScale[]>(num_levels - 1);
const size_t last_level = num_levels - 1;
diff --git a/src/runtime/CL/functions/CLMagnitude.cpp b/src/runtime/CL/functions/CLMagnitude.cpp
index 51088cb71f..68b8c3545a 100644
--- a/src/runtime/CL/functions/CLMagnitude.cpp
+++ b/src/runtime/CL/functions/CLMagnitude.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLMagnitude.h"
#include "arm_compute/core/CL/kernels/CLMagnitudePhaseKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLMagnitude::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output, MagnitudeType mag_type)
{
- auto k = arm_compute::cpp14::make_unique<CLMagnitudePhaseKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLMagnitudePhaseKernel>();
k->configure(input1, input2, output, nullptr, mag_type);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLMedian3x3.cpp b/src/runtime/CL/functions/CLMedian3x3.cpp
index 0c10f9aa08..55f9eaa907 100644
--- a/src/runtime/CL/functions/CLMedian3x3.cpp
+++ b/src/runtime/CL/functions/CLMedian3x3.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLMedian3x3.h"
#include "arm_compute/core/CL/kernels/CLMedian3x3Kernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLMedian3x3::configure(ICLTensor *input, ICLTensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLMedian3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLMedian3x3Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLNonLinearFilter.cpp b/src/runtime/CL/functions/CLNonLinearFilter.cpp
index b593a6cced..d37412f47f 100644
--- a/src/runtime/CL/functions/CLNonLinearFilter.cpp
+++ b/src/runtime/CL/functions/CLNonLinearFilter.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLNonLinearFilter.h"
#include "arm_compute/core/CL/kernels/CLNonLinearFilterKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLNonLinearFilter::configure(ICLTensor *input, ICLTensor *output, NonLinearFilterFunction function, unsigned int mask_size, MatrixPattern pattern, const uint8_t *mask,
BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLNonLinearFilterKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLNonLinearFilterKernel>();
k->configure(input, output, function, mask_size, pattern, mask, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLNonMaximaSuppression3x3.cpp b/src/runtime/CL/functions/CLNonMaximaSuppression3x3.cpp
index ca7d5aede7..c0a0cef885 100644
--- a/src/runtime/CL/functions/CLNonMaximaSuppression3x3.cpp
+++ b/src/runtime/CL/functions/CLNonMaximaSuppression3x3.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLNonMaximaSuppression3x3.h"
#include "arm_compute/core/CL/kernels/CLNonMaximaSuppression3x3Kernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLNonMaximaSuppression3x3::configure(ICLTensor *input, ICLTensor *output, BorderMode border_mode)
{
- auto k = arm_compute::cpp14::make_unique<CLNonMaximaSuppression3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLNonMaximaSuppression3x3Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
diff --git a/src/runtime/CL/functions/CLOpticalFlow.cpp b/src/runtime/CL/functions/CLOpticalFlow.cpp
index a6b0eb3bec..542f5961fa 100644
--- a/src/runtime/CL/functions/CLOpticalFlow.cpp
+++ b/src/runtime/CL/functions/CLOpticalFlow.cpp
@@ -26,7 +26,6 @@
#include "arm_compute/core/CL/ICLTensor.h"
#include "arm_compute/core/CL/kernels/CLLKTrackerKernel.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Window.h"
#include "arm_compute/runtime/CL/CLPyramid.h"
@@ -34,6 +33,7 @@
#include "arm_compute/runtime/CL/CLTensor.h"
#include "arm_compute/runtime/CL/CLTensorAllocator.h"
#include "arm_compute/runtime/CL/functions/CLScharr3x3.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -70,21 +70,21 @@ void CLOpticalFlow::configure(const CLPyramid *old_pyramid, const CLPyramid *new
const int old_values_list_length = list_length * window_dimension * window_dimension;
// Create kernels and tensors
- _tracker_init_kernel = arm_compute::cpp14::make_unique<CLLKTrackerInitKernel[]>(_num_levels);
- _tracker_stage0_kernel = arm_compute::cpp14::make_unique<CLLKTrackerStage0Kernel[]>(_num_levels);
- _tracker_stage1_kernel = arm_compute::cpp14::make_unique<CLLKTrackerStage1Kernel[]>(_num_levels);
- _func_scharr = arm_compute::cpp14::make_unique<CLScharr3x3[]>(_num_levels);
- _scharr_gx = arm_compute::cpp14::make_unique<CLTensor[]>(_num_levels);
- _scharr_gy = arm_compute::cpp14::make_unique<CLTensor[]>(_num_levels);
+ _tracker_init_kernel = arm_compute::support::cpp14::make_unique<CLLKTrackerInitKernel[]>(_num_levels);
+ _tracker_stage0_kernel = arm_compute::support::cpp14::make_unique<CLLKTrackerStage0Kernel[]>(_num_levels);
+ _tracker_stage1_kernel = arm_compute::support::cpp14::make_unique<CLLKTrackerStage1Kernel[]>(_num_levels);
+ _func_scharr = arm_compute::support::cpp14::make_unique<CLScharr3x3[]>(_num_levels);
+ _scharr_gx = arm_compute::support::cpp14::make_unique<CLTensor[]>(_num_levels);
+ _scharr_gy = arm_compute::support::cpp14::make_unique<CLTensor[]>(_num_levels);
// Create internal keypoint arrays
- _old_points_internal = arm_compute::cpp14::make_unique<CLLKInternalKeypointArray>(list_length);
+ _old_points_internal = arm_compute::support::cpp14::make_unique<CLLKInternalKeypointArray>(list_length);
_old_points_internal->resize(list_length);
- _new_points_internal = arm_compute::cpp14::make_unique<CLLKInternalKeypointArray>(list_length);
+ _new_points_internal = arm_compute::support::cpp14::make_unique<CLLKInternalKeypointArray>(list_length);
_new_points_internal->resize(list_length);
- _coefficient_table = arm_compute::cpp14::make_unique<CLCoefficientTableArray>(list_length);
+ _coefficient_table = arm_compute::support::cpp14::make_unique<CLCoefficientTableArray>(list_length);
_coefficient_table->resize(list_length);
- _old_values = arm_compute::cpp14::make_unique<CLOldValueArray>(old_values_list_length);
+ _old_values = arm_compute::support::cpp14::make_unique<CLOldValueArray>(old_values_list_length);
_old_values->resize(old_values_list_length);
_new_points->resize(list_length);
diff --git a/src/runtime/CL/functions/CLPhase.cpp b/src/runtime/CL/functions/CLPhase.cpp
index a8cb22b06e..cf3fa7e7fb 100644
--- a/src/runtime/CL/functions/CLPhase.cpp
+++ b/src/runtime/CL/functions/CLPhase.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLPhase.h"
#include "arm_compute/core/CL/kernels/CLMagnitudePhaseKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLPhase::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output, PhaseType phase_type)
{
- auto k = arm_compute::cpp14::make_unique<CLMagnitudePhaseKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLMagnitudePhaseKernel>();
k->configure(input1, input2, nullptr, output, MagnitudeType::L1NORM, phase_type);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLPixelWiseMultiplication.cpp b/src/runtime/CL/functions/CLPixelWiseMultiplication.cpp
index 8a86c2e203..139d466b39 100644
--- a/src/runtime/CL/functions/CLPixelWiseMultiplication.cpp
+++ b/src/runtime/CL/functions/CLPixelWiseMultiplication.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLPixelWiseMultiplication.h"
#include "arm_compute/core/CL/kernels/CLPixelWiseMultiplicationKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLPixelWiseMultiplication::configure(const ICLTensor *input1, const ICLTensor *input2, ICLTensor *output, float scale,
ConvertPolicy overflow_policy, RoundingPolicy rounding_policy)
{
- auto k = arm_compute::cpp14::make_unique<CLPixelWiseMultiplicationKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLPixelWiseMultiplicationKernel>();
k->configure(input1, input2, output, scale, overflow_policy, rounding_policy);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLPoolingLayer.cpp b/src/runtime/CL/functions/CLPoolingLayer.cpp
index 1ef70f4a2b..2cb7d63aa8 100644
--- a/src/runtime/CL/functions/CLPoolingLayer.cpp
+++ b/src/runtime/CL/functions/CLPoolingLayer.cpp
@@ -24,14 +24,14 @@
#include "arm_compute/runtime/CL/functions/CLPoolingLayer.h"
#include "arm_compute/core/CL/kernels/CLPoolingLayerKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void CLPoolingLayer::configure(ICLTensor *input, ICLTensor *output, const PoolingLayerInfo &pool_info)
{
// Configure pooling kernel
- auto k = arm_compute::cpp14::make_unique<CLPoolingLayerKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLPoolingLayerKernel>();
k->configure(input, output, pool_info);
_kernel = std::move(k);
diff --git a/src/runtime/CL/functions/CLRemap.cpp b/src/runtime/CL/functions/CLRemap.cpp
index f6b1713c58..bc3fd4ed53 100644
--- a/src/runtime/CL/functions/CLRemap.cpp
+++ b/src/runtime/CL/functions/CLRemap.cpp
@@ -26,10 +26,10 @@
#include "arm_compute/core/CL/ICLTensor.h"
#include "arm_compute/core/CL/kernels/CLRemapKernel.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -43,7 +43,7 @@ void CLRemap::configure(ICLTensor *input, const ICLTensor *map_x, const ICLTenso
ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN(map_y, 1, DataType::F32);
ARM_COMPUTE_ERROR_ON_MSG(policy == InterpolationPolicy::AREA, "Area interpolation is not supported");
- auto k = arm_compute::cpp14::make_unique<CLRemapKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLRemapKernel>();
k->configure(input, map_x, map_y, output, policy, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLScale.cpp b/src/runtime/CL/functions/CLScale.cpp
index 043f873028..05522b4af5 100644
--- a/src/runtime/CL/functions/CLScale.cpp
+++ b/src/runtime/CL/functions/CLScale.cpp
@@ -26,8 +26,8 @@
#include "arm_compute/core/CL/ICLTensor.h"
#include "arm_compute/core/CL/kernels/CLScaleKernel.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/Validate.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -38,7 +38,7 @@ void CLScale::configure(ICLTensor *input, ICLTensor *output, InterpolationPolicy
ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN(output, 1, DataType::U8, DataType::S16);
ARM_COMPUTE_ERROR_ON_MISMATCHING_DATA_TYPES(input, output);
- auto k = arm_compute::cpp14::make_unique<CLScaleKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLScaleKernel>();
k->configure(input, output, policy, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, constant_border_value);
diff --git a/src/runtime/CL/functions/CLScharr3x3.cpp b/src/runtime/CL/functions/CLScharr3x3.cpp
index c8bc465be6..73f8673e78 100644
--- a/src/runtime/CL/functions/CLScharr3x3.cpp
+++ b/src/runtime/CL/functions/CLScharr3x3.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLScharr3x3.h"
#include "arm_compute/core/CL/kernels/CLScharr3x3Kernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLScharr3x3::configure(ICLTensor *input, ICLTensor *output_x, ICLTensor *output_y, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLScharr3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLScharr3x3Kernel>();
k->configure(input, output_x, output_y, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLSobel3x3.cpp b/src/runtime/CL/functions/CLSobel3x3.cpp
index 6b74ebaedb..e227e58bb2 100644
--- a/src/runtime/CL/functions/CLSobel3x3.cpp
+++ b/src/runtime/CL/functions/CLSobel3x3.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLSobel3x3.h"
#include "arm_compute/core/CL/kernels/CLSobel3x3Kernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLSobel3x3::configure(ICLTensor *input, ICLTensor *output_x, ICLTensor *output_y, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLSobel3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLSobel3x3Kernel>();
k->configure(input, output_x, output_y, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLTableLookup.cpp b/src/runtime/CL/functions/CLTableLookup.cpp
index 743ed5e73e..d18765093f 100644
--- a/src/runtime/CL/functions/CLTableLookup.cpp
+++ b/src/runtime/CL/functions/CLTableLookup.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLTableLookup.h"
#include "arm_compute/core/CL/kernels/CLTableLookupKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLTableLookup::configure(const ICLTensor *input, const ICLLut *lut, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLTableLookupKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLTableLookupKernel>();
k->configure(input, lut, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLThreshold.cpp b/src/runtime/CL/functions/CLThreshold.cpp
index e70f932d66..1b30b77f1d 100644
--- a/src/runtime/CL/functions/CLThreshold.cpp
+++ b/src/runtime/CL/functions/CLThreshold.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLThreshold.h"
#include "arm_compute/core/CL/kernels/CLThresholdKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLThreshold::configure(const ICLTensor *input, ICLTensor *output, uint8_t threshold, uint8_t false_value, uint8_t true_value, ThresholdType type, uint8_t upper)
{
- auto k = arm_compute::cpp14::make_unique<CLThresholdKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLThresholdKernel>();
k->configure(input, output, threshold, false_value, true_value, type, upper);
_kernel = std::move(k);
}
diff --git a/src/runtime/CL/functions/CLTranspose.cpp b/src/runtime/CL/functions/CLTranspose.cpp
index d802b4fe77..cd19e255bd 100644
--- a/src/runtime/CL/functions/CLTranspose.cpp
+++ b/src/runtime/CL/functions/CLTranspose.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/CL/functions/CLTranspose.h"
#include "arm_compute/core/CL/kernels/CLTransposeKernel.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void CLTranspose::configure(const ICLTensor *input, ICLTensor *output)
{
- auto k = arm_compute::cpp14::make_unique<CLTransposeKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLTransposeKernel>();
k->configure(input, output);
_kernel = std::move(k);
} \ No newline at end of file
diff --git a/src/runtime/CL/functions/CLWarpAffine.cpp b/src/runtime/CL/functions/CLWarpAffine.cpp
index 537e0d9397..f785c75a72 100644
--- a/src/runtime/CL/functions/CLWarpAffine.cpp
+++ b/src/runtime/CL/functions/CLWarpAffine.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLWarpAffine.h"
#include "arm_compute/core/CL/kernels/CLWarpAffineKernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLWarpAffine::configure(ICLTensor *input, ICLTensor *output, const float *matrix, InterpolationPolicy policy, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLWarpAffineKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLWarpAffineKernel>();
k->configure(input, output, matrix, policy);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/CL/functions/CLWarpPerspective.cpp b/src/runtime/CL/functions/CLWarpPerspective.cpp
index a552ab480d..b445b3b9c5 100644
--- a/src/runtime/CL/functions/CLWarpPerspective.cpp
+++ b/src/runtime/CL/functions/CLWarpPerspective.cpp
@@ -24,8 +24,8 @@
#include "arm_compute/runtime/CL/functions/CLWarpPerspective.h"
#include "arm_compute/core/CL/kernels/CLWarpPerspectiveKernel.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void CLWarpPerspective::configure(ICLTensor *input, ICLTensor *output, const float *matrix, InterpolationPolicy policy, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<CLWarpPerspectiveKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<CLWarpPerspectiveKernel>();
k->configure(input, output, matrix, policy);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/Distribution1D.cpp b/src/runtime/Distribution1D.cpp
index b06767499b..3431834c48 100644
--- a/src/runtime/Distribution1D.cpp
+++ b/src/runtime/Distribution1D.cpp
@@ -24,14 +24,14 @@
#include "arm_compute/runtime/Distribution1D.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
#include <cstdint>
using namespace arm_compute;
Distribution1D::Distribution1D(size_t num_bins, int32_t offset, uint32_t range)
- : IDistribution1D(num_bins, offset, range), _data(arm_compute::cpp14::make_unique<uint32_t[]>(num_bins))
+ : IDistribution1D(num_bins, offset, range), _data(arm_compute::support::cpp14::make_unique<uint32_t[]>(num_bins))
{
}
diff --git a/src/runtime/HOG.cpp b/src/runtime/HOG.cpp
index 5d533dded4..01640bb0ac 100644
--- a/src/runtime/HOG.cpp
+++ b/src/runtime/HOG.cpp
@@ -24,7 +24,7 @@
#include "arm_compute/runtime/HOG.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -37,7 +37,7 @@ void HOG::init(const HOGInfo &input)
{
ARM_COMPUTE_ERROR_ON(nullptr != _descriptor);
_info = input;
- _descriptor = arm_compute::cpp14::make_unique<float[]>(_info.descriptor_size());
+ _descriptor = arm_compute::support::cpp14::make_unique<float[]>(_info.descriptor_size());
}
float *HOG::descriptor() const
diff --git a/src/runtime/LutAllocator.cpp b/src/runtime/LutAllocator.cpp
index 17baf21f45..eb9051cc0a 100644
--- a/src/runtime/LutAllocator.cpp
+++ b/src/runtime/LutAllocator.cpp
@@ -23,7 +23,7 @@
*/
#include "arm_compute/runtime/LutAllocator.h"
-#include "arm_compute/core/Helpers.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -39,7 +39,7 @@ uint8_t *LutAllocator::data() const
void LutAllocator::allocate()
{
- _buffer = arm_compute::cpp14::make_unique<uint8_t[]>(size());
+ _buffer = arm_compute::support::cpp14::make_unique<uint8_t[]>(size());
}
uint8_t *LutAllocator::lock()
diff --git a/src/runtime/MultiHOG.cpp b/src/runtime/MultiHOG.cpp
index 003dc93895..e0b60b1137 100644
--- a/src/runtime/MultiHOG.cpp
+++ b/src/runtime/MultiHOG.cpp
@@ -24,13 +24,13 @@
#include "arm_compute/runtime/MultiHOG.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/IMultiHOG.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
MultiHOG::MultiHOG(size_t num_models)
- : _num_models(num_models), _model(arm_compute::cpp14::make_unique<HOG[]>(_num_models))
+ : _num_models(num_models), _model(arm_compute::support::cpp14::make_unique<HOG[]>(_num_models))
{
}
diff --git a/src/runtime/NEON/functions/NEAbsoluteDifference.cpp b/src/runtime/NEON/functions/NEAbsoluteDifference.cpp
index b39feb3a2b..b4620f16dd 100644
--- a/src/runtime/NEON/functions/NEAbsoluteDifference.cpp
+++ b/src/runtime/NEON/functions/NEAbsoluteDifference.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEAbsoluteDifference.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEAbsoluteDifferenceKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEAbsoluteDifference::configure(const ITensor *input1, const ITensor *input2, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEAbsoluteDifferenceKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEAbsoluteDifferenceKernel>();
k->configure(input1, input2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEAccumulate.cpp b/src/runtime/NEON/functions/NEAccumulate.cpp
index c39abfc540..49524d2202 100644
--- a/src/runtime/NEON/functions/NEAccumulate.cpp
+++ b/src/runtime/NEON/functions/NEAccumulate.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEAccumulate.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEAccumulateKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEAccumulate::configure(const ITensor *input, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEAccumulateKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEAccumulateKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
@@ -41,13 +41,13 @@ void NEAccumulateWeighted::configure(const ITensor *input, float alpha, ITensor
{
if(use_fp16)
{
- auto k = arm_compute::cpp14::make_unique<NEAccumulateWeightedFP16Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEAccumulateWeightedFP16Kernel>();
k->configure(input, alpha, output);
_kernel = std::move(k);
}
else
{
- auto k = arm_compute::cpp14::make_unique<NEAccumulateWeightedKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEAccumulateWeightedKernel>();
k->configure(input, alpha, output);
_kernel = std::move(k);
}
@@ -55,7 +55,7 @@ void NEAccumulateWeighted::configure(const ITensor *input, float alpha, ITensor
void NEAccumulateSquared::configure(const ITensor *input, uint32_t shift, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEAccumulateSquaredKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEAccumulateSquaredKernel>();
k->configure(input, shift, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEActivationLayer.cpp b/src/runtime/NEON/functions/NEActivationLayer.cpp
index 447ae6411b..57a1738f85 100644
--- a/src/runtime/NEON/functions/NEActivationLayer.cpp
+++ b/src/runtime/NEON/functions/NEActivationLayer.cpp
@@ -23,14 +23,14 @@
*/
#include "arm_compute/runtime/NEON/functions/NEActivationLayer.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEActivationLayerKernel.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void NEActivationLayer::configure(ITensor *input, ITensor *output, ActivationLayerInfo activation_info)
{
- auto k = arm_compute::cpp14::make_unique<NEActivationLayerKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEActivationLayerKernel>();
k->configure(input, output, activation_info);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEArithmeticAddition.cpp b/src/runtime/NEON/functions/NEArithmeticAddition.cpp
index 50cc38b489..11f5aa74e4 100644
--- a/src/runtime/NEON/functions/NEArithmeticAddition.cpp
+++ b/src/runtime/NEON/functions/NEArithmeticAddition.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEArithmeticAddition.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEArithmeticAdditionKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEArithmeticAddition::configure(const ITensor *input1, const ITensor *input2, ITensor *output, ConvertPolicy policy)
{
- auto k = arm_compute::cpp14::make_unique<NEArithmeticAdditionKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEArithmeticAdditionKernel>();
k->configure(input1, input2, output, policy);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEArithmeticSubtraction.cpp b/src/runtime/NEON/functions/NEArithmeticSubtraction.cpp
index a3d27c0ed6..37586af751 100644
--- a/src/runtime/NEON/functions/NEArithmeticSubtraction.cpp
+++ b/src/runtime/NEON/functions/NEArithmeticSubtraction.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEArithmeticSubtraction.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEArithmeticSubtractionKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEArithmeticSubtraction::configure(const ITensor *input1, const ITensor *input2, ITensor *output, ConvertPolicy policy)
{
- auto k = arm_compute::cpp14::make_unique<NEArithmeticSubtractionKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEArithmeticSubtractionKernel>();
k->configure(input1, input2, output, policy);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEBitwiseAnd.cpp b/src/runtime/NEON/functions/NEBitwiseAnd.cpp
index 5aafc51dc0..79820952bb 100644
--- a/src/runtime/NEON/functions/NEBitwiseAnd.cpp
+++ b/src/runtime/NEON/functions/NEBitwiseAnd.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEBitwiseAnd.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEBitwiseAndKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEBitwiseAnd::configure(const ITensor *input1, const ITensor *input2, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEBitwiseAndKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEBitwiseAndKernel>();
k->configure(input1, input2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEBitwiseNot.cpp b/src/runtime/NEON/functions/NEBitwiseNot.cpp
index af3df6e46a..c55957e2b4 100644
--- a/src/runtime/NEON/functions/NEBitwiseNot.cpp
+++ b/src/runtime/NEON/functions/NEBitwiseNot.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEBitwiseNot.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEBitwiseNotKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEBitwiseNot::configure(const ITensor *input, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEBitwiseNotKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEBitwiseNotKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEBitwiseOr.cpp b/src/runtime/NEON/functions/NEBitwiseOr.cpp
index d12c5e5f6f..01036daaef 100644
--- a/src/runtime/NEON/functions/NEBitwiseOr.cpp
+++ b/src/runtime/NEON/functions/NEBitwiseOr.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEBitwiseOr.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEBitwiseOrKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEBitwiseOr::configure(const ITensor *input1, const ITensor *input2, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEBitwiseOrKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEBitwiseOrKernel>();
k->configure(input1, input2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEBitwiseXor.cpp b/src/runtime/NEON/functions/NEBitwiseXor.cpp
index 65c943e64c..45916984b0 100644
--- a/src/runtime/NEON/functions/NEBitwiseXor.cpp
+++ b/src/runtime/NEON/functions/NEBitwiseXor.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEBitwiseXor.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEBitwiseXorKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEBitwiseXor::configure(const ITensor *input1, const ITensor *input2, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEBitwiseXorKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEBitwiseXorKernel>();
k->configure(input1, input2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEBox3x3.cpp b/src/runtime/NEON/functions/NEBox3x3.cpp
index 7f0b45d34c..46cf259073 100644
--- a/src/runtime/NEON/functions/NEBox3x3.cpp
+++ b/src/runtime/NEON/functions/NEBox3x3.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NEBox3x3.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEBox3x3Kernel.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -35,13 +35,13 @@ void NEBox3x3::configure(ITensor *input, ITensor *output, BorderMode border_mode
{
if(use_fp16)
{
- auto k = arm_compute::cpp14::make_unique<NEBox3x3FP16Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEBox3x3FP16Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
}
else
{
- auto k = arm_compute::cpp14::make_unique<NEBox3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEBox3x3Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NECannyEdge.cpp b/src/runtime/NEON/functions/NECannyEdge.cpp
index 26f31f557b..029d30c5d6 100644
--- a/src/runtime/NEON/functions/NECannyEdge.cpp
+++ b/src/runtime/NEON/functions/NECannyEdge.cpp
@@ -24,7 +24,6 @@
#include "arm_compute/runtime/NEON/functions/NECannyEdge.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/NEON/kernels/NECannyEdgeKernel.h"
#include "arm_compute/core/NEON/kernels/NEFillBorderKernel.h"
@@ -35,6 +34,7 @@
#include "arm_compute/runtime/NEON/functions/NESobel5x5.h"
#include "arm_compute/runtime/NEON/functions/NESobel7x7.h"
#include "arm_compute/runtime/TensorAllocator.h"
+#include "support/ToolchainSupport.h"
#include <cstring>
#include <utility>
@@ -85,19 +85,19 @@ void NECannyEdge::configure(ITensor *input, ITensor *output, int32_t upper_thr,
// Configure/Init sobelNxN
if(gradient_size == 3)
{
- auto k = arm_compute::cpp14::make_unique<NESobel3x3>();
+ auto k = arm_compute::support::cpp14::make_unique<NESobel3x3>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
}
else if(gradient_size == 5)
{
- auto k = arm_compute::cpp14::make_unique<NESobel5x5>();
+ auto k = arm_compute::support::cpp14::make_unique<NESobel5x5>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
}
else if(gradient_size == 7)
{
- auto k = arm_compute::cpp14::make_unique<NESobel7x7>();
+ auto k = arm_compute::support::cpp14::make_unique<NESobel7x7>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
}
@@ -109,13 +109,13 @@ void NECannyEdge::configure(ITensor *input, ITensor *output, int32_t upper_thr,
// Configure gradient
if(use_fp16)
{
- auto k = arm_compute::cpp14::make_unique<NEGradientFP16Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEGradientFP16Kernel>();
k->configure(&_gx, &_gy, &_magnitude, &_phase, norm_type);
_gradient = std::move(k);
}
else
{
- auto k = arm_compute::cpp14::make_unique<NEGradientKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEGradientKernel>();
k->configure(&_gx, &_gy, &_magnitude, &_phase, norm_type);
_gradient = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEChannelCombine.cpp b/src/runtime/NEON/functions/NEChannelCombine.cpp
index 84d4fff4ff..9166aa97db 100644
--- a/src/runtime/NEON/functions/NEChannelCombine.cpp
+++ b/src/runtime/NEON/functions/NEChannelCombine.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEChannelCombine.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEChannelCombineKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,14 +32,14 @@ using namespace arm_compute;
void NEChannelCombine::configure(const ITensor *plane0, const ITensor *plane1, const ITensor *plane2, const ITensor *plane3, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEChannelCombineKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEChannelCombineKernel>();
k->configure(plane0, plane1, plane2, plane3, output);
_kernel = std::move(k);
}
void NEChannelCombine::configure(const IImage *plane0, const IImage *plane1, const IImage *plane2, IMultiImage *output)
{
- auto k = arm_compute::cpp14::make_unique<NEChannelCombineKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEChannelCombineKernel>();
k->configure(plane0, plane1, plane2, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEChannelExtract.cpp b/src/runtime/NEON/functions/NEChannelExtract.cpp
index 634e918eac..7b8a99335f 100644
--- a/src/runtime/NEON/functions/NEChannelExtract.cpp
+++ b/src/runtime/NEON/functions/NEChannelExtract.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEChannelExtract.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEChannelExtractKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,14 +32,14 @@ using namespace arm_compute;
void NEChannelExtract::configure(const ITensor *input, Channel channel, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEChannelExtractKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEChannelExtractKernel>();
k->configure(input, channel, output);
_kernel = std::move(k);
}
void NEChannelExtract::configure(const IMultiImage *input, Channel channel, IImage *output)
{
- auto k = arm_compute::cpp14::make_unique<NEChannelExtractKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEChannelExtractKernel>();
k->configure(input, channel, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEColorConvert.cpp b/src/runtime/NEON/functions/NEColorConvert.cpp
index bbaa832284..b9fe1ff11d 100644
--- a/src/runtime/NEON/functions/NEColorConvert.cpp
+++ b/src/runtime/NEON/functions/NEColorConvert.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEColorConvert.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEColorConvertKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,28 +32,28 @@ using namespace arm_compute;
void NEColorConvert::configure(const ITensor *input, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEColorConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEColorConvertKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
void NEColorConvert::configure(const IMultiImage *input, IImage *output)
{
- auto k = arm_compute::cpp14::make_unique<NEColorConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEColorConvertKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
void NEColorConvert::configure(const IImage *input, IMultiImage *output)
{
- auto k = arm_compute::cpp14::make_unique<NEColorConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEColorConvertKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
void NEColorConvert::configure(const IMultiImage *input, IMultiImage *output)
{
- auto k = arm_compute::cpp14::make_unique<NEColorConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEColorConvertKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEConvolution.cpp b/src/runtime/NEON/functions/NEConvolution.cpp
index 3f39ae2cbd..4ad6450c67 100644
--- a/src/runtime/NEON/functions/NEConvolution.cpp
+++ b/src/runtime/NEON/functions/NEConvolution.cpp
@@ -24,7 +24,6 @@
#include "arm_compute/runtime/NEON/functions/NEConvolution.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/NEON/kernels/NEConvolutionKernel.h"
#include "arm_compute/core/PixelValue.h"
@@ -33,6 +32,7 @@
#include "arm_compute/core/Validate.h"
#include "arm_compute/runtime/NEON/NEScheduler.h"
#include "arm_compute/runtime/TensorAllocator.h"
+#include "support/ToolchainSupport.h"
#include <array>
#include <utility>
@@ -41,7 +41,7 @@ using namespace arm_compute;
void NEConvolution3x3::configure(ITensor *input, ITensor *output, const int16_t *conv, uint32_t scale, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NEConvolution3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEConvolution3x3Kernel>();
k->configure(input, output, conv, scale, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
@@ -113,7 +113,7 @@ template class arm_compute::NEConvolutionSquare<9>;
void NEConvolutionRectangle::configure(ITensor *input, ITensor *output, const int16_t *conv, uint32_t rows, uint32_t cols, uint32_t scale, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NEConvolutionRectangleKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEConvolutionRectangleKernel>();
k->configure(input, output, conv, rows, cols, scale, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/NEON/functions/NEDepthConcatenate.cpp b/src/runtime/NEON/functions/NEDepthConcatenate.cpp
index 7d2c5494a9..8661fe5fda 100644
--- a/src/runtime/NEON/functions/NEDepthConcatenate.cpp
+++ b/src/runtime/NEON/functions/NEDepthConcatenate.cpp
@@ -24,13 +24,13 @@
#include "arm_compute/runtime/NEON/functions/NEDepthConcatenate.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/NEON/kernels/NEDepthConcatenateKernel.h"
#include "arm_compute/core/NEON/kernels/NEFillBorderKernel.h"
#include "arm_compute/core/PixelValue.h"
#include "arm_compute/core/Types.h"
#include "arm_compute/runtime/NEON/NEScheduler.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -44,8 +44,8 @@ void NEDepthConcatenate::configure(std::vector<ITensor *> inputs_vector, ITensor
ARM_COMPUTE_ERROR_ON(inputs_vector.size() < 2);
_num_inputs = inputs_vector.size();
- _concat_kernels_vector = arm_compute::cpp14::make_unique<NEDepthConcatenateKernel[]>(_num_inputs);
- _border_handlers_vector = arm_compute::cpp14::make_unique<NEFillBorderKernel[]>(_num_inputs);
+ _concat_kernels_vector = arm_compute::support::cpp14::make_unique<NEDepthConcatenateKernel[]>(_num_inputs);
+ _border_handlers_vector = arm_compute::support::cpp14::make_unique<NEFillBorderKernel[]>(_num_inputs);
unsigned int depth_offset = 0;
for(unsigned int i = 0; i < _num_inputs; ++i)
diff --git a/src/runtime/NEON/functions/NEDepthConvert.cpp b/src/runtime/NEON/functions/NEDepthConvert.cpp
index a339cae316..011e366bf3 100644
--- a/src/runtime/NEON/functions/NEDepthConvert.cpp
+++ b/src/runtime/NEON/functions/NEDepthConvert.cpp
@@ -24,8 +24,9 @@
#include "arm_compute/runtime/NEON/functions/NEDepthConvert.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEDepthConvertKernel.h"
+#include "arm_compute/core/Validate.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -38,7 +39,7 @@ void NEDepthConvert::configure(const ITensor *input, ITensor *output, ConvertPol
ARM_COMPUTE_ERROR_ON(input == output);
ARM_COMPUTE_ERROR_ON(input->info()->data_type() == output->info()->data_type());
- auto k = arm_compute::cpp14::make_unique<NEDepthConvertKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEDepthConvertKernel>();
k->configure(input, output, policy, shift);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEDilate.cpp b/src/runtime/NEON/functions/NEDilate.cpp
index 0c016f14f9..5c733a8278 100644
--- a/src/runtime/NEON/functions/NEDilate.cpp
+++ b/src/runtime/NEON/functions/NEDilate.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NEDilate.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEDilateKernel.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void NEDilate::configure(ITensor *input, ITensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NEDilateKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEDilateKernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/NEON/functions/NEErode.cpp b/src/runtime/NEON/functions/NEErode.cpp
index 9b011db845..3609572de6 100644
--- a/src/runtime/NEON/functions/NEErode.cpp
+++ b/src/runtime/NEON/functions/NEErode.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NEErode.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEErodeKernel.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void NEErode::configure(ITensor *input, ITensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NEErodeKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEErodeKernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/NEON/functions/NEGEMMInterleave4x4.cpp b/src/runtime/NEON/functions/NEGEMMInterleave4x4.cpp
index 4c77c88656..63f330be6c 100644
--- a/src/runtime/NEON/functions/NEGEMMInterleave4x4.cpp
+++ b/src/runtime/NEON/functions/NEGEMMInterleave4x4.cpp
@@ -23,14 +23,14 @@
*/
#include "arm_compute/runtime/NEON/functions/NEGEMMInterleave4x4.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEGEMMInterleave4x4Kernel.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void NEGEMMInterleave4x4::configure(const ITensor *input, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEGEMMInterleave4x4Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEGEMMInterleave4x4Kernel>();
k->configure(input, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEGEMMTranspose1xW.cpp b/src/runtime/NEON/functions/NEGEMMTranspose1xW.cpp
index dc40ecec14..571bf2bc74 100644
--- a/src/runtime/NEON/functions/NEGEMMTranspose1xW.cpp
+++ b/src/runtime/NEON/functions/NEGEMMTranspose1xW.cpp
@@ -24,17 +24,17 @@
#include "arm_compute/runtime/NEON/functions/NEGEMMTranspose1xW.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/NEON/kernels/NEGEMMTranspose1xWKernel.h"
#include "arm_compute/core/Types.h"
#include "arm_compute/core/Validate.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void NEGEMMTranspose1xW::configure(const ITensor *input, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEGEMMTranspose1xWKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEGEMMTranspose1xWKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEGaussian3x3.cpp b/src/runtime/NEON/functions/NEGaussian3x3.cpp
index 95ba5cbdf9..db8eb63c90 100644
--- a/src/runtime/NEON/functions/NEGaussian3x3.cpp
+++ b/src/runtime/NEON/functions/NEGaussian3x3.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NEGaussian3x3.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEGaussian3x3Kernel.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void NEGaussian3x3::configure(ITensor *input, ITensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NEGaussian3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEGaussian3x3Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/NEON/functions/NEGaussianPyramid.cpp b/src/runtime/NEON/functions/NEGaussianPyramid.cpp
index e1d64f11f6..75c439511e 100644
--- a/src/runtime/NEON/functions/NEGaussianPyramid.cpp
+++ b/src/runtime/NEON/functions/NEGaussianPyramid.cpp
@@ -24,7 +24,6 @@
#include "arm_compute/runtime/NEON/functions/NEGaussianPyramid.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/NEON/kernels/NEGaussianPyramidKernel.h"
#include "arm_compute/core/NEON/kernels/NEScaleKernel.h"
@@ -36,6 +35,7 @@
#include "arm_compute/runtime/Pyramid.h"
#include "arm_compute/runtime/Tensor.h"
#include "arm_compute/runtime/TensorAllocator.h"
+#include "support/ToolchainSupport.h"
#include <cstddef>
@@ -68,9 +68,9 @@ void NEGaussianPyramidHalf::configure(const ITensor *input, IPyramid *pyramid, B
if(num_levels > 1)
{
- _border_handler = arm_compute::cpp14::make_unique<NEFillBorderKernel[]>(num_levels - 1);
- _horizontal_reduction = arm_compute::cpp14::make_unique<NEGaussianPyramidHorKernel[]>(num_levels - 1);
- _vertical_reduction = arm_compute::cpp14::make_unique<NEGaussianPyramidVertKernel[]>(num_levels - 1);
+ _border_handler = arm_compute::support::cpp14::make_unique<NEFillBorderKernel[]>(num_levels - 1);
+ _horizontal_reduction = arm_compute::support::cpp14::make_unique<NEGaussianPyramidHorKernel[]>(num_levels - 1);
+ _vertical_reduction = arm_compute::support::cpp14::make_unique<NEGaussianPyramidVertKernel[]>(num_levels - 1);
// Apply half scale to the X dimension of the tensor shape
TensorShape tensor_shape = pyramid->info()->tensor_shape();
@@ -135,9 +135,9 @@ void NEGaussianPyramidOrb::configure(const ITensor *input, IPyramid *pyramid, Bo
if(num_levels > 1)
{
- _gaus5x5 = arm_compute::cpp14::make_unique<NEGaussian5x5[]>(num_levels - 1);
- _scale_nearest = arm_compute::cpp14::make_unique<NEScaleKernel[]>(num_levels - 1);
- _offsets = arm_compute::cpp14::make_unique<Image[]>(num_levels - 1);
+ _gaus5x5 = arm_compute::support::cpp14::make_unique<NEGaussian5x5[]>(num_levels - 1);
+ _scale_nearest = arm_compute::support::cpp14::make_unique<NEScaleKernel[]>(num_levels - 1);
+ _offsets = arm_compute::support::cpp14::make_unique<Image[]>(num_levels - 1);
PyramidInfo pyramid_info(num_levels - 1, SCALE_PYRAMID_ORB, pyramid->info()->tensor_shape(), Format::U8);
_tmp.init(pyramid_info);
diff --git a/src/runtime/NEON/functions/NEHOGDetector.cpp b/src/runtime/NEON/functions/NEHOGDetector.cpp
index e8ed29d0b9..49d0778eaa 100644
--- a/src/runtime/NEON/functions/NEHOGDetector.cpp
+++ b/src/runtime/NEON/functions/NEHOGDetector.cpp
@@ -23,14 +23,14 @@
*/
#include "arm_compute/runtime/NEON/functions/NEHOGDetector.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEHOGDetectorKernel.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void NEHOGDetector::configure(const ITensor *input, const IHOG *hog, IDetectionWindowArray *detection_windows, const Size2D &detection_window_stride, float threshold, size_t idx_class)
{
- auto k = arm_compute::cpp14::make_unique<NEHOGDetectorKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEHOGDetectorKernel>();
k->configure(input, hog, detection_windows, detection_window_stride, threshold, idx_class);
_kernel = std::move(k);
} \ No newline at end of file
diff --git a/src/runtime/NEON/functions/NEHOGGradient.cpp b/src/runtime/NEON/functions/NEHOGGradient.cpp
index 2f4b8802e3..563d4c2640 100644
--- a/src/runtime/NEON/functions/NEHOGGradient.cpp
+++ b/src/runtime/NEON/functions/NEHOGGradient.cpp
@@ -23,10 +23,10 @@
*/
#include "arm_compute/runtime/NEON/functions/NEHOGGradient.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEMagnitudePhaseKernel.h"
#include "arm_compute/core/Validate.h"
#include "arm_compute/runtime/NEON/NEScheduler.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -54,13 +54,13 @@ void NEHOGGradient::configure(ITensor *input, ITensor *output_magnitude, ITensor
// Initialise magnitude/phase kernel
if(PhaseType::UNSIGNED == phase_type)
{
- auto k = arm_compute::cpp14::make_unique<NEMagnitudePhaseKernel<MagnitudeType::L2NORM, PhaseType::UNSIGNED>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEMagnitudePhaseKernel<MagnitudeType::L2NORM, PhaseType::UNSIGNED>>();
k->configure(&_gx, &_gy, output_magnitude, output_phase);
_mag_phase = std::move(k);
}
else
{
- auto k = arm_compute::cpp14::make_unique<NEMagnitudePhaseKernel<MagnitudeType::L2NORM, PhaseType::SIGNED>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEMagnitudePhaseKernel<MagnitudeType::L2NORM, PhaseType::SIGNED>>();
k->configure(&_gx, &_gy, output_magnitude, output_phase);
_mag_phase = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEHOGMultiDetection.cpp b/src/runtime/NEON/functions/NEHOGMultiDetection.cpp
index 173b8f4c42..635b793d0c 100644
--- a/src/runtime/NEON/functions/NEHOGMultiDetection.cpp
+++ b/src/runtime/NEON/functions/NEHOGMultiDetection.cpp
@@ -24,10 +24,11 @@
#include "arm_compute/runtime/NEON/functions/NEHOGMultiDetection.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/TensorInfo.h"
+#include "arm_compute/core/Validate.h"
#include "arm_compute/runtime/NEON/NEScheduler.h"
#include "arm_compute/runtime/Tensor.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -112,12 +113,12 @@ void NEHOGMultiDetection::configure(ITensor *input, const IMultiHOG *multi_hog,
_num_block_norm_kernel = input_block_norm.size(); // Number of NEHOGBlockNormalizationKernel kernels to compute
_num_hog_detect_kernel = input_hog_detect.size(); // Number of NEHOGDetector functions to compute
- _orient_bin_kernel = arm_compute::cpp14::make_unique<NEHOGOrientationBinningKernel[]>(_num_orient_bin_kernel);
- _block_norm_kernel = arm_compute::cpp14::make_unique<NEHOGBlockNormalizationKernel[]>(_num_block_norm_kernel);
- _hog_detect_kernel = arm_compute::cpp14::make_unique<NEHOGDetector[]>(_num_hog_detect_kernel);
- _non_maxima_kernel = arm_compute::cpp14::make_unique<CPPDetectionWindowNonMaximaSuppressionKernel>();
- _hog_space = arm_compute::cpp14::make_unique<Tensor[]>(_num_orient_bin_kernel);
- _hog_norm_space = arm_compute::cpp14::make_unique<Tensor[]>(_num_block_norm_kernel);
+ _orient_bin_kernel = arm_compute::support::cpp14::make_unique<NEHOGOrientationBinningKernel[]>(_num_orient_bin_kernel);
+ _block_norm_kernel = arm_compute::support::cpp14::make_unique<NEHOGBlockNormalizationKernel[]>(_num_block_norm_kernel);
+ _hog_detect_kernel = arm_compute::support::cpp14::make_unique<NEHOGDetector[]>(_num_hog_detect_kernel);
+ _non_maxima_kernel = arm_compute::support::cpp14::make_unique<CPPDetectionWindowNonMaximaSuppressionKernel>();
+ _hog_space = arm_compute::support::cpp14::make_unique<Tensor[]>(_num_orient_bin_kernel);
+ _hog_norm_space = arm_compute::support::cpp14::make_unique<Tensor[]>(_num_block_norm_kernel);
// Allocate tensors for magnitude and phase
TensorInfo info_mag(shape_img, Format::S16);
diff --git a/src/runtime/NEON/functions/NEHarrisCorners.cpp b/src/runtime/NEON/functions/NEHarrisCorners.cpp
index b54fb67ab7..53b1968db2 100644
--- a/src/runtime/NEON/functions/NEHarrisCorners.cpp
+++ b/src/runtime/NEON/functions/NEHarrisCorners.cpp
@@ -24,7 +24,6 @@
#include "arm_compute/runtime/NEON/functions/NEHarrisCorners.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEFillBorderKernel.h"
#include "arm_compute/core/NEON/kernels/NEHarrisCornersKernel.h"
#include "arm_compute/core/TensorInfo.h"
@@ -35,6 +34,7 @@
#include "arm_compute/runtime/NEON/functions/NESobel5x5.h"
#include "arm_compute/runtime/NEON/functions/NESobel7x7.h"
#include "arm_compute/runtime/TensorAllocator.h"
+#include "support/ToolchainSupport.h"
#include <cmath>
#include <utility>
@@ -73,28 +73,28 @@ void NEHarrisCorners::configure(IImage *input, float threshold, float min_dist,
_score.allocator()->init(tensor_info_score);
_nonmax.allocator()->init(tensor_info_score);
- _corners_list = arm_compute::cpp14::make_unique<InternalKeypoint[]>(shape.x() * shape.y());
+ _corners_list = arm_compute::support::cpp14::make_unique<InternalKeypoint[]>(shape.x() * shape.y());
// Set/init Sobel kernel accordingly with gradient_size
switch(gradient_size)
{
case 3:
{
- auto k = arm_compute::cpp14::make_unique<NESobel3x3>();
+ auto k = arm_compute::support::cpp14::make_unique<NESobel3x3>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
break;
}
case 5:
{
- auto k = arm_compute::cpp14::make_unique<NESobel5x5>();
+ auto k = arm_compute::support::cpp14::make_unique<NESobel5x5>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
break;
}
case 7:
{
- auto k = arm_compute::cpp14::make_unique<NESobel7x7>();
+ auto k = arm_compute::support::cpp14::make_unique<NESobel7x7>();
k->configure(input, &_gx, &_gy, border_mode, constant_border_value);
_sobel = std::move(k);
break;
@@ -112,21 +112,21 @@ void NEHarrisCorners::configure(IImage *input, float threshold, float min_dist,
{
case 3:
{
- auto k = arm_compute::cpp14::make_unique<NEHarrisScoreFP16Kernel<3>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEHarrisScoreFP16Kernel<3>>();
k->configure(&_gx, &_gy, &_score, norm_factor, threshold, sensitivity, border_mode == BorderMode::UNDEFINED);
_harris_score = std::move(k);
}
break;
case 5:
{
- auto k = arm_compute::cpp14::make_unique<NEHarrisScoreFP16Kernel<5>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEHarrisScoreFP16Kernel<5>>();
k->configure(&_gx, &_gy, &_score, norm_factor, threshold, sensitivity, border_mode == BorderMode::UNDEFINED);
_harris_score = std::move(k);
}
break;
case 7:
{
- auto k = arm_compute::cpp14::make_unique<NEHarrisScoreFP16Kernel<7>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEHarrisScoreFP16Kernel<7>>();
k->configure(&_gx, &_gy, &_score, norm_factor, threshold, sensitivity, border_mode == BorderMode::UNDEFINED);
_harris_score = std::move(k);
}
@@ -141,21 +141,21 @@ void NEHarrisCorners::configure(IImage *input, float threshold, float min_dist,
{
case 3:
{
- auto k = arm_compute::cpp14::make_unique<NEHarrisScoreKernel<3>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEHarrisScoreKernel<3>>();
k->configure(&_gx, &_gy, &_score, norm_factor, threshold, sensitivity, border_mode == BorderMode::UNDEFINED);
_harris_score = std::move(k);
}
break;
case 5:
{
- auto k = arm_compute::cpp14::make_unique<NEHarrisScoreKernel<5>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEHarrisScoreKernel<5>>();
k->configure(&_gx, &_gy, &_score, norm_factor, threshold, sensitivity, border_mode == BorderMode::UNDEFINED);
_harris_score = std::move(k);
}
break;
case 7:
{
- auto k = arm_compute::cpp14::make_unique<NEHarrisScoreKernel<7>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEHarrisScoreKernel<7>>();
k->configure(&_gx, &_gy, &_score, norm_factor, threshold, sensitivity, border_mode == BorderMode::UNDEFINED);
_harris_score = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEHistogram.cpp b/src/runtime/NEON/functions/NEHistogram.cpp
index c42b2a56e0..f333ecb1f8 100644
--- a/src/runtime/NEON/functions/NEHistogram.cpp
+++ b/src/runtime/NEON/functions/NEHistogram.cpp
@@ -24,17 +24,17 @@
#include "arm_compute/runtime/NEON/functions/NEHistogram.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/IDistribution1D.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
#include "arm_compute/runtime/NEON/NEScheduler.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
NEHistogram::NEHistogram()
- : _histogram_kernel(), _local_hist(), _window_lut(arm_compute::cpp14::make_unique<uint32_t[]>(window_lut_default_size)), _local_hist_size(0)
+ : _histogram_kernel(), _local_hist(), _window_lut(arm_compute::support::cpp14::make_unique<uint32_t[]>(window_lut_default_size)), _local_hist_size(0)
{
}
@@ -45,7 +45,7 @@ void NEHistogram::configure(const IImage *input, IDistribution1D *output)
// Allocate space for threads local histograms
_local_hist_size = output->num_bins() * NEScheduler::get().num_threads();
- _local_hist = arm_compute::cpp14::make_unique<uint32_t[]>(_local_hist_size);
+ _local_hist = arm_compute::support::cpp14::make_unique<uint32_t[]>(_local_hist_size);
// Configure kernel
_histogram_kernel.configure(input, output, _local_hist.get(), _window_lut.get());
diff --git a/src/runtime/NEON/functions/NEIntegralImage.cpp b/src/runtime/NEON/functions/NEIntegralImage.cpp
index af604e9295..2e94ed5f9a 100644
--- a/src/runtime/NEON/functions/NEIntegralImage.cpp
+++ b/src/runtime/NEON/functions/NEIntegralImage.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NEIntegralImage.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEIntegralImageKernel.h"
#include "arm_compute/core/Types.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void NEIntegralImage::configure(const ITensor *input, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEIntegralImageKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEIntegralImageKernel>();
k->configure(input, output);
_kernel = std::move(k);
_border_handler.configure(output, _kernel->border_size(), BorderMode::CONSTANT, 0);
diff --git a/src/runtime/NEON/functions/NELaplacianPyramid.cpp b/src/runtime/NEON/functions/NELaplacianPyramid.cpp
index 8232c79f2d..ec93759869 100644
--- a/src/runtime/NEON/functions/NELaplacianPyramid.cpp
+++ b/src/runtime/NEON/functions/NELaplacianPyramid.cpp
@@ -24,7 +24,6 @@
#include "arm_compute/runtime/NEON/functions/NELaplacianPyramid.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/IPyramid.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
@@ -33,6 +32,7 @@
#include "arm_compute/runtime/NEON/functions/NEGaussian5x5.h"
#include "arm_compute/runtime/NEON/functions/NEGaussianPyramid.h"
#include "arm_compute/runtime/Tensor.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -86,8 +86,8 @@ void NELaplacianPyramid::configure(const ITensor *input, IPyramid *pyramid, ITen
// Create Gaussian Pyramid function
_gaussian_pyr_function.configure(input, &_gauss_pyr, border_mode, constant_border_value);
- _convf = arm_compute::cpp14::make_unique<NEGaussian5x5[]>(_num_levels);
- _subf = arm_compute::cpp14::make_unique<NEArithmeticSubtraction[]>(_num_levels);
+ _convf = arm_compute::support::cpp14::make_unique<NEGaussian5x5[]>(_num_levels);
+ _subf = arm_compute::support::cpp14::make_unique<NEArithmeticSubtraction[]>(_num_levels);
for(unsigned int i = 0; i < _num_levels; ++i)
{
diff --git a/src/runtime/NEON/functions/NELaplacianReconstruct.cpp b/src/runtime/NEON/functions/NELaplacianReconstruct.cpp
index 36ac4a74d1..8366e2bfec 100644
--- a/src/runtime/NEON/functions/NELaplacianReconstruct.cpp
+++ b/src/runtime/NEON/functions/NELaplacianReconstruct.cpp
@@ -24,11 +24,11 @@
#include "arm_compute/runtime/NEON/functions/NELaplacianReconstruct.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/IPyramid.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
+#include "support/ToolchainSupport.h"
#include <cstddef>
@@ -61,8 +61,8 @@ void NELaplacianReconstruct::configure(const IPyramid *pyramid, const ITensor *i
_tmp_pyr.init(pyramid_info);
// Allocate add and scale functions. Level 0 does not need to be scaled.
- _addf = arm_compute::cpp14::make_unique<NEArithmeticAddition[]>(num_levels);
- _scalef = arm_compute::cpp14::make_unique<NEScale[]>(num_levels - 1);
+ _addf = arm_compute::support::cpp14::make_unique<NEArithmeticAddition[]>(num_levels);
+ _scalef = arm_compute::support::cpp14::make_unique<NEScale[]>(num_levels - 1);
const size_t last_level = num_levels - 1;
diff --git a/src/runtime/NEON/functions/NEMagnitude.cpp b/src/runtime/NEON/functions/NEMagnitude.cpp
index 9390ca2b6a..7877995d6b 100644
--- a/src/runtime/NEON/functions/NEMagnitude.cpp
+++ b/src/runtime/NEON/functions/NEMagnitude.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NEMagnitude.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEMagnitudePhaseKernel.h"
#include "arm_compute/core/Types.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -35,13 +35,13 @@ void NEMagnitude::configure(const ITensor *input1, const ITensor *input2, ITenso
{
if(use_fp16)
{
- auto k = arm_compute::cpp14::make_unique<NEMagnitudePhaseFP16Kernel<MagnitudeType::L2NORM, PhaseType::SIGNED>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEMagnitudePhaseFP16Kernel<MagnitudeType::L2NORM, PhaseType::SIGNED>>();
k->configure(input1, input2, output, nullptr);
_kernel = std::move(k);
}
else
{
- auto k = arm_compute::cpp14::make_unique<NEMagnitudePhaseKernel<MagnitudeType::L2NORM, PhaseType::SIGNED>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEMagnitudePhaseKernel<MagnitudeType::L2NORM, PhaseType::SIGNED>>();
k->configure(input1, input2, output, nullptr);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEMedian3x3.cpp b/src/runtime/NEON/functions/NEMedian3x3.cpp
index aa7cc97081..627e5fb2a7 100644
--- a/src/runtime/NEON/functions/NEMedian3x3.cpp
+++ b/src/runtime/NEON/functions/NEMedian3x3.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NEMedian3x3.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEMedian3x3Kernel.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void NEMedian3x3::configure(ITensor *input, ITensor *output, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NEMedian3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEMedian3x3Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/NEON/functions/NENonLinearFilter.cpp b/src/runtime/NEON/functions/NENonLinearFilter.cpp
index 01aea3b671..57bd4e7aff 100644
--- a/src/runtime/NEON/functions/NENonLinearFilter.cpp
+++ b/src/runtime/NEON/functions/NENonLinearFilter.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NENonLinearFilter.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NENonLinearFilterKernel.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -35,7 +35,7 @@ void NENonLinearFilter::configure(ITensor *input, ITensor *output, NonLinearFilt
BorderMode border_mode,
uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NENonLinearFilterKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NENonLinearFilterKernel>();
k->configure(input, output, function, mask_size, pattern, mask, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/NEON/functions/NENonMaximaSuppression3x3.cpp b/src/runtime/NEON/functions/NENonMaximaSuppression3x3.cpp
index e92d567d52..3b59820d09 100644
--- a/src/runtime/NEON/functions/NENonMaximaSuppression3x3.cpp
+++ b/src/runtime/NEON/functions/NENonMaximaSuppression3x3.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NENonMaximaSuppression3x3.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NENonMaximaSuppression3x3Kernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NENonMaximaSuppression3x3::configure(ITensor *input, ITensor *output, BorderMode border_mode)
{
- auto k = arm_compute::cpp14::make_unique<NENonMaximaSuppression3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NENonMaximaSuppression3x3Kernel>();
k->configure(input, output, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
diff --git a/src/runtime/NEON/functions/NEOpticalFlow.cpp b/src/runtime/NEON/functions/NEOpticalFlow.cpp
index 49135e442c..d851e9a62b 100644
--- a/src/runtime/NEON/functions/NEOpticalFlow.cpp
+++ b/src/runtime/NEON/functions/NEOpticalFlow.cpp
@@ -24,7 +24,6 @@
#include "arm_compute/runtime/NEON/functions/NEOpticalFlow.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/NEON/kernels/NELKTrackerKernel.h"
#include "arm_compute/core/TensorInfo.h"
@@ -34,6 +33,7 @@
#include "arm_compute/runtime/Pyramid.h"
#include "arm_compute/runtime/Tensor.h"
#include "arm_compute/runtime/TensorAllocator.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
@@ -65,10 +65,10 @@ void NEOpticalFlow::configure(const Pyramid *old_pyramid, const Pyramid *new_pyr
const float pyr_scale = old_pyramid->info()->scale();
- _func_scharr = arm_compute::cpp14::make_unique<NEScharr3x3[]>(_num_levels);
- _kernel_tracker = arm_compute::cpp14::make_unique<NELKTrackerKernel[]>(_num_levels);
- _scharr_gx = arm_compute::cpp14::make_unique<Tensor[]>(_num_levels);
- _scharr_gy = arm_compute::cpp14::make_unique<Tensor[]>(_num_levels);
+ _func_scharr = arm_compute::support::cpp14::make_unique<NEScharr3x3[]>(_num_levels);
+ _kernel_tracker = arm_compute::support::cpp14::make_unique<NELKTrackerKernel[]>(_num_levels);
+ _scharr_gx = arm_compute::support::cpp14::make_unique<Tensor[]>(_num_levels);
+ _scharr_gy = arm_compute::support::cpp14::make_unique<Tensor[]>(_num_levels);
_old_points_internal = LKInternalKeypointArray(old_points->num_values());
_new_points_internal = LKInternalKeypointArray(old_points->num_values());
diff --git a/src/runtime/NEON/functions/NEPhase.cpp b/src/runtime/NEON/functions/NEPhase.cpp
index 7683f461d3..436d22f3af 100644
--- a/src/runtime/NEON/functions/NEPhase.cpp
+++ b/src/runtime/NEON/functions/NEPhase.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEPhase.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEMagnitudePhaseKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEPhase::configure(const ITensor *input1, const ITensor *input2, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NEMagnitudePhaseKernel<MagnitudeType::L2NORM, PhaseType::SIGNED>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEMagnitudePhaseKernel<MagnitudeType::L2NORM, PhaseType::SIGNED>>();
k->configure(input1, input2, nullptr, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEPixelWiseMultiplication.cpp b/src/runtime/NEON/functions/NEPixelWiseMultiplication.cpp
index 056d33b370..2e2ea11e86 100644
--- a/src/runtime/NEON/functions/NEPixelWiseMultiplication.cpp
+++ b/src/runtime/NEON/functions/NEPixelWiseMultiplication.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEPixelWiseMultiplication.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEPixelWiseMultiplicationKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEPixelWiseMultiplication::configure(const ITensor *input1, const ITensor *input2, ITensor *output, float scale, ConvertPolicy overflow_policy, RoundingPolicy rounding_policy)
{
- auto k = arm_compute::cpp14::make_unique<NEPixelWiseMultiplicationKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEPixelWiseMultiplicationKernel>();
k->configure(input1, input2, output, scale, overflow_policy, rounding_policy);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEPoolingLayer.cpp b/src/runtime/NEON/functions/NEPoolingLayer.cpp
index 6f0cc4f160..4c4e11f7db 100644
--- a/src/runtime/NEON/functions/NEPoolingLayer.cpp
+++ b/src/runtime/NEON/functions/NEPoolingLayer.cpp
@@ -23,15 +23,15 @@
*/
#include "arm_compute/runtime/NEON/functions/NEPoolingLayer.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEPoolingLayerKernel.h"
+#include "support/ToolchainSupport.h"
using namespace arm_compute;
void NEPoolingLayer::configure(ITensor *input, ITensor *output, const PoolingLayerInfo &pool_info)
{
// Configure pooling kernel
- auto k = arm_compute::cpp14::make_unique<NEPoolingLayerKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEPoolingLayerKernel>();
k->configure(input, output, pool_info);
_kernel = std::move(k);
diff --git a/src/runtime/NEON/functions/NERemap.cpp b/src/runtime/NEON/functions/NERemap.cpp
index 9f06fb699c..882e93beae 100644
--- a/src/runtime/NEON/functions/NERemap.cpp
+++ b/src/runtime/NEON/functions/NERemap.cpp
@@ -24,13 +24,13 @@
#include "arm_compute/runtime/NEON/functions/NERemap.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/ITensor.h"
#include "arm_compute/core/NEON/kernels/NERemapKernel.h"
#include "arm_compute/core/PixelValue.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Validate.h"
#include "arm_compute/runtime/TensorAllocator.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -44,7 +44,7 @@ void NERemap::configure(ITensor *input, const ITensor *map_x, const ITensor *map
ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN(map_y, 1, DataType::F32);
ARM_COMPUTE_ERROR_ON_MSG(policy == InterpolationPolicy::AREA, "Area interpolation is not supported");
- auto k = arm_compute::cpp14::make_unique<NERemapKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NERemapKernel>();
k->configure(input, map_x, map_y, output, policy);
diff --git a/src/runtime/NEON/functions/NEScale.cpp b/src/runtime/NEON/functions/NEScale.cpp
index b70f626df0..0a551e937d 100644
--- a/src/runtime/NEON/functions/NEScale.cpp
+++ b/src/runtime/NEON/functions/NEScale.cpp
@@ -32,6 +32,7 @@
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/Window.h"
#include "arm_compute/runtime/TensorAllocator.h"
+#include "support/ToolchainSupport.h"
#include <cmath>
#include <cstddef>
@@ -116,7 +117,7 @@ void NEScale::configure(ITensor *input, ITensor *output, InterpolationPolicy pol
policy = InterpolationPolicy::NEAREST_NEIGHBOR;
}
- auto k = arm_compute::cpp14::make_unique<NEScaleKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEScaleKernel>();
// Check if the border mode is UNDEFINED
const bool border_undefined = border_mode == BorderMode::UNDEFINED;
diff --git a/src/runtime/NEON/functions/NEScharr3x3.cpp b/src/runtime/NEON/functions/NEScharr3x3.cpp
index 04b3f14ce7..ba9985e1d2 100644
--- a/src/runtime/NEON/functions/NEScharr3x3.cpp
+++ b/src/runtime/NEON/functions/NEScharr3x3.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NEScharr3x3.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEScharr3x3Kernel.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void NEScharr3x3::configure(ITensor *input, ITensor *output_x, ITensor *output_y, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NEScharr3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEScharr3x3Kernel>();
k->configure(input, output_x, output_y, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/NEON/functions/NESobel3x3.cpp b/src/runtime/NEON/functions/NESobel3x3.cpp
index 3b46fd78c1..753b1f600f 100644
--- a/src/runtime/NEON/functions/NESobel3x3.cpp
+++ b/src/runtime/NEON/functions/NESobel3x3.cpp
@@ -23,9 +23,9 @@
*/
#include "arm_compute/runtime/NEON/functions/NESobel3x3.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NESobel3x3Kernel.h"
#include "arm_compute/core/PixelValue.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -33,7 +33,7 @@ using namespace arm_compute;
void NESobel3x3::configure(ITensor *input, ITensor *output_x, ITensor *output_y, BorderMode border_mode, uint8_t constant_border_value)
{
- auto k = arm_compute::cpp14::make_unique<NESobel3x3Kernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NESobel3x3Kernel>();
k->configure(input, output_x, output_y, border_mode == BorderMode::UNDEFINED);
_kernel = std::move(k);
_border_handler.configure(input, _kernel->border_size(), border_mode, PixelValue(constant_border_value));
diff --git a/src/runtime/NEON/functions/NETableLookup.cpp b/src/runtime/NEON/functions/NETableLookup.cpp
index ebb8a0ac9b..cae117a13e 100644
--- a/src/runtime/NEON/functions/NETableLookup.cpp
+++ b/src/runtime/NEON/functions/NETableLookup.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NETableLookup.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NETableLookupKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NETableLookup::configure(const ITensor *input, const ILut *lut, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NETableLookupKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NETableLookupKernel>();
k->configure(input, lut, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEThreshold.cpp b/src/runtime/NEON/functions/NEThreshold.cpp
index 93dc124880..37883e5387 100644
--- a/src/runtime/NEON/functions/NEThreshold.cpp
+++ b/src/runtime/NEON/functions/NEThreshold.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NEThreshold.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEThresholdKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NEThreshold::configure(const ITensor *input, ITensor *output, uint8_t threshold, uint8_t false_value, uint8_t true_value, ThresholdType type, uint8_t upper)
{
- auto k = arm_compute::cpp14::make_unique<NEThresholdKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NEThresholdKernel>();
k->configure(input, output, threshold, false_value, true_value, type, upper);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NETranspose.cpp b/src/runtime/NEON/functions/NETranspose.cpp
index 53ac9c5ee3..eb81e02205 100644
--- a/src/runtime/NEON/functions/NETranspose.cpp
+++ b/src/runtime/NEON/functions/NETranspose.cpp
@@ -23,8 +23,8 @@
*/
#include "arm_compute/runtime/NEON/functions/NETranspose.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NETransposeKernel.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -32,7 +32,7 @@ using namespace arm_compute;
void NETranspose::configure(const ITensor *input, ITensor *output)
{
- auto k = arm_compute::cpp14::make_unique<NETransposeKernel>();
+ auto k = arm_compute::support::cpp14::make_unique<NETransposeKernel>();
k->configure(input, output);
_kernel = std::move(k);
}
diff --git a/src/runtime/NEON/functions/NEWarpAffine.cpp b/src/runtime/NEON/functions/NEWarpAffine.cpp
index 24fb16f9e3..889d827ed0 100644
--- a/src/runtime/NEON/functions/NEWarpAffine.cpp
+++ b/src/runtime/NEON/functions/NEWarpAffine.cpp
@@ -24,8 +24,9 @@
#include "arm_compute/runtime/NEON/functions/NEWarpAffine.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEWarpKernel.h"
+#include "arm_compute/core/Validate.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -41,14 +42,14 @@ void NEWarpAffine::configure(ITensor *input, ITensor *output, const float *matri
{
case InterpolationPolicy::NEAREST_NEIGHBOR:
{
- auto k = arm_compute::cpp14::make_unique<NEWarpAffineKernel<InterpolationPolicy::NEAREST_NEIGHBOR>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEWarpAffineKernel<InterpolationPolicy::NEAREST_NEIGHBOR>>();
k->configure(input, output, matrix, border_mode, constant_border_value);
_kernel = std::move(k);
break;
}
case InterpolationPolicy::BILINEAR:
{
- auto k = arm_compute::cpp14::make_unique<NEWarpAffineKernel<InterpolationPolicy::BILINEAR>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEWarpAffineKernel<InterpolationPolicy::BILINEAR>>();
k->configure(input, output, matrix, border_mode, constant_border_value);
_kernel = std::move(k);
break;
diff --git a/src/runtime/NEON/functions/NEWarpPerspective.cpp b/src/runtime/NEON/functions/NEWarpPerspective.cpp
index 84b2df5bfa..ed5d6a0d27 100644
--- a/src/runtime/NEON/functions/NEWarpPerspective.cpp
+++ b/src/runtime/NEON/functions/NEWarpPerspective.cpp
@@ -24,8 +24,9 @@
#include "arm_compute/runtime/NEON/functions/NEWarpPerspective.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/NEON/kernels/NEWarpKernel.h"
+#include "arm_compute/core/Validate.h"
+#include "support/ToolchainSupport.h"
#include <utility>
@@ -41,14 +42,14 @@ void NEWarpPerspective::configure(ITensor *input, ITensor *output, const float *
{
case InterpolationPolicy::NEAREST_NEIGHBOR:
{
- auto k = arm_compute::cpp14::make_unique<NEWarpPerspectiveKernel<InterpolationPolicy::NEAREST_NEIGHBOR>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEWarpPerspectiveKernel<InterpolationPolicy::NEAREST_NEIGHBOR>>();
k->configure(input, output, matrix, border_mode, constant_border_value);
_kernel = std::move(k);
break;
}
case InterpolationPolicy::BILINEAR:
{
- auto k = arm_compute::cpp14::make_unique<NEWarpPerspectiveKernel<InterpolationPolicy::BILINEAR>>();
+ auto k = arm_compute::support::cpp14::make_unique<NEWarpPerspectiveKernel<InterpolationPolicy::BILINEAR>>();
k->configure(input, output, matrix, border_mode, constant_border_value);
_kernel = std::move(k);
break;
diff --git a/src/runtime/Pyramid.cpp b/src/runtime/Pyramid.cpp
index f1b6c93b50..ebd65702a6 100644
--- a/src/runtime/Pyramid.cpp
+++ b/src/runtime/Pyramid.cpp
@@ -24,10 +24,10 @@
#include "arm_compute/runtime/Pyramid.h"
#include "arm_compute/core/Error.h"
-#include "arm_compute/core/Helpers.h"
#include "arm_compute/core/PyramidInfo.h"
#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/TensorShape.h"
+#include "support/ToolchainSupport.h"
#include <cmath>
@@ -46,7 +46,7 @@ void Pyramid::init_auto_padding(const PyramidInfo &info)
void Pyramid::internal_init(const PyramidInfo &info, bool auto_padding)
{
_info = info;
- _pyramid = arm_compute::cpp14::make_unique<Tensor[]>(_info.num_levels());
+ _pyramid = arm_compute::support::cpp14::make_unique<Tensor[]>(_info.num_levels());
size_t w = _info.width();
size_t h = _info.height();
diff --git a/support/ToolchainSupport.h b/support/ToolchainSupport.h
new file mode 100644
index 0000000000..36b08affb9
--- /dev/null
+++ b/support/ToolchainSupport.h
@@ -0,0 +1,310 @@
+/*
+ * Copyright (c) 2017 ARM Limited.
+ *
+ * SPDX-License-Identifier: MIT
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to
+ * deal in the Software without restriction, including without limitation the
+ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+#ifndef ARM_COMPUTE_TEST_TOOLCHAINSUPPORT
+#define ARM_COMPUTE_TEST_TOOLCHAINSUPPORT
+
+#include <algorithm>
+#include <cmath>
+#include <cstddef>
+#include <limits>
+#include <memory>
+#include <numeric>
+#include <sstream>
+#include <string>
+#include <type_traits>
+
+namespace arm_compute
+{
+namespace support
+{
+namespace cpp11
+{
+#ifdef __ANDROID__
+/** Convert integer and float values to string.
+ *
+ * @note This function implements the same behaviour as std::to_string. The
+ * latter is missing in some Android toolchains.
+ *
+ * @param[in] value Value to be converted to string.
+ *
+ * @return String representation of @p value.
+ */
+template <typename T, typename std::enable_if<std::is_arithmetic<typename std::decay<T>::type>::value, int>::type = 0>
+std::string to_string(T && value)
+{
+ std::stringstream stream;
+ stream << std::forward<T>(value);
+ return stream.str();
+}
+
+/** Convert string values to integer.
+ *
+ * @note This function implements the same behaviour as std::stoi. The latter
+ * is missing in some Android toolchains.
+ *
+ * @param[in] str String to be converted to int.
+ *
+ * @return Integer representation of @p str.
+ */
+inline int stoi(const std::string &str)
+{
+ std::stringstream stream(str);
+ int value = 0;
+ stream >> value;
+ return value;
+}
+
+/** Convert string values to unsigned long.
+ *
+ * @note This function implements the same behaviour as std::stoul. The latter
+ * is missing in some Android toolchains.
+ *
+ * @param[in] str String to be converted to unsigned long.
+ *
+ * @return Unsigned long representation of @p str.
+ */
+inline unsigned long stoul(const std::string &str)
+{
+ std::stringstream stream(str);
+ unsigned long value = 0;
+ stream >> value;
+ return value;
+}
+
+/** Convert string values to float.
+ *
+ * @note This function implements the same behaviour as std::stof. The latter
+ * is missing in some Android toolchains.
+ *
+ * @param[in] str String to be converted to float.
+ *
+ * @return Float representation of @p str.
+ */
+inline float stof(const std::string &str)
+{
+ std::stringstream stream(str);
+ float value = 0.f;
+ stream >> value;
+ return value;
+}
+
+/** Round floating-point value with half value rounding away from zero.
+ *
+ * @note This function implements the same behaviour as std::round except that it doesn't
+ * support Integral type. The latter is not in the namespace std in some Android toolchains.
+ *
+ * @param[in] value floating-point value to be rounded.
+ *
+ * @return Floating-point value of rounded @p value.
+ */
+template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
+inline T round(T value)
+{
+ return ::round(value);
+}
+
+/** Truncate floating-point value.
+ *
+ * @note This function implements the same behaviour as std::truncate except that it doesn't
+ * support Integral type. The latter is not in the namespace std in some Android toolchains.
+ *
+ * @param[in] value floating-point value to be truncated.
+ *
+ * @return Floating-point value of truncated @p value.
+ */
+template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
+inline T trunc(T value)
+{
+ return ::trunc(value);
+}
+
+/** Composes a floating point value with the magnitude of @p x and the sign of @p y.
+ *
+ * @note This function implements the same behaviour as std::copysign except that it doesn't
+ * support Integral type. The latter is not in the namespace std in some Android toolchains.
+ *
+ * @param[in] x value that contains the magnitued to be used in constructing the result.
+ * @param[in] y value that contains the sign to be used in constructin the result.
+ *
+ * @return Floating-point value with magnitude of @p x and sign of @p y.
+ */
+template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
+inline T copysign(T x, T y)
+{
+ return ::copysign(x, y);
+}
+#else
+/** Convert integer and float values to string.
+ *
+ * @note This function acts as a convenience wrapper around std::to_string. The
+ * latter is missing in some Android toolchains.
+ *
+ * @param[in] value Value to be converted to string.
+ *
+ * @return String representation of @p value.
+ */
+template <typename T>
+std::string to_string(T &&value)
+{
+ return ::std::to_string(std::forward<T>(value));
+}
+
+/** Convert string values to integer.
+ *
+ * @note This function acts as a convenience wrapper around std::stoi. The
+ * latter is missing in some Android toolchains.
+ *
+ * @param[in] args Arguments forwarded to std::stoi.
+ *
+ * @return Integer representation of input string.
+ */
+template <typename... Ts>
+int stoi(Ts &&... args)
+{
+ return ::std::stoi(std::forward<Ts>(args)...);
+}
+
+/** Convert string values to unsigned long.
+ *
+ * @note This function acts as a convenience wrapper around std::stoul. The
+ * latter is missing in some Android toolchains.
+ *
+ * @param[in] args Arguments forwarded to std::stoul.
+ *
+ * @return Unsigned long representation of input string.
+ */
+template <typename... Ts>
+int stoul(Ts &&... args)
+{
+ return ::std::stoul(std::forward<Ts>(args)...);
+}
+
+/** Convert string values to float.
+ *
+ * @note This function acts as a convenience wrapper around std::stof. The
+ * latter is missing in some Android toolchains.
+ *
+ * @param[in] args Arguments forwarded to std::stof.
+ *
+ * @return Float representation of input string.
+ */
+template <typename... Ts>
+int stof(Ts &&... args)
+{
+ return ::std::stof(std::forward<Ts>(args)...);
+}
+
+/** Round floating-point value with half value rounding away from zero.
+ *
+ * @note This function implements the same behaviour as std::round except that it doesn't
+ * support Integral type. The latter is not in the namespace std in some Android toolchains.
+ *
+ * @param[in] value floating-point value to be rounded.
+ *
+ * @return Floating-point value of rounded @p value.
+ */
+template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
+inline T round(T value)
+{
+ return std::round(value);
+}
+
+/** Truncate floating-point value.
+ *
+ * @note This function implements the same behaviour as std::truncate except that it doesn't
+ * support Integral type. The latter is not in the namespace std in some Android toolchains.
+ *
+ * @param[in] value floating-point value to be truncated.
+ *
+ * @return Floating-point value of truncated @p value.
+ */
+template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
+inline T trunc(T value)
+{
+ return std::trunc(value);
+}
+
+/** Composes a floating point value with the magnitude of @p x and the sign of @p y.
+ *
+ * @note This function implements the same behaviour as std::copysign except that it doesn't
+ * support Integral type. The latter is not in the namespace std in some Android toolchains.
+ *
+ * @param[in] x value that contains the magnitued to be used in constructing the result.
+ * @param[in] y value that contains the sign to be used in constructin the result.
+ *
+ * @return Floating-point value with magnitude of @p x and sign of @p y.
+ */
+template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
+inline T copysign(T x, T y)
+{
+ return std::copysign(x, y);
+}
+#endif
+} // namespace cpp11
+
+namespace cpp14
+{
+/** make_unqiue is missing in CPP11. Reimplement it according to the standard
+ * proposal.
+ */
+template <class T>
+struct _Unique_if
+{
+ typedef std::unique_ptr<T> _Single_object;
+};
+
+template <class T>
+struct _Unique_if<T[]>
+{
+ typedef std::unique_ptr<T[]> _Unknown_bound;
+};
+
+template <class T, size_t N>
+struct _Unique_if<T[N]>
+{
+ typedef void _Known_bound;
+};
+
+template <class T, class... Args>
+typename _Unique_if<T>::_Single_object
+make_unique(Args &&... args)
+{
+ return std::unique_ptr<T>(new T(std::forward<Args>(args)...));
+}
+
+template <class T>
+typename _Unique_if<T>::_Unknown_bound
+make_unique(size_t n)
+{
+ typedef typename std::remove_extent<T>::type U;
+ return std::unique_ptr<T>(new U[n]());
+}
+
+template <class T, class... Args>
+typename _Unique_if<T>::_Known_bound
+make_unique(Args &&...) = delete;
+} // namespace cpp14
+} // namespace support
+} // namespace arm_compute
+#endif
diff --git a/tests/RawTensor.cpp b/tests/RawTensor.cpp
index 6bfdf57b36..402b5f3d0b 100644
--- a/tests/RawTensor.cpp
+++ b/tests/RawTensor.cpp
@@ -26,6 +26,7 @@
#include "Utils.h"
#include "arm_compute/core/Utils.h"
+#include "support/ToolchainSupport.h"
#include <algorithm>
#include <array>
@@ -43,7 +44,7 @@ RawTensor::RawTensor(TensorShape shape, Format format, int fixed_point_position)
_format(format),
_fixed_point_position(fixed_point_position)
{
- _buffer = ::arm_compute::test::cpp14::make_unique<BufferType[]>(size());
+ _buffer = support::cpp14::make_unique<BufferType[]>(size());
}
RawTensor::RawTensor(TensorShape shape, DataType data_type, int num_channels, int fixed_point_position)
@@ -53,7 +54,7 @@ RawTensor::RawTensor(TensorShape shape, DataType data_type, int num_channels, in
_num_channels(num_channels),
_fixed_point_position(fixed_point_position)
{
- _buffer = ::arm_compute::test::cpp14::make_unique<BufferType[]>(size());
+ _buffer = support::cpp14::make_unique<BufferType[]>(size());
}
RawTensor::RawTensor(const RawTensor &tensor)
@@ -62,7 +63,7 @@ RawTensor::RawTensor(const RawTensor &tensor)
_format(tensor.format()),
_fixed_point_position(tensor.fixed_point_position())
{
- _buffer = ::arm_compute::test::cpp14::make_unique<BufferType[]>(tensor.size());
+ _buffer = support::cpp14::make_unique<BufferType[]>(tensor.size());
std::copy(tensor.data(), tensor.data() + size(), _buffer.get());
}
diff --git a/tests/Utils.h b/tests/Utils.h
index 25023d46e6..3be046182a 100644
--- a/tests/Utils.h
+++ b/tests/Utils.h
@@ -27,8 +27,10 @@
#include "arm_compute/core/Coordinates.h"
#include "arm_compute/core/Error.h"
#include "arm_compute/core/FixedPoint.h"
+#include "arm_compute/core/TensorInfo.h"
#include "arm_compute/core/TensorShape.h"
#include "arm_compute/core/Types.h"
+#include "support/ToolchainSupport.h"
#include <cmath>
#include <cstddef>
@@ -46,230 +48,6 @@ namespace arm_compute
{
namespace test
{
-namespace cpp11
-{
-#ifdef __ANDROID__
-/** Convert integer and float values to string.
- *
- * @note This function implements the same behaviour as std::to_string. The
- * latter is missing in some Android toolchains.
- *
- * @param[in] value Value to be converted to string.
- *
- * @return String representation of @p value.
- */
-template <typename T, typename std::enable_if<std::is_arithmetic<typename std::decay<T>::type>::value, int>::type = 0>
-std::string to_string(T && value)
-{
- std::stringstream stream;
- stream << std::forward<T>(value);
- return stream.str();
-}
-
-/** Convert string values to integer.
- *
- * @note This function implements the same behaviour as std::stoi. The latter
- * is missing in some Android toolchains.
- *
- * @param[in] str String to be converted to int.
- *
- * @return Integer representation of @p str.
- */
-inline int stoi(const std::string &str)
-{
- std::stringstream stream(str);
- int value = 0;
- stream >> value;
- return value;
-}
-
-/** Convert string values to unsigned long.
- *
- * @note This function implements the same behaviour as std::stoul. The latter
- * is missing in some Android toolchains.
- *
- * @param[in] str String to be converted to unsigned long.
- *
- * @return Unsigned long representation of @p str.
- */
-inline unsigned long stoul(const std::string &str)
-{
- std::stringstream stream(str);
- unsigned long value = 0;
- stream >> value;
- return value;
-}
-
-/** Convert string values to float.
- *
- * @note This function implements the same behaviour as std::stof. The latter
- * is missing in some Android toolchains.
- *
- * @param[in] str String to be converted to float.
- *
- * @return Float representation of @p str.
- */
-inline float stof(const std::string &str)
-{
- std::stringstream stream(str);
- float value = 0.f;
- stream >> value;
- return value;
-}
-
-/** Round floating-point value with half value rounding away from zero.
- *
- * @note This function implements the same behaviour as std::round except that it doesn't
- * support Integral type. The latter is not in the namespace std in some Android toolchains.
- *
- * @param[in] value floating-point value to be rounded.
- *
- * @return Floating-point value of rounded @p value.
- */
-template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
-inline T round(T value)
-{
- return ::round(value);
-}
-
-/** Truncate floating-point value.
- *
- * @note This function implements the same behaviour as std::truncate except that it doesn't
- * support Integral type. The latter is not in the namespace std in some Android toolchains.
- *
- * @param[in] value floating-point value to be truncated.
- *
- * @return Floating-point value of truncated @p value.
- */
-template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
-inline T trunc(T value)
-{
- return ::trunc(value);
-}
-
-/** Composes a floating point value with the magnitude of @p x and the sign of @p y.
- *
- * @note This function implements the same behaviour as std::copysign except that it doesn't
- * support Integral type. The latter is not in the namespace std in some Android toolchains.
- *
- * @param[in] x value that contains the magnitued to be used in constructing the result.
- * @param[in] y value that contains the sign to be used in constructin the result.
- *
- * @return Floating-point value with magnitude of @p x and sign of @p y.
- */
-template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
-inline T copysign(T x, T y)
-{
- return ::copysign(x, y);
-}
-#else
-/** Convert integer and float values to string.
- *
- * @note This function acts as a convenience wrapper around std::to_string. The
- * latter is missing in some Android toolchains.
- *
- * @param[in] value Value to be converted to string.
- *
- * @return String representation of @p value.
- */
-template <typename T>
-std::string to_string(T &&value)
-{
- return ::std::to_string(std::forward<T>(value));
-}
-
-/** Convert string values to integer.
- *
- * @note This function acts as a convenience wrapper around std::stoi. The
- * latter is missing in some Android toolchains.
- *
- * @param[in] args Arguments forwarded to std::stoi.
- *
- * @return Integer representation of input string.
- */
-template <typename... Ts>
-int stoi(Ts &&... args)
-{
- return ::std::stoi(std::forward<Ts>(args)...);
-}
-
-/** Convert string values to unsigned long.
- *
- * @note This function acts as a convenience wrapper around std::stoul. The
- * latter is missing in some Android toolchains.
- *
- * @param[in] args Arguments forwarded to std::stoul.
- *
- * @return Unsigned long representation of input string.
- */
-template <typename... Ts>
-int stoul(Ts &&... args)
-{
- return ::std::stoul(std::forward<Ts>(args)...);
-}
-
-/** Convert string values to float.
- *
- * @note This function acts as a convenience wrapper around std::stof. The
- * latter is missing in some Android toolchains.
- *
- * @param[in] args Arguments forwarded to std::stof.
- *
- * @return Float representation of input string.
- */
-template <typename... Ts>
-int stof(Ts &&... args)
-{
- return ::std::stof(std::forward<Ts>(args)...);
-}
-
-/** Round floating-point value with half value rounding away from zero.
- *
- * @note This function implements the same behaviour as std::round except that it doesn't
- * support Integral type. The latter is not in the namespace std in some Android toolchains.
- *
- * @param[in] value floating-point value to be rounded.
- *
- * @return Floating-point value of rounded @p value.
- */
-template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
-inline T round(T value)
-{
- return std::round(value);
-}
-
-/** Truncate floating-point value.
- *
- * @note This function implements the same behaviour as std::truncate except that it doesn't
- * support Integral type. The latter is not in the namespace std in some Android toolchains.
- *
- * @param[in] value floating-point value to be truncated.
- *
- * @return Floating-point value of truncated @p value.
- */
-template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
-inline T trunc(T value)
-{
- return std::trunc(value);
-}
-
-/** Composes a floating point value with the magnitude of @p x and the sign of @p y.
- *
- * @note This function implements the same behaviour as std::copysign except that it doesn't
- * support Integral type. The latter is not in the namespace std in some Android toolchains.
- *
- * @param[in] x value that contains the magnitued to be used in constructing the result.
- * @param[in] y value that contains the sign to be used in constructin the result.
- *
- * @return Floating-point value with magnitude of @p x and sign of @p y.
- */
-template <typename T, typename = typename std::enable_if<std::is_floating_point<T>::value>::type>
-inline T copysign(T x, T y)
-{
- return std::copysign(x, y);
-}
-#endif
-
/** Round floating-point value with half value rounding to positive infinity.
*
* @param[in] value floating-point value to be rounded.
@@ -301,58 +79,14 @@ inline T round_half_even(T value, T epsilon = std::numeric_limits<T>::epsilon())
// If 'ipart' is even then return 'ipart'
if(std::fmod(ipart, 2.f) < epsilon)
{
- return cpp11::copysign(ipart, value);
+ return support::cpp11::copysign(ipart, value);
}
// Else return the nearest even integer
- return cpp11::copysign(std::ceil(ipart + 0.5f), value);
+ return support::cpp11::copysign(std::ceil(ipart + 0.5f), value);
}
// Otherwise use the usual round to closest
- return cpp11::copysign(cpp11::round(positive_value), value);
+ return support::cpp11::copysign(support::cpp11::round(positive_value), value);
}
-} // namespace cpp11
-
-namespace cpp14
-{
-/** make_unqiue is missing in CPP11. Reimplement it according to the standard
- * proposal.
- */
-template <class T>
-struct _Unique_if
-{
- typedef std::unique_ptr<T> _Single_object;
-};
-
-template <class T>
-struct _Unique_if<T[]>
-{
- typedef std::unique_ptr<T[]> _Unknown_bound;
-};
-
-template <class T, size_t N>
-struct _Unique_if<T[N]>
-{
- typedef void _Known_bound;
-};
-
-template <class T, class... Args>
-typename _Unique_if<T>::_Single_object
-make_unique(Args &&... args)
-{
- return std::unique_ptr<T>(new T(std::forward<Args>(args)...));
-}
-
-template <class T>
-typename _Unique_if<T>::_Unknown_bound
-make_unique(size_t n)
-{
- typedef typename std::remove_extent<T>::type U;
- return std::unique_ptr<T>(new U[n]());
-}
-
-template <class T, class... Args>
-typename _Unique_if<T>::_Known_bound
-make_unique(Args &&...) = delete;
-} // namespace cpp14
namespace traits
{
@@ -663,7 +397,6 @@ inline bool is_in_valid_region(const ValidRegion &valid_region, const Coordinate
}
return true;
}
-
} // namespace test
} // namespace arm_compute
#endif
diff --git a/tests/benchmark/PMUCounter.cpp b/tests/benchmark/PMUCounter.cpp
index e87dae82e6..6d59dae65d 100644
--- a/tests/benchmark/PMUCounter.cpp
+++ b/tests/benchmark/PMUCounter.cpp
@@ -24,6 +24,7 @@
#include "PMUCounter.h"
#include "Utils.h"
+#include "support/ToolchainSupport.h"
#define _GNU_SOURCE 1
#include <asm/unistd.h>
@@ -89,7 +90,7 @@ void CycleCounter::stop()
std::unique_ptr<Instrument::IMeasurement> CycleCounter::get_measurement() const
{
- return ::arm_compute::test::cpp14::make_unique<Instrument::Measurement<long long>>(_cycles);
+ return support::cpp14::make_unique<Instrument::Measurement<long long>>(_cycles);
}
InstructionCounter::InstructionCounter()
diff --git a/tests/benchmark/WallClockTimer.cpp b/tests/benchmark/WallClockTimer.cpp
index 9ab53d0b3c..717fe04b31 100644
--- a/tests/benchmark/WallClockTimer.cpp
+++ b/tests/benchmark/WallClockTimer.cpp
@@ -24,6 +24,7 @@
#include "WallClockTimer.h"
#include "Utils.h"
+#include "support/ToolchainSupport.h"
namespace arm_compute
{
@@ -49,7 +50,7 @@ void WallClockTimer::stop()
std::unique_ptr<Instrument::IMeasurement> WallClockTimer::get_measurement() const
{
const std::chrono::duration<float, std::milli> delta = _stop - _start;
- return ::arm_compute::test::cpp14::make_unique<Instrument::Measurement<float>>(delta.count());
+ return support::cpp14::make_unique<Instrument::Measurement<float>>(delta.count());
}
} // namespace benchmark
} // namespace test
diff --git a/tests/benchmark/main.cpp b/tests/benchmark/main.cpp
index 7ce6a26acd..1b6bafb3a1 100644
--- a/tests/benchmark/main.cpp
+++ b/tests/benchmark/main.cpp
@@ -30,6 +30,7 @@
#include "WallClockTimer.h"
#include "benchmark/benchmark_api.h"
+#include "support/ToolchainSupport.h"
#ifdef OPENCL
#include "arm_compute/runtime/CL/CLScheduler.h"
@@ -78,11 +79,11 @@ int main(int argc, char **argv)
if(user_config.seed.is_set())
{
- library = cpp14::make_unique<TensorLibrary>(user_config.path.get(), user_config.seed);
+ library = arm_compute::support::cpp14::make_unique<TensorLibrary>(user_config.path.get(), user_config.seed);
}
else
{
- library = cpp14::make_unique<TensorLibrary>(user_config.path.get());
+ library = arm_compute::support::cpp14::make_unique<TensorLibrary>(user_config.path.get());
}
#ifdef OPENCL
diff --git a/tests/validation/FixedPoint.h b/tests/validation/FixedPoint.h
index fa99ff84c2..dca6e7ed2f 100644
--- a/tests/validation/FixedPoint.h
+++ b/tests/validation/FixedPoint.h
@@ -25,6 +25,7 @@
#define __ARM_COMPUTE_TEST_VALIDATION_FIXEDPOINT_H__
#include "Utils.h"
+#include "support/ToolchainSupport.h"
#include <cassert>
#include <cstdint>
@@ -147,7 +148,7 @@ public:
* @param[in] p Fixed point precision
*/
fixed_point(std::string str, uint8_t p)
- : _value(detail::constant_expr<T>::to_fixed(arm_compute::test::cpp11::stof(str), p)), _fixed_point_position(p)
+ : _value(detail::constant_expr<T>::to_fixed(support::cpp11::stof(str), p)), _fixed_point_position(p)
{
assert(p > 0 && p < std::numeric_limits<T>::digits);
}
diff --git a/tests/validation/TensorOperations.h b/tests/validation/TensorOperations.h
index 5557cfc2df..4f7765613c 100644
--- a/tests/validation/TensorOperations.h
+++ b/tests/validation/TensorOperations.h
@@ -28,6 +28,7 @@
#include "Tensor.h"
#include "Types.h"
#include "Utils.h"
+#include "support/ToolchainSupport.h"
#include "FixedPoint.h"
#include "Types.h"
@@ -257,7 +258,7 @@ void apply_2d_spatial_filter(Coordinates coord, const Tensor<T1> &in, Tensor<T3>
}
coord.set(0, x);
coord.set(1, y);
- const double rounded_val = cpp11::trunc(val * static_cast<double>(scale));
+ const double rounded_val = support::cpp11::trunc(val * static_cast<double>(scale));
out[coord2index(in.shape(), coord)] = saturate_cast<T3>(rounded_val);
}
} // namespace
@@ -790,13 +791,13 @@ void pixel_wise_multiplication(const Tensor<T1> &in1, const Tensor<T2> &in2, Ten
switch(rounding_policy)
{
case(RoundingPolicy::TO_ZERO):
- rounded_val = cpp11::trunc(val);
+ rounded_val = support::cpp11::trunc(val);
break;
case(RoundingPolicy::TO_NEAREST_UP):
- rounded_val = cpp11::round_half_up(val);
+ rounded_val = round_half_up(val);
break;
case(RoundingPolicy::TO_NEAREST_EVEN):
- rounded_val = cpp11::round_half_even(val);
+ rounded_val = round_half_even(val);
break;
default:
ARM_COMPUTE_ERROR("Unsupported rounding policy");
diff --git a/tests/validation/UNIT/FixedPoint.cpp b/tests/validation/UNIT/FixedPoint.cpp
index 8042bb6da8..9206863ec6 100644
--- a/tests/validation/UNIT/FixedPoint.cpp
+++ b/tests/validation/UNIT/FixedPoint.cpp
@@ -25,6 +25,7 @@
#include "TypePrinter.h"
#include "Utils.h"
+#include "support/ToolchainSupport.h"
#include "validation/Validation.h"
#include "validation/ValidationUserConfiguration.h"
@@ -52,7 +53,7 @@ BOOST_AUTO_TEST_SUITE(FixedPoint)
BOOST_TEST_DECORATOR(*boost::unit_test::label("precommit") * boost::unit_test::label("nightly"))
BOOST_DATA_TEST_CASE(FixedPointQS8Inputs, boost::unit_test::data::make(func_names) * boost::unit_test::data::xrange(1, 7), func_name, frac_bits)
{
- const std::string base_file_name = user_config.path.get() + "/dumps/" + func_name + "_Q8." + cpp11::to_string(frac_bits);
+ const std::string base_file_name = user_config.path.get() + "/dumps/" + func_name + "_Q8." + support::cpp11::to_string(frac_bits);
std::ifstream inputs_file{ base_file_name + ".in", std::ios::binary | std::ios::in };
BOOST_TEST_INFO(base_file_name + ".in");
@@ -84,7 +85,7 @@ BOOST_TEST_DECORATOR(*boost::unit_test::label("precommit") * boost::unit_test::l
BOOST_DATA_TEST_CASE(FixedPointQS8Outputs, (boost::unit_test::data::make(func_names) * boost::unit_test::data::xrange(1, 7)) ^ (boost::unit_test::data::make({ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 8, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 32, 67 })),
func_name, frac_bits, expected_failures)
{
- const std::string base_file_name = user_config.path.get() + "/dumps/" + func_name + "_Q8." + cpp11::to_string(frac_bits);
+ const std::string base_file_name = user_config.path.get() + "/dumps/" + func_name + "_Q8." + support::cpp11::to_string(frac_bits);
std::ifstream inputs_file{ base_file_name + ".in", std::ios::binary | std::ios::in };
std::ifstream reference_file{ base_file_name + ".out", std::ios::binary | std::ios::in };
diff --git a/tests/validation/UNIT/Utils.cpp b/tests/validation/UNIT/Utils.cpp
index 7a09be52b5..69523a5620 100644
--- a/tests/validation/UNIT/Utils.cpp
+++ b/tests/validation/UNIT/Utils.cpp
@@ -32,7 +32,6 @@
using namespace arm_compute;
using namespace arm_compute::test;
-using namespace arm_compute::test::cpp11;
using namespace arm_compute::test::validation;
#ifndef DOXYGEN_SKIP_THIS
@@ -43,14 +42,14 @@ BOOST_TEST_DECORATOR(*boost::unit_test::label("precommit") * boost::unit_test::l
BOOST_DATA_TEST_CASE(RoundHalfUp, boost::unit_test::data::make({ 1.f, 1.2f, 1.5f, 2.5f, 2.9f, -3.f, -3.5f, -3.8f, -4.3f, -4.5f }) ^ boost::unit_test::data::make({ 1.f, 1.f, 2.f, 3.f, 3.f, -3.f, -3.f, -4.f, -4.f, -4.f }),
value, result)
{
- BOOST_TEST(cpp11::round_half_up(value) == result);
+ BOOST_TEST(round_half_up(value) == result);
}
BOOST_TEST_DECORATOR(*boost::unit_test::label("precommit") * boost::unit_test::label("nightly"))
BOOST_DATA_TEST_CASE(RoundHalfEven, boost::unit_test::data::make({ 1.f, 1.2f, 1.5f, 2.5f, 2.9f, -3.f, -3.5f, -3.8f, -4.3f, -4.5f }) ^ boost::unit_test::data::make({ 1.f, 1.f, 2.f, 2.f, 3.f, -3.f, -4.f, -4.f, -4.f, -4.f }),
value, result)
{
- BOOST_TEST(cpp11::round_half_even(value) == result);
+ BOOST_TEST(round_half_even(value) == result);
}
BOOST_TEST_DECORATOR(*boost::unit_test::label("precommit") * boost::unit_test::label("nightly"))
diff --git a/tests/validation/main.cpp b/tests/validation/main.cpp
index c89372637f..6ec6885159 100644
--- a/tests/validation/main.cpp
+++ b/tests/validation/main.cpp
@@ -28,6 +28,7 @@
#include "Utils.h"
#include "ValidationProgramOptions.h"
#include "ValidationUserConfiguration.h"
+#include "support/ToolchainSupport.h"
#include "arm_compute/runtime/Scheduler.h"
@@ -55,11 +56,11 @@ struct GlobalFixture
{
if(user_config.seed.is_set())
{
- library = cpp14::make_unique<TensorLibrary>(user_config.path.get(), user_config.seed);
+ library = arm_compute::support::cpp14::make_unique<TensorLibrary>(user_config.path.get(), user_config.seed);
}
else
{
- library = cpp14::make_unique<TensorLibrary>(user_config.path.get());
+ library = arm_compute::support::cpp14::make_unique<TensorLibrary>(user_config.path.get());
}
std::cout << "Seed: " << library->seed() << "\n";