aboutsummaryrefslogtreecommitdiff
path: root/src/core/CL/kernels/CLDirectConvolutionLayerKernel.cpp
diff options
context:
space:
mode:
authorGian Marco Iodice <gianmarco.iodice@arm.com>2021-02-01 14:37:02 +0000
committerTeresaARM <teresa.charlinreyes@arm.com>2021-02-03 22:04:13 +0000
commit0841ca085301e8ddbc9627b2be55758b66437c15 (patch)
tree346923c68946694ae164d890ee0e2d9346c9c39f /src/core/CL/kernels/CLDirectConvolutionLayerKernel.cpp
parent8d8a1c554d71e020526838bd65be0bb7fc9c8914 (diff)
downloadComputeLibrary-0841ca085301e8ddbc9627b2be55758b66437c15.tar.gz
Fix OpenCL direct convolution
- The ARM DOT macro was using wrong variables for performing the dot product - K0 could be a non power of 2 values when IFM was not a multiple of 16 - Refactor the test for direct convolution NHWC Resolves COMPMID-4135, COMPMID-4155 Change-Id: I3a2dc89ef613ae20245cfc28e76ea36c55eaf81d Signed-off-by: Gian Marco Iodice <gianmarco.iodice@arm.com> Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/4962 Comments-Addressed: Arm Jenkins <bsgcomp@arm.com> Reviewed-by: TeresaARM <teresa.charlinreyes@arm.com> Tested-by: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'src/core/CL/kernels/CLDirectConvolutionLayerKernel.cpp')
-rw-r--r--src/core/CL/kernels/CLDirectConvolutionLayerKernel.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/CL/kernels/CLDirectConvolutionLayerKernel.cpp b/src/core/CL/kernels/CLDirectConvolutionLayerKernel.cpp
index 3ca72b3e5d..3948261bc3 100644
--- a/src/core/CL/kernels/CLDirectConvolutionLayerKernel.cpp
+++ b/src/core/CL/kernels/CLDirectConvolutionLayerKernel.cpp
@@ -375,7 +375,7 @@ void CLDirectConvolutionLayerKernel::configure(const CLCompileContext &compile_c
const unsigned int n0 = win_config.second.x().step();
const unsigned int m0 = win_config.second.y().step();
- const unsigned int k0 = std::min(static_cast<unsigned int>(_input->info()->dimension(channel_idx)), 16u);
+ const unsigned int k0 = adjust_vec_size(16u, _input->info()->dimension(channel_idx));
const unsigned int partial_store_n0 = _output->info()->dimension(channel_idx) % n0;
const unsigned int partial_store_m0 = (_output->info()->dimension(width_idx) * _output->info()->dimension(height_idx)) % m0;
const unsigned int pad_left = conv_info.pad_left();