From d8804fdc4254f614e48296e5a4efef2833ba4163 Mon Sep 17 00:00:00 2001 From: Gian Marco Iodice Date: Tue, 28 Jun 2022 16:55:19 +0100 Subject: Fix OpenCL Winograd output transform - num_tiles_x was not initialized when we were passing the argument at compilation time Resolves COMPMID-5394 Change-Id: I6004a2d47656edda3c832f980c78622045de7068 Signed-off-by: Gian Marco Iodice Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/7857 Reviewed-by: Pablo Marquez Tello Comments-Addressed: Arm Jenkins Benchmark: Arm Jenkins Tested-by: Arm Jenkins --- src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp b/src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp index a664d1ec1d..632fd2636f 100644 --- a/src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp +++ b/src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp @@ -176,6 +176,8 @@ void ClWinogradOutputTransformKernel::configure(const ClCompileContext &compile_ build_opts.add_option("-DVEC_SIZE=4"); } + _num_tiles_x = num_tiles.width; + if(_is_nhwc) { build_opts.add_option_if(bias != nullptr, std::string("-DHAS_BIAS")); @@ -210,7 +212,6 @@ void ClWinogradOutputTransformKernel::configure(const ClCompileContext &compile_ _src_height = src->dimension(1); _dst_width = dst->dimension(idx_width); _dst_height = dst->dimension(idx_height); - _num_tiles_x = num_tiles.width; // Create kernel std::string kernel_name = "winograd_output_transform_" + output_tile_size.to_string() + "_" + kernel_size.to_string() + "_" + lower_string(string_from_data_layout(winograd_info.output_data_layout)); -- cgit v1.2.1