aboutsummaryrefslogtreecommitdiff
path: root/test/logical-and.qbe
blob: b827bca5f0bf4b08dea41475663a28385abd332a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
export
function w $main() {
@start.1
@body.2
	%.1 =w loadw $i
	jnz %.1, @logic_right.3, @logic_join.4
@logic_right.3
	%.2 =w cnew 1, 0
@logic_join.4
	%.3 =w phi @body.2 0, @logic_right.3 %.2
	jnz %.3, @if_true.5, @if_false.6
@if_true.5
	ret 1
@if_false.6
	%.4 =s loads $f
	%.5 =w cnes %.4, s_0
	jnz %.5, @logic_right.7, @logic_join.8
@logic_right.7
	%.6 =w cnew 1, 0
@logic_join.8
	%.7 =w phi @if_false.6 0, @logic_right.7 %.6
	jnz %.7, @if_true.9, @if_false.10
@if_true.9
	ret 1
@if_false.10
	%.8 =l loadl $p
	%.9 =w cnel %.8, 0
	jnz %.9, @logic_right.11, @logic_join.12
@logic_right.11
	%.10 =w cnew 1, 0
@logic_join.12
	%.11 =w phi @if_false.10 0, @logic_right.11 %.10
	jnz %.11, @if_true.13, @if_false.14
@if_true.13
	ret 1
@if_false.14
	ret 0
}
export data $i = align 4 { z 4 }
export data $f = align 4 { z 4 }
export data $p = align 8 { z 8 }