From bef7fa27b0d231a8649952f60808132d109b6345 Mon Sep 17 00:00:00 2001 From: Sang-Hoon Park Date: Wed, 21 Oct 2020 15:58:54 +0100 Subject: COMPMID-3639: (3RDPARTY_UPDATE) Move CL kernels to src Change-Id: I10d27db788e5086adae1841e3e2441cd9b76ef84 Signed-off-by: Sang-Hoon Park Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/4310 Reviewed-by: Georgios Pinitas Comments-Addressed: Arm Jenkins Tested-by: Arm Jenkins --- .../runtime/CL/functions/CLMinMaxLocation.h | 28 +++++++++++++--------- 1 file changed, 17 insertions(+), 11 deletions(-) (limited to 'arm_compute/runtime/CL/functions/CLMinMaxLocation.h') diff --git a/arm_compute/runtime/CL/functions/CLMinMaxLocation.h b/arm_compute/runtime/CL/functions/CLMinMaxLocation.h index 04926f7bd0..4e3f28b006 100644 --- a/arm_compute/runtime/CL/functions/CLMinMaxLocation.h +++ b/arm_compute/runtime/CL/functions/CLMinMaxLocation.h @@ -24,12 +24,16 @@ #ifndef ARM_COMPUTE_CLMINMAXLOCATION_H #define ARM_COMPUTE_CLMINMAXLOCATION_H -#include "arm_compute/core/CL/kernels/CLMinMaxLocationKernel.h" #include "arm_compute/runtime/CL/CLArray.h" #include "arm_compute/runtime/IFunction.h" +#include + namespace arm_compute { +class CLCompileContext; +class CLMinMaxKernel; +class CLMinMaxLocationKernel; class ICLTensor; using ICLImage = ICLTensor; @@ -51,6 +55,8 @@ public: CLMinMaxLocation(CLMinMaxLocation &&) = default; /** Allow instances of this class to be moved */ CLMinMaxLocation &operator=(CLMinMaxLocation &&) = default; + /** Default destructor */ + ~CLMinMaxLocation(); /** Initialise the kernel's inputs and outputs. * * @note When locations of min and max occurrences are requested, the reported number of locations is limited to the given array size. @@ -87,16 +93,16 @@ public: void run() override; private: - CLMinMaxKernel _min_max_kernel; /**< Kernel that performs min/max */ - CLMinMaxLocationKernel _min_max_loc_kernel; /**< Kernel that counts min/max occurrences and identifies their positions */ - cl::Buffer _min_max_vals; /**< Buffer to collect min, max values */ - cl::Buffer _min_max_count_vals; /**< Buffer to collect min, max values */ - void *_min; /**< Minimum value. */ - void *_max; /**< Maximum value. */ - uint32_t *_min_count; /**< Minimum value occurrences. */ - uint32_t *_max_count; /**< Maximum value occurrences. */ - CLCoordinates2DArray *_min_loc; /**< Minimum value occurrences coordinates. */ - CLCoordinates2DArray *_max_loc; /**< Maximum value occurrences coordinates. */ + std::unique_ptr _min_max_kernel; /**< Kernel that performs min/max */ + std::unique_ptr _min_max_loc_kernel; /**< Kernel that counts min/max occurrences and identifies their positions */ + cl::Buffer _min_max_vals; /**< Buffer to collect min, max values */ + cl::Buffer _min_max_count_vals; /**< Buffer to collect min, max values */ + void *_min; /**< Minimum value. */ + void *_max; /**< Maximum value. */ + uint32_t *_min_count; /**< Minimum value occurrences. */ + uint32_t *_max_count; /**< Maximum value occurrences. */ + CLCoordinates2DArray *_min_loc; /**< Minimum value occurrences coordinates. */ + CLCoordinates2DArray *_max_loc; /**< Maximum value occurrences coordinates. */ }; } #endif /*ARM_COMPUTE_CLMINMAXLOCATION_H */ -- cgit v1.2.1