From 04fd097fb51346f655c7bdc0c88b85e29359ef1c Mon Sep 17 00:00:00 2001 From: bd-912 Date: Sat, 20 Apr 2024 23:43:30 -0600 Subject: Non-function live-interval computation algorithm --- vaporize/tests/ex32.vaporm | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) (limited to 'vaporize/tests') diff --git a/vaporize/tests/ex32.vaporm b/vaporize/tests/ex32.vaporm index 85ecf13..7ef23aa 100644 --- a/vaporize/tests/ex32.vaporm +++ b/vaporize/tests/ex32.vaporm @@ -1,6 +1,12 @@ -func Main [in 0, out 0, local 0] - $t0 = HeapAllocZ(4) - [$t0] = :functable_A +func Main [in 0, out 0, local 4] + local[0] = $s0 + local[1] = $s1 + local[2] = $s2 + $s0 = HeapAllocZ(4) + local[3] = $s0 + $s0 = local[3] + [$s0] = :functable_A + $local[4] = $s0 $t1 = [$t0] $t2 = [$t1] $a0 = $t0 @@ -8,15 +14,22 @@ func Main [in 0, out 0, local 0] call $t2 $t1 = $v0 PrintIntS($t1) + $s0 = local[0] + $s1 = local[1] + $s2 = local[2] ret const functable_A :A_foo -func A_foo [in 0, out 0, local 1] +func A_foo [in 0, out 0, local 6] local[0] = $s0 + local[1] = $s1 + local[2] = $s2 $t0 = $a0 $s0 = $a1 $v0 = $s0 $s0 = local[0] + $s1 = local[1] + $s2 = local[2] ret -- cgit v1.2.3