Skip to content

Commit d1109c4

Browse files
committed
opencl : merge empty node and noop checks
1 parent c4936a2 commit d1109c4

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

ggml/src/ggml-opencl/ggml-opencl.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2187,11 +2187,7 @@ static ggml_status ggml_backend_opencl_graph_compute(ggml_backend_t backend, ggm
21872187
// dependencies.
21882188
sync_with_other_backends(backend);
21892189

2190-
if (ggml_is_empty(node)) {
2191-
continue;
2192-
}
2193-
2194-
if (node->op == GGML_OP_RESHAPE || node->op == GGML_OP_TRANSPOSE || node->op == GGML_OP_VIEW || node->op == GGML_OP_PERMUTE || node->op == GGML_OP_NONE) {
2190+
if (ggml_is_empty(node) || node->op == GGML_OP_RESHAPE || node->op == GGML_OP_TRANSPOSE || node->op == GGML_OP_VIEW || node->op == GGML_OP_PERMUTE || node->op == GGML_OP_NONE) {
21952191
continue;
21962192
}
21972193

0 commit comments

Comments
 (0)