diff options
Diffstat (limited to 'arm_compute/runtime/CL/functions/CLTranspose.h')
-rw-r--r-- | arm_compute/runtime/CL/functions/CLTranspose.h | 46 |
1 files changed, 37 insertions, 9 deletions
diff --git a/arm_compute/runtime/CL/functions/CLTranspose.h b/arm_compute/runtime/CL/functions/CLTranspose.h index b2fdcda5c4..9dc977fbeb 100644 --- a/arm_compute/runtime/CL/functions/CLTranspose.h +++ b/arm_compute/runtime/CL/functions/CLTranspose.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017-2020 ARM Limited. + * Copyright (c) 2017-2021 Arm Limited. * * SPDX-License-Identifier: MIT * @@ -24,22 +24,43 @@ #ifndef ARM_COMPUTE_CLTRANSPOSE_H #define ARM_COMPUTE_CLTRANSPOSE_H -#include "arm_compute/runtime/CL/ICLSimpleFunction.h" +#include "arm_compute/core/Error.h" +#include "arm_compute/runtime/IFunction.h" + +#include <memory> namespace arm_compute { +class CLCompileContext; class ICLTensor; +class ITensorInfo; -/** Basic function to transpose a matrix on OpenCL. This function calls the following OpenCL kernel: - * - * -# @ref CLTransposeKernel - * - */ -class CLTranspose : public ICLSimpleFunction +/** Basic function to execute an @ref opencl::kernels::ClTransposeKernel. */ +class CLTranspose : public IFunction { public: + /** Constructor */ + CLTranspose(); + /** Destructor */ + ~CLTranspose(); + /** Prevent instances of this class from being copied (As this class contains pointers) */ + CLTranspose(const CLTranspose &) = delete; + /** Default move constructor */ + CLTranspose(CLTranspose &&) = default; + /** Prevent instances of this class from being copied (As this class contains pointers) */ + CLTranspose &operator=(const CLTranspose &) = delete; + /** Default move assignment operator */ + CLTranspose &operator=(CLTranspose &&) = default; /** Initialise the kernel's inputs and output * + * Valid data layouts: + * - All + * + * Valid data type configurations: + * |src |dst | + * |:--------------|:--------------| + * |All |All | + * * @param[in] input Input tensor. Data types supported: All. * @param[out] output Output tensor. Data type supported: Same as @p input */ @@ -59,7 +80,14 @@ public: * @return a status */ static Status validate(const ITensorInfo *input, const ITensorInfo *output); + + // Inherited methods overridden: + void run() override; + +private: + struct Impl; + std::unique_ptr<Impl> _impl; }; -} +} // namespace arm_compute #endif /* ARM_COMPUTE_CLTRANSPOSE_H */ |