Skip to content

Commit a186173

Browse files
committed
reset hash table in ggml_build_forward
1 parent c3a979e commit a186173

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/ggml.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18304,6 +18304,7 @@ static void ggml_build_forward_impl(struct ggml_cgraph * cgraph, struct ggml_ten
1830418304
if (!expand) {
1830518305
cgraph->n_nodes = 0;
1830618306
cgraph->n_leafs = 0;
18307+
memset(cgraph->visited_hash_table.keys, 0, cgraph->visited_hash_table.size * sizeof(struct ggml_tensor *));
1830718308
}
1830818309

1830918310
const int n0 = cgraph->n_nodes;

0 commit comments

Comments
 (0)