Skip to content

Commit 77dee9d

Browse files
danbevslarenCISC
authored
ggml : WebGPU add TRANSPOSE and RESHAPE to supported ops (ggml-org#15695)
* ggml : WebGPU add TRANSPOSE and RESHAPE to supported ops This commit adds support for the TRANSPOSE and RESHAPE operations in the ggml webgpu backend. Co-authored-by: Diego Devesa <[email protected]> Co-authored-by: Sigbjørn Skjæret <[email protected]>
1 parent 4795c91 commit 77dee9d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

ggml/src/ggml-webgpu/ggml-webgpu.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -611,6 +611,8 @@ static bool ggml_webgpu_encode_node(webgpu_context ctx, ggml_tensor * node) {
611611
case GGML_OP_NONE:
612612
case GGML_OP_VIEW:
613613
case GGML_OP_PERMUTE:
614+
case GGML_OP_TRANSPOSE:
615+
case GGML_OP_RESHAPE:
614616
return false;
615617
case GGML_OP_CPY:
616618
{
@@ -1062,6 +1064,8 @@ static bool ggml_backend_webgpu_device_supports_op(ggml_backend_dev_t dev, const
10621064
case GGML_OP_NONE:
10631065
case GGML_OP_VIEW:
10641066
case GGML_OP_PERMUTE:
1067+
case GGML_OP_TRANSPOSE:
1068+
case GGML_OP_RESHAPE:
10651069
return true;
10661070
case GGML_OP_CPY:
10671071
case GGML_OP_SET_ROWS:

0 commit comments

Comments
 (0)