MCPcopy Create free account
hub / github.com/ROCm/AMDMIGraphX / create_program

Function create_program

test/print_graph_test.cpp:30–44  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28#include <basic_ops.hpp>
29
30static migraphx::program create_program()
31{
32 migraphx::program p;
33
34 auto* mm = p.get_main_module();
35
36 auto x = mm->add_parameter("x", {migraphx::shape::int64_type});
37 auto y = mm->add_parameter("y", {migraphx::shape::int64_type});
38
39 auto sum = mm->add_instruction(sum_op{}, x, y);
40 auto one = mm->add_literal(1);
41 mm->add_instruction(sum_op{}, sum, one);
42
43 return p;
44}
45
46TEST_CASE(basic_graph_test)
47{

Callers 1

TEST_CASEFunction · 0.70

Calls 4

get_main_moduleMethod · 0.80
add_parameterMethod · 0.80
add_instructionMethod · 0.45
add_literalMethod · 0.45

Tested by

no test coverage detected