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

Method replace_instruction

src/module.cpp:329–341  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

327}
328
329instruction_ref module::replace_instruction(instruction_ref ins,
330 const operation& op,
331 std::vector<instruction_ref> args) MIGRAPHX_TIDY_CONST
332{
333 impl->changed.notify();
334 assert(has_instruction(ins));
335 assert(not starts_with(op.name(), "@"));
336
337 shape r = compute_shape(op, args);
338 instruction::replace(ins, op, r, std::move(args));
339 assert(ins->valid(begin()));
340 return ins;
341}
342
343instruction_ref module::replace_instruction(instruction_ref ins,
344 const operation& op,

Callers 15

TEST_CASEFunction · 0.80
applyMethod · 0.80
TEST_CASEFunction · 0.80
applyMethod · 0.80
applyMethod · 0.80
applyMethod · 0.80
remove_zero_pointFunction · 0.80
applyMethod · 0.80
cast_to_fnuzMethod · 0.80
apply_horizontal_finderFunction · 0.80
applyMethod · 0.80

Calls 15

endMethod · 0.95
starts_withFunction · 0.85
replaceFunction · 0.85
beginFunction · 0.85
replace_instructionFunction · 0.85
endFunction · 0.85
notifyMethod · 0.80
outputsMethod · 0.80
compute_shapeFunction · 0.70
make_opFunction · 0.70
all_ofFunction · 0.50
nameMethod · 0.45

Tested by 3

TEST_CASEFunction · 0.64
applyMethod · 0.64
TEST_CASEFunction · 0.64