Skip to content

Commit 2c10f1c

Browse files
use vector empty instead of size
Co-authored-by: Johannes Gäßler <[email protected]>
1 parent e765d9a commit 2c10f1c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ggml/src/ggml-cuda/moe-expert-reduce.cu

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ bool ggml_cuda_should_use_moe_expert_reduce(const ggml_cgraph * cgraph, int star
121121
}
122122

123123
//check if all the adds are in increasing order
124-
const ggml_tensor * prev_add_src = view_nodes.size() ? view_nodes[0] : nullptr;
124+
const ggml_tensor * prev_add_src = view_nodes.empty() ? nullptr : view_nodes[0];
125125
int num_adds = 0;
126126
int num_views = view_nodes.size();
127127
while (current_node < end_index && cgraph->nodes[current_node]->op == GGML_OP_ADD) {

0 commit comments

Comments
 (0)