blob: 868e715cb364421519d57645e227ec891d763f56 (
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
|
func Main()
t.3 = HeapAllocZ(24)
[t.3+0] = :functable_LS
t.4 = t.3
t.5 = [t.4+0]
t.6 = [t.5+0]
t.7 = 10
t.2 = call t.6(t.4 t.7)
t.8 = t.2
PrintIntS(t.8)
ret
const functable_LS
:LS_Start
:LS_Print
:LS_Search
:LS_Init
func LS_Start(this t.0 )
t.3 = [this]
t.4 = t.0
t.3 = [t.3+12]
t.2 = call t.3(this t.4)
t.1 = t.2
t.7 = [this]
t.7 = [t.7+4]
t.6 = call t.7(this )
t.5 = t.6
t.8 = 9999
PrintIntS(t.8)
t.10 = [this]
t.11 = 8
t.10 = [t.10+8]
t.9 = call t.10(this t.11)
t.12 = t.9
PrintIntS(t.12)
t.14 = [this]
t.15 = 12
t.14 = [t.14+8]
t.13 = call t.14(this t.15)
t.16 = t.13
PrintIntS(t.16)
t.18 = [this]
t.19 = 17
t.18 = [t.18+8]
t.17 = call t.18(this t.19)
t.20 = t.17
PrintIntS(t.20)
t.22 = [this]
t.23 = 50
t.22 = [t.22+8]
t.21 = call t.22(this t.23)
t.24 = t.21
PrintIntS(t.24)
t.25 = 55
ret t.25
func LS_Print(this )
t.0 = 1
while29_test:
t.2 = t.0
t.3 = [this+20]
t.1 = LtS(t.2 t.3)
t.4 = t.1
if0 t.4 goto :while29_end
while29_body:
t.6 = [this+16]
t.7 = MulS(t.0 4)
t.7 = Add(t.7 4)
t.7 = Add(t.6 t.7)
t.5 = [t.7]
t.8 = t.5
PrintIntS(t.8)
t.10 = t.0
t.11 = 1
t.9 = Add(t.10 t.11)
t.0 = t.9
goto :while29_test
while29_end:
t.12 = 0
ret t.12
func LS_Search(this t.0 )
t.1 = 1
t.2 = 0
t.3 = 0
while42_test:
t.5 = t.1
t.6 = [this+20]
t.4 = LtS(t.5 t.6)
t.7 = t.4
if0 t.7 goto :while42_end
while42_body:
t.10 = [this+16]
t.11 = MulS(t.1 4)
t.11 = Add(t.11 4)
t.11 = Add(t.10 t.11)
t.9 = [t.11]
t.8 = t.9
t.14 = t.0
t.15 = 1
t.13 = Add(t.14 t.15)
t.12 = t.13
t.17 = t.8
t.18 = t.0
t.16 = LtS(t.17 t.18)
t.19 = t.16
if0 t.19 goto :if53_else
if53_body:
t.20 = 0
goto :if53_end
if53_else:
t.23 = t.8
t.24 = t.12
t.22 = LtS(t.23 t.24)
t.21 = Eq(t.22 0)
t.25 = t.21
if0 t.25 goto :if57_else
if57_body:
t.20 = 0
goto :if57_end
if57_else:
t.2 = 1
t.3 = 1
t.1 = [this+20]
if57_end:
if53_end:
t.27 = t.1
t.28 = 1
t.26 = Add(t.27 t.28)
t.1 = t.26
goto :while42_test
while42_end:
t.29 = t.3
ret t.29
func LS_Init(this t.0 )
[this+20] = t.0
t.1 = call :AllocArray(t.0)
[this+16] = t.1
t.2 = 1
t.5 = [this+20]
t.6 = 1
t.4 = Add(t.5 t.6)
t.3 = t.4
while70_test:
t.8 = t.2
t.9 = [this+20]
t.7 = LtS(t.8 t.9)
t.10 = t.7
if0 t.10 goto :while70_end
while70_body:
t.13 = 2
t.14 = t.2
t.12 = MulS(t.13 t.14)
t.11 = t.12
t.17 = t.3
t.18 = 3
t.16 = Sub(t.17 t.18)
t.15 = t.16
t.19 = [this+16]
t.20 = MulS(t.2 4)
t.20 = Add(t.20 4)
t.20 = Add(t.19 t.20)
t.22 = t.11
t.23 = t.15
t.21 = Add(t.22 t.23)
[t.20] = t.21
t.25 = t.2
t.26 = 1
t.24 = Add(t.25 t.26)
t.2 = t.24
t.28 = t.3
t.29 = 1
t.27 = Sub(t.28 t.29)
t.3 = t.27
goto :while70_test
while70_end:
t.30 = 0
ret t.30
func AllocArray(size)
bytes = MulS(size 4)
bytes = Add(bytes 4)
v = HeapAllocZ(bytes)
[v] = size
ret v
|