MCPcopy Create free account
hub / github.com/LPC4/Full-Stack / float_f64_negation

Function float_f64_negation

tests/integration/vm_execution.rs:2358–2375  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2356 );
2357 let (_, outcome, _) = run_ir(&program);
2358 assert!(
2359 matches!(outcome, RunOutcome::Halted(0)),
2360 "ult: 2 < 5 should be true, got {outcome:?}"
2361 );
2362}
2363
2364/// Signed less-than comparison via IR: -1 < 0 must be true with `Slt`.
2365#[test]
2366fn ir_cmp_slt_negative() {
2367 let i32_ty = IrType::Integer(IntWidth::I32);
2368 let mut entry = IrBlock::new("entry");
2369 entry.push_instruction(IrInstruction::Cmp {
2370 dest: IrRegister::Named("ok".into()),
2371 op: IrCmpOp::Slt,
2372 ty: i32_ty,
2373 lhs: IrValue::Integer(-1),
2374 rhs: IrValue::Integer(0),
2375 });
2376 let program = pass_fail_ir(
2377 "slt",
2378 entry,

Callers

nothing calls this directly

Calls 1

run_hllFunction · 0.70

Tested by

no test coverage detected