From db8485ac24135f17e9882c76196924435abc064f Mon Sep 17 00:00:00 2001 From: Pablo Tello Date: Tue, 24 Sep 2019 11:03:47 +0100 Subject: COMPMID-2205: CL runtime context. CL Interfaces implemented. Concrete classes implemented. One test (ActivationLayer) ported to the new interface. Change-Id: I283808bec36ccfc2f13fe048c45cbbee698ce525 Signed-off-by: Pablo Tello Reviewed-on: https://review.mlplatform.org/c/1998 Tested-by: Arm Jenkins Reviewed-by: Georgios Pinitas Comments-Addressed: Arm Jenkins --- arm_compute/runtime/CL/CLTensorAllocator.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'arm_compute/runtime/CL/CLTensorAllocator.h') diff --git a/arm_compute/runtime/CL/CLTensorAllocator.h b/arm_compute/runtime/CL/CLTensorAllocator.h index 3450c72d61..b3ffd8b949 100644 --- a/arm_compute/runtime/CL/CLTensorAllocator.h +++ b/arm_compute/runtime/CL/CLTensorAllocator.h @@ -37,7 +37,7 @@ namespace arm_compute { class CLTensor; - +class CLRuntimeContext; /** Basic implementation of a CL memory tensor allocator. */ class CLTensorAllocator : public ITensorAllocator { @@ -45,8 +45,9 @@ public: /** Default constructor. * * @param[in] owner (Optional) Owner of the allocator. + * @param[in] ctx (Optional) Runtime context. */ - CLTensorAllocator(IMemoryManageable *owner = nullptr); + CLTensorAllocator(IMemoryManageable *owner = nullptr, CLRuntimeContext *ctx = nullptr); /** Prevent instances of this class from being copied (As this class contains pointers) */ CLTensorAllocator(const CLTensorAllocator &) = delete; /** Prevent instances of this class from being copy assigned (As this class contains pointers) */ @@ -139,6 +140,7 @@ private: static const cl::Buffer _empty_buffer; private: + CLRuntimeContext *_ctx; IMemoryManageable *_owner; /**< Memory manageable object that owns the allocator */ IMemoryGroup *_associated_memory_group; /**< Registered memory manager */ CLMemory _memory; /**< OpenCL memory */ -- cgit v1.2.1