diff options
author | Michele Di Giorgio <michele.digiorgio@arm.com> | 2018-04-13 14:28:08 +0100 |
---|---|---|
committer | Anthony Barbier <anthony.barbier@arm.com> | 2018-11-02 16:49:54 +0000 |
commit | 164b65d3c8f61f1d6d404fb484c1998a20a2cbda (patch) | |
tree | b60b9f49066ca8c008726dd193e4e0bd56ac1168 /arm_compute/runtime/GLES_COMPUTE/functions/GCGEMM.h | |
parent | 0cbb927ac309e332ac6e6f1ab9170f041f0138ab (diff) | |
download | ComputeLibrary-164b65d3c8f61f1d6d404fb484c1998a20a2cbda.tar.gz |
COMPMID-1043: Rework GCGEMMMatrixMultiplyKernel interface and allow auto initialization of the tensors
This patch also:
- removes support for already reshaped weights in GCConvolutionLayer
- makes GCConvolutionLayer similar to CLGEMMConvolutionLayer
- enables usage of the GCGEMM function in GCConvolution instead of calling the
GEMM kernels directly
Change-Id: I3e4a64335555e86e18585d38d8fda4bfdb44e265
Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/127696
Tested-by: Jenkins <bsgcomp@arm.com>
Reviewed-by: Anthony Barbier <anthony.barbier@arm.com>
Diffstat (limited to 'arm_compute/runtime/GLES_COMPUTE/functions/GCGEMM.h')
-rw-r--r-- | arm_compute/runtime/GLES_COMPUTE/functions/GCGEMM.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/arm_compute/runtime/GLES_COMPUTE/functions/GCGEMM.h b/arm_compute/runtime/GLES_COMPUTE/functions/GCGEMM.h index 31ad0abaa0..a1d6c8a438 100644 --- a/arm_compute/runtime/GLES_COMPUTE/functions/GCGEMM.h +++ b/arm_compute/runtime/GLES_COMPUTE/functions/GCGEMM.h @@ -69,6 +69,20 @@ public: * if the reshape of matrix B should happen only for the first run */ void configure(const IGCTensor *a, const IGCTensor *b, const IGCTensor *c, IGCTensor *output, float alpha, float beta, const GEMMInfo &gemm_info = GEMMInfo()); + /** Static function to check if given info will lead to a valid configuration of @ref GCGEMM. + * + * @param[in] a First input tensor (Matrix or Vector A). Data types supported: F16/F32 + * @param[in] b Second input tensor (Matrix B). Data type supported: same as @p a. + * @param[in] c Third input tensor (Matrix C). It can be a nullptr if just the multiplication between @p a and @p b is needed. Data type supported: same as @p a. + * @param[out] output Output tensor. Data type supported: same as @p a + * @param[in] alpha Weight of the matrix product + * @param[in] beta Weight of matrix C + * @param[in] gemm_info (Optional) Specifies if the matrix A and/or matrix B have been reshaped and + * if the reshape of matrix B should happen only for the first run + * + * @return a status + */ + static Status validate(const ITensorInfo *a, const ITensorInfo *b, const IGCTensor *c, const ITensorInfo *output, const float alpha, const float beta, const GEMMInfo &gemm_info = GEMMInfo()); // Inherited methods overridden: void run() override; @@ -83,6 +97,8 @@ private: GCTensor _tmp_b; bool _is_interleaved_transposed; bool _run_addition; + bool _is_first_run; + bool _reshape_b_only_on_first_run; }; } |