diff --git a/backends/vulkan/runtime/graph/ops/glsl/conv2d_dw_output_tile.yaml b/backends/vulkan/runtime/graph/ops/glsl/conv2d_dw_output_tile.yaml index 19cacdef178..3dbdb802796 100644 --- a/backends/vulkan/runtime/graph/ops/glsl/conv2d_dw_output_tile.yaml +++ b/backends/vulkan/runtime/graph/ops/glsl/conv2d_dw_output_tile.yaml @@ -32,3 +32,12 @@ conv2d_dw_output_tile: OPERATOR: clamp(X, A, B) BATCH_SIZE_X: 1 BATCH_SIZE_Y: 1 + - NAME: conv2d_dw_output_tile_5x5_b1x1 + TILE_SIZE: 5 + BATCH_SIZE_X: 1 + BATCH_SIZE_Y: 1 + - NAME: conv2d_dw_output_tile_5x5_b1x1_clamp + OPERATOR: clamp(X, A, B) + TILE_SIZE: 5 + BATCH_SIZE_X: 1 + BATCH_SIZE_Y: 1 diff --git a/backends/vulkan/runtime/graph/ops/impl/Conv2dDW.cpp b/backends/vulkan/runtime/graph/ops/impl/Conv2dDW.cpp index a9d8483b2e2..74649051635 100644 --- a/backends/vulkan/runtime/graph/ops/impl/Conv2dDW.cpp +++ b/backends/vulkan/runtime/graph/ops/impl/Conv2dDW.cpp @@ -81,13 +81,13 @@ std::string pick_conv2d_dw_shader( kernel_name += "_sned"; } - if (is_3x3) { - kernel_name += "_output_tile_3x3"; + if (is_3x3 || is_5x5) { + kernel_name += is_3x3 ? "_output_tile_3x3" : "_output_tile_5x5"; + // Mali spills with the default 4x2 output tile: each invocation holds 8 + // accumulators and loads an overlapping input window for each of them. if (stride_equals_dilation && graph.device_is_mali()) { kernel_name += "_b1x1"; } - } else if (is_5x5) { - kernel_name += "_output_tile_5x5"; } if (clamp_out) {