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 <gianmarco.iodice@arm.com>
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/7857
Reviewed-by: Pablo Marquez Tello <pablo.tello@arm.com>
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Benchmark: Arm Jenkins <bsgcomp@arm.com>
Tested-by: Arm Jenkins <bsgcomp@arm.com>
diff --git a/src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp b/src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp
index a664d1e..632fd26 100644
--- a/src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp
+++ b/src/gpu/cl/kernels/ClWinogradOutputTransformKernel.cpp
@@ -176,6 +176,8 @@
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 @@
_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));