Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion tests/test-backend-ops.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1454,13 +1454,20 @@ struct test_case {
ggml_context_ptr ctx(ggml_init(params)); // smart ptr
GGML_ASSERT(ctx);

gf = ggml_new_graph_custom(ctx.get(), graph_nodes, false);

ggml_tensor * out = build_graph(ctx.get());
current_op_name = op_desc(out);

if (!matches_filter(out, op_names_filter)) {
return true;
}

// Filter out fusion tests in support mode
if (run_whole_graph()) {
return true;
}

bool supported = ggml_backend_supports_op(backend, out);

std::string device_desc = ggml_backend_dev_description(ggml_backend_get_device(backend));
Expand Down Expand Up @@ -4844,7 +4851,9 @@ struct test_moe_expert_reduce : public test_case {

std::string name = "expert_view_" + std::to_string(i);
ggml_set_name(expert_views[i], name.c_str());
ggml_build_forward_expand(gf, expert_views[i]);
if (gf) {
ggml_build_forward_expand(gf, expert_views[i]);
}
}

ggml_tensor * moe_out = expert_views[0];
Expand Down
Loading