aboutsummaryrefslogtreecommitdiff
path: root/test/gvn1.ssa
blob: d47f05b0f5071653a103aec25180d53b559d1125 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
export
function w $test(w %p1, w %p2) {
@start
@entry
	%t1 =w copy 1
	jnz %t1, @live, @dead1
@live
	%t2 =w add %p1, %p2
	ret %t2
@dead1
	%t2 =w add %p1, %p2  # live ins in dead blk
@dead2
	jnz %t1, @live, @dead1
}

# >>> driver
# extern int test(int p1, int p2);
# int main() { return test(1, 2) != 3; }
# <<<