MCPcopy Create free account
hub / github.com/chc4/lineiform / function_inc_regalloc

Function function_inc_regalloc

tangle/src/ir.rs:268–281  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

266
267 #[test]
268 pub fn function_inc_regalloc() {
269 let mut ir = IR::new();
270 let mut f = Node::function::<1, 1>(&mut ir);
271 let port = f.add_argument(&mut ir);
272 let ret_port = f.add_return(&mut ir);
273 let mut inc = Node::simple(Operation::Inc);
274 f.add_body(inc, &mut ir, |inc, r| {
275 inc.connect_input(0, port, r);
276 inc.connect_output(0, ret_port, r);
277 });
278 ir.set_body(f);
279 ir.regalloc();
280 ir.validate();
281 }
282
283 #[test]
284 pub fn function_inc_codegen() {

Callers

nothing calls this directly

Calls 8

add_argumentMethod · 0.80
add_returnMethod · 0.80
add_bodyMethod · 0.80
connect_inputMethod · 0.80
connect_outputMethod · 0.80
set_bodyMethod · 0.80
regallocMethod · 0.80
validateMethod · 0.45

Tested by

no test coverage detected