From 205eed8cf22d221fbee6442df73be9870879c9b5 Mon Sep 17 00:00:00 2001 From: Giorgio Arena Date: Wed, 14 Aug 2019 10:13:50 +0100 Subject: COMPMID-2080 Create a new kernel for CLPad with CONSTANT mode Change-Id: Ib67bacd40c13c7784ca9f5699a235f9d106baddb Signed-off-by: Giorgio Arena Reviewed-on: https://review.mlplatform.org/c/1739 Tested-by: Arm Jenkins Reviewed-by: Giuseppe Rossini Comments-Addressed: Arm Jenkins --- arm_compute/runtime/CL/functions/CLPadLayer.h | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'arm_compute/runtime') diff --git a/arm_compute/runtime/CL/functions/CLPadLayer.h b/arm_compute/runtime/CL/functions/CLPadLayer.h index 7f140d9e1d..58e0cabe63 100644 --- a/arm_compute/runtime/CL/functions/CLPadLayer.h +++ b/arm_compute/runtime/CL/functions/CLPadLayer.h @@ -25,14 +25,10 @@ #define __ARM_COMPUTE_CLPADLAYER_H__ #include "arm_compute/core/CL/kernels/CLCopyKernel.h" -#include "arm_compute/core/CL/kernels/CLMemsetKernel.h" -#include "arm_compute/core/Types.h" -#include "arm_compute/runtime/CL/functions/CLConcatenateLayer.h" - -#include "arm_compute/runtime/CL/CLScheduler.h" +#include "arm_compute/core/CL/kernels/CLPadLayerKernel.h" #include "arm_compute/runtime/CL/CLTensor.h" +#include "arm_compute/runtime/CL/functions/CLConcatenateLayer.h" #include "arm_compute/runtime/CL/functions/CLStridedSlice.h" -#include "arm_compute/runtime/IFunction.h" namespace arm_compute { @@ -47,8 +43,16 @@ class ICLTensor; class CLPadLayer : public IFunction { public: - /** Default constructor*/ + /** Default constructor */ CLPadLayer(); + /** Prevent instances of this class from being copied (As this class contains pointers) */ + CLPadLayer(const CLPadLayer &) = delete; + /** Default move constructor */ + CLPadLayer(CLPadLayer &&) = default; + /** Prevent instances of this class from being copied (As this class contains pointers) */ + CLPadLayer &operator=(const CLPadLayer &) = delete; + /** Default move assignment operator */ + CLPadLayer &operator=(CLPadLayer &&) = default; /** Initialize the function * @@ -83,10 +87,10 @@ private: void configure_constant_mode(ICLTensor *input, ICLTensor *output, const PaddingList &padding, const PixelValue constant_value); void configure_reflect_symmetric_mode(ICLTensor *input, ICLTensor *output); + CLPadLayerKernel _pad_kernel; CLCopyKernel _copy_kernel; PaddingMode _mode; PaddingList _padding; - CLMemsetKernel _memset_kernel; size_t _num_dimensions; std::vector _slice_functions; std::vector _concat_functions; -- cgit v1.2.1