kumi 0.0.22 → 0.0.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/README.md +60 -116
- data/golden/array_element/expected/schema_ruby.rb +1 -1
- data/golden/array_index/expected/schema_ruby.rb +1 -1
- data/golden/array_operations/expected/schema_ruby.rb +1 -1
- data/golden/cascade_logic/expected/schema_ruby.rb +1 -1
- data/golden/chained_fusion/expected/schema_ruby.rb +1 -1
- data/golden/element_arrays/expected/schema_ruby.rb +1 -1
- data/golden/empty_and_null_inputs/expected/schema_ruby.rb +1 -1
- data/golden/game_of_life/expected/lir_00_unoptimized.txt +33 -33
- data/golden/game_of_life/expected/lir_01_hoist_scalar_references.txt +33 -33
- data/golden/game_of_life/expected/lir_02_inlined.txt +296 -296
- data/golden/game_of_life/expected/lir_03_cse.txt +128 -128
- data/golden/game_of_life/expected/lir_04_1_loop_fusion.txt +128 -128
- data/golden/game_of_life/expected/lir_04_loop_invcm.txt +128 -128
- data/golden/game_of_life/expected/lir_06_const_prop.txt +128 -128
- data/golden/game_of_life/expected/schema_ruby.rb +1 -1
- data/golden/hash_keys/expected/schema_ruby.rb +1 -1
- data/golden/hash_keys/schema.kumi +4 -5
- data/golden/hash_value/expected/schema_ruby.rb +1 -1
- data/golden/hierarchical_complex/expected/schema_ruby.rb +1 -1
- data/golden/inline_rename_scope_leak/expected/ast.txt +48 -0
- data/golden/inline_rename_scope_leak/expected/input_plan.txt +10 -0
- data/golden/inline_rename_scope_leak/expected/lir_00_unoptimized.txt +35 -0
- data/golden/inline_rename_scope_leak/expected/lir_01_hoist_scalar_references.txt +35 -0
- data/golden/inline_rename_scope_leak/expected/lir_02_inlined.txt +49 -0
- data/golden/inline_rename_scope_leak/expected/lir_03_cse.txt +49 -0
- data/golden/inline_rename_scope_leak/expected/lir_04_1_loop_fusion.txt +49 -0
- data/golden/inline_rename_scope_leak/expected/lir_04_loop_invcm.txt +49 -0
- data/golden/inline_rename_scope_leak/expected/lir_06_const_prop.txt +49 -0
- data/golden/inline_rename_scope_leak/expected/nast.txt +31 -0
- data/golden/inline_rename_scope_leak/expected/schema_javascript.mjs +51 -0
- data/golden/inline_rename_scope_leak/expected/schema_ruby.rb +82 -0
- data/golden/inline_rename_scope_leak/expected/snast.txt +31 -0
- data/golden/inline_rename_scope_leak/expected.json +7 -0
- data/golden/inline_rename_scope_leak/input.json +4 -0
- data/golden/inline_rename_scope_leak/schema.kumi +24 -0
- data/golden/input_reference/expected/schema_ruby.rb +1 -1
- data/golden/interleaved_fusion/expected/schema_ruby.rb +1 -1
- data/golden/let_inline/expected/schema_ruby.rb +1 -1
- data/golden/loop_fusion/expected/schema_ruby.rb +1 -1
- data/golden/min_reduce_scope/expected/schema_ruby.rb +1 -1
- data/golden/mixed_dimensions/expected/schema_ruby.rb +1 -1
- data/golden/multirank_hoisting/expected/schema_ruby.rb +1 -1
- data/golden/nested_hash/expected/schema_ruby.rb +1 -1
- data/golden/reduction_broadcast/expected/schema_ruby.rb +1 -1
- data/golden/roll/expected/lir_00_unoptimized.txt +8 -8
- data/golden/roll/expected/lir_01_hoist_scalar_references.txt +8 -8
- data/golden/roll/expected/lir_02_inlined.txt +8 -8
- data/golden/roll/expected/lir_03_cse.txt +8 -8
- data/golden/roll/expected/lir_04_1_loop_fusion.txt +8 -8
- data/golden/roll/expected/lir_04_loop_invcm.txt +8 -8
- data/golden/roll/expected/lir_06_const_prop.txt +8 -8
- data/golden/roll/expected/schema_ruby.rb +1 -1
- data/golden/shift/expected/lir_00_unoptimized.txt +12 -12
- data/golden/shift/expected/lir_01_hoist_scalar_references.txt +12 -12
- data/golden/shift/expected/lir_02_inlined.txt +12 -12
- data/golden/shift/expected/lir_03_cse.txt +12 -12
- data/golden/shift/expected/lir_04_1_loop_fusion.txt +12 -12
- data/golden/shift/expected/lir_04_loop_invcm.txt +12 -12
- data/golden/shift/expected/lir_06_const_prop.txt +12 -12
- data/golden/shift/expected/schema_ruby.rb +1 -1
- data/golden/shift_2d/expected/lir_00_unoptimized.txt +48 -48
- data/golden/shift_2d/expected/lir_01_hoist_scalar_references.txt +48 -48
- data/golden/shift_2d/expected/lir_02_inlined.txt +48 -48
- data/golden/shift_2d/expected/lir_03_cse.txt +48 -48
- data/golden/shift_2d/expected/lir_04_1_loop_fusion.txt +48 -48
- data/golden/shift_2d/expected/lir_04_loop_invcm.txt +48 -48
- data/golden/shift_2d/expected/lir_06_const_prop.txt +48 -48
- data/golden/shift_2d/expected/schema_ruby.rb +1 -1
- data/golden/simple_math/expected/schema_ruby.rb +1 -1
- data/golden/streaming_basics/expected/schema_ruby.rb +1 -1
- data/golden/tuples/expected/lir_00_unoptimized.txt +4 -4
- data/golden/tuples/expected/lir_01_hoist_scalar_references.txt +4 -4
- data/golden/tuples/expected/lir_02_inlined.txt +4 -4
- data/golden/tuples/expected/lir_03_cse.txt +4 -4
- data/golden/tuples/expected/lir_04_1_loop_fusion.txt +4 -4
- data/golden/tuples/expected/lir_04_loop_invcm.txt +4 -4
- data/golden/tuples/expected/lir_06_const_prop.txt +4 -4
- data/golden/tuples/expected/schema_ruby.rb +1 -1
- data/golden/tuples_and_arrays/expected/lir_00_unoptimized.txt +1 -1
- data/golden/tuples_and_arrays/expected/lir_01_hoist_scalar_references.txt +1 -1
- data/golden/tuples_and_arrays/expected/lir_02_inlined.txt +2 -2
- data/golden/tuples_and_arrays/expected/lir_03_cse.txt +2 -2
- data/golden/tuples_and_arrays/expected/lir_04_1_loop_fusion.txt +2 -2
- data/golden/tuples_and_arrays/expected/lir_04_loop_invcm.txt +2 -2
- data/golden/tuples_and_arrays/expected/lir_06_const_prop.txt +2 -2
- data/golden/tuples_and_arrays/expected/schema_ruby.rb +1 -1
- data/golden/us_tax_2024/expected/ast.txt +865 -0
- data/golden/us_tax_2024/expected/input_plan.txt +61 -0
- data/golden/us_tax_2024/expected/lir_00_unoptimized.txt +901 -0
- data/golden/us_tax_2024/expected/lir_01_hoist_scalar_references.txt +901 -0
- data/golden/us_tax_2024/expected/lir_02_inlined.txt +5178 -0
- data/golden/us_tax_2024/expected/lir_03_cse.txt +2499 -0
- data/golden/us_tax_2024/expected/lir_04_1_loop_fusion.txt +2519 -0
- data/golden/us_tax_2024/expected/lir_04_loop_invcm.txt +2439 -0
- data/golden/us_tax_2024/expected/lir_06_const_prop.txt +2439 -0
- data/golden/us_tax_2024/expected/nast.txt +976 -0
- data/golden/us_tax_2024/expected/schema_javascript.mjs +584 -0
- data/golden/us_tax_2024/expected/schema_ruby.rb +639 -0
- data/golden/us_tax_2024/expected/snast.txt +976 -0
- data/golden/us_tax_2024/expected.json +1 -0
- data/golden/us_tax_2024/input.json +168 -0
- data/golden/us_tax_2024/schema.kumi +203 -0
- data/golden/with_constants/expected/schema_ruby.rb +1 -1
- data/lib/kumi/core/analyzer/passes/lir/inline_declarations_pass.rb +181 -105
- data/lib/kumi/core/analyzer/passes/output_schema_pass.rb +6 -4
- data/lib/kumi/core/functions/function_spec.rb +14 -8
- data/lib/kumi/core/functions/loader.rb +1 -1
- data/lib/kumi/version.rb +1 -1
- metadata +33 -1
@@ -9,7 +9,7 @@
|
|
9
9
|
)
|
10
10
|
(Declaration n
|
11
11
|
%t6 = load_input "rows" :: array
|
12
|
-
%t11 =
|
12
|
+
%t11 = length %t6 :: integer
|
13
13
|
%t12 = const -1 :: integer
|
14
14
|
%t14 = const 0 :: integer
|
15
15
|
%t18 = const 1 :: integer
|
@@ -20,13 +20,13 @@
|
|
20
20
|
%t16 = call core.lt(%t13, %t11) :: boolean
|
21
21
|
%t21 = call core.clamp(%t13, %t14, %t19) :: integer
|
22
22
|
%t17 = call core.and(%t15, %t16) :: boolean
|
23
|
-
%t22 =
|
24
|
-
%t23 =
|
23
|
+
%t22 = gather %t6, %t21 :: any
|
24
|
+
%t23 = length %t22 :: integer
|
25
25
|
loop col id=L4 in %rows_el_7 as el=%col_el_9, idx=%col_i_10
|
26
26
|
%t24 = call core.mod(%col_i_10, %t23) :: integer
|
27
27
|
%t25 = call core.add(%t24, %t23) :: integer
|
28
28
|
%t26 = call core.mod(%t25, %t23) :: integer
|
29
|
-
%t27 =
|
29
|
+
%t27 = gather %t22, %t26 :: integer
|
30
30
|
%t29 = select %t17, %t27, %t14 :: integer
|
31
31
|
yield %t29
|
32
32
|
end_loop
|
@@ -34,7 +34,7 @@
|
|
34
34
|
)
|
35
35
|
(Declaration s
|
36
36
|
%t30 = load_input "rows" :: array
|
37
|
-
%t35 =
|
37
|
+
%t35 = length %t30 :: integer
|
38
38
|
%t36 = const 1 :: integer
|
39
39
|
%t38 = const 0 :: integer
|
40
40
|
%t43 = call core.sub(%t35, %t36) :: integer
|
@@ -44,13 +44,13 @@
|
|
44
44
|
%t40 = call core.lt(%t37, %t35) :: boolean
|
45
45
|
%t45 = call core.clamp(%t37, %t38, %t43) :: integer
|
46
46
|
%t41 = call core.and(%t39, %t40) :: boolean
|
47
|
-
%t46 =
|
48
|
-
%t47 =
|
47
|
+
%t46 = gather %t30, %t45 :: any
|
48
|
+
%t47 = length %t46 :: integer
|
49
49
|
loop col id=L6 in %rows_el_31 as el=%col_el_33, idx=%col_i_34
|
50
50
|
%t48 = call core.mod(%col_i_34, %t47) :: integer
|
51
51
|
%t49 = call core.add(%t48, %t47) :: integer
|
52
52
|
%t50 = call core.mod(%t49, %t47) :: integer
|
53
|
-
%t51 =
|
53
|
+
%t51 = gather %t46, %t50 :: integer
|
54
54
|
%t53 = select %t41, %t51, %t38 :: integer
|
55
55
|
yield %t53
|
56
56
|
end_loop
|
@@ -58,7 +58,7 @@
|
|
58
58
|
)
|
59
59
|
(Declaration w
|
60
60
|
%t54 = load_input "rows" :: array
|
61
|
-
%t59 =
|
61
|
+
%t59 = length %t54 :: integer
|
62
62
|
%t65 = const -1 :: integer
|
63
63
|
%t67 = const 0 :: integer
|
64
64
|
%t71 = const 1 :: integer
|
@@ -66,8 +66,8 @@
|
|
66
66
|
%t60 = call core.mod(%rows_i_56, %t59) :: integer
|
67
67
|
%t61 = call core.add(%t60, %t59) :: integer
|
68
68
|
%t62 = call core.mod(%t61, %t59) :: integer
|
69
|
-
%t63 =
|
70
|
-
%t64 =
|
69
|
+
%t63 = gather %t54, %t62 :: any
|
70
|
+
%t64 = length %t63 :: integer
|
71
71
|
%t72 = call core.sub(%t64, %t71) :: integer
|
72
72
|
loop col id=L8 in %rows_el_55 as el=%col_el_57, idx=%col_i_58
|
73
73
|
%t66 = call core.sub(%col_i_58, %t65) :: integer
|
@@ -75,7 +75,7 @@
|
|
75
75
|
%t69 = call core.lt(%t66, %t64) :: boolean
|
76
76
|
%t70 = call core.and(%t68, %t69) :: boolean
|
77
77
|
%t74 = call core.clamp(%t66, %t67, %t72) :: integer
|
78
|
-
%t75 =
|
78
|
+
%t75 = gather %t63, %t74 :: integer
|
79
79
|
%t77 = select %t70, %t75, %t67 :: integer
|
80
80
|
yield %t77
|
81
81
|
end_loop
|
@@ -83,15 +83,15 @@
|
|
83
83
|
)
|
84
84
|
(Declaration e
|
85
85
|
%t78 = load_input "rows" :: array
|
86
|
-
%t83 =
|
86
|
+
%t83 = length %t78 :: integer
|
87
87
|
%t89 = const 1 :: integer
|
88
88
|
%t91 = const 0 :: integer
|
89
89
|
loop rows id=L9 in %t78 as el=%rows_el_79, idx=%rows_i_80
|
90
90
|
%t84 = call core.mod(%rows_i_80, %t83) :: integer
|
91
91
|
%t85 = call core.add(%t84, %t83) :: integer
|
92
92
|
%t86 = call core.mod(%t85, %t83) :: integer
|
93
|
-
%t87 =
|
94
|
-
%t88 =
|
93
|
+
%t87 = gather %t78, %t86 :: any
|
94
|
+
%t88 = length %t87 :: integer
|
95
95
|
%t96 = call core.sub(%t88, %t89) :: integer
|
96
96
|
loop col id=L10 in %rows_el_79 as el=%col_el_81, idx=%col_i_82
|
97
97
|
%t90 = call core.sub(%col_i_82, %t89) :: integer
|
@@ -99,7 +99,7 @@
|
|
99
99
|
%t93 = call core.lt(%t90, %t88) :: boolean
|
100
100
|
%t94 = call core.and(%t92, %t93) :: boolean
|
101
101
|
%t98 = call core.clamp(%t90, %t91, %t96) :: integer
|
102
|
-
%t99 =
|
102
|
+
%t99 = gather %t87, %t98 :: integer
|
103
103
|
%t101 = select %t94, %t99, %t91 :: integer
|
104
104
|
yield %t101
|
105
105
|
end_loop
|
@@ -107,7 +107,7 @@
|
|
107
107
|
)
|
108
108
|
(Declaration nw
|
109
109
|
%t102 = load_input "rows" :: array
|
110
|
-
%t107 =
|
110
|
+
%t107 = length %t102 :: integer
|
111
111
|
%t108 = const -1 :: integer
|
112
112
|
%t110 = const 0 :: integer
|
113
113
|
%t114 = const 1 :: integer
|
@@ -118,8 +118,8 @@
|
|
118
118
|
%t112 = call core.lt(%t109, %t107) :: boolean
|
119
119
|
%t117 = call core.clamp(%t109, %t110, %t115) :: integer
|
120
120
|
%t113 = call core.and(%t111, %t112) :: boolean
|
121
|
-
%t118 =
|
122
|
-
%t119 =
|
121
|
+
%t118 = gather %t102, %t117 :: any
|
122
|
+
%t119 = length %t118 :: integer
|
123
123
|
%t128 = call core.sub(%t119, %t114) :: integer
|
124
124
|
loop col id=L12 in %rows_el_103 as el=%col_el_105, idx=%col_i_106
|
125
125
|
%t121 = call core.sub(%col_i_106, %t108) :: integer
|
@@ -128,7 +128,7 @@
|
|
128
128
|
%t125 = call core.and(%t123, %t124) :: boolean
|
129
129
|
%t126 = call core.and(%t113, %t125) :: boolean
|
130
130
|
%t130 = call core.clamp(%t121, %t110, %t128) :: integer
|
131
|
-
%t131 =
|
131
|
+
%t131 = gather %t118, %t130 :: integer
|
132
132
|
%t133 = select %t126, %t131, %t110 :: integer
|
133
133
|
yield %t133
|
134
134
|
end_loop
|
@@ -136,7 +136,7 @@
|
|
136
136
|
)
|
137
137
|
(Declaration ne
|
138
138
|
%t134 = load_input "rows" :: array
|
139
|
-
%t139 =
|
139
|
+
%t139 = length %t134 :: integer
|
140
140
|
%t140 = const -1 :: integer
|
141
141
|
%t142 = const 0 :: integer
|
142
142
|
%t146 = const 1 :: integer
|
@@ -147,8 +147,8 @@
|
|
147
147
|
%t144 = call core.lt(%t141, %t139) :: boolean
|
148
148
|
%t149 = call core.clamp(%t141, %t142, %t147) :: integer
|
149
149
|
%t145 = call core.and(%t143, %t144) :: boolean
|
150
|
-
%t150 =
|
151
|
-
%t151 =
|
150
|
+
%t150 = gather %t134, %t149 :: any
|
151
|
+
%t151 = length %t150 :: integer
|
152
152
|
%t160 = call core.sub(%t151, %t146) :: integer
|
153
153
|
loop col id=L14 in %rows_el_135 as el=%col_el_137, idx=%col_i_138
|
154
154
|
%t153 = call core.sub(%col_i_138, %t146) :: integer
|
@@ -157,7 +157,7 @@
|
|
157
157
|
%t157 = call core.and(%t155, %t156) :: boolean
|
158
158
|
%t158 = call core.and(%t145, %t157) :: boolean
|
159
159
|
%t162 = call core.clamp(%t153, %t142, %t160) :: integer
|
160
|
-
%t163 =
|
160
|
+
%t163 = gather %t150, %t162 :: integer
|
161
161
|
%t165 = select %t158, %t163, %t142 :: integer
|
162
162
|
yield %t165
|
163
163
|
end_loop
|
@@ -165,7 +165,7 @@
|
|
165
165
|
)
|
166
166
|
(Declaration sw
|
167
167
|
%t166 = load_input "rows" :: array
|
168
|
-
%t171 =
|
168
|
+
%t171 = length %t166 :: integer
|
169
169
|
%t172 = const 1 :: integer
|
170
170
|
%t174 = const 0 :: integer
|
171
171
|
%t184 = const -1 :: integer
|
@@ -176,8 +176,8 @@
|
|
176
176
|
%t176 = call core.lt(%t173, %t171) :: boolean
|
177
177
|
%t181 = call core.clamp(%t173, %t174, %t179) :: integer
|
178
178
|
%t177 = call core.and(%t175, %t176) :: boolean
|
179
|
-
%t182 =
|
180
|
-
%t183 =
|
179
|
+
%t182 = gather %t166, %t181 :: any
|
180
|
+
%t183 = length %t182 :: integer
|
181
181
|
%t192 = call core.sub(%t183, %t172) :: integer
|
182
182
|
loop col id=L16 in %rows_el_167 as el=%col_el_169, idx=%col_i_170
|
183
183
|
%t185 = call core.sub(%col_i_170, %t184) :: integer
|
@@ -186,7 +186,7 @@
|
|
186
186
|
%t189 = call core.and(%t187, %t188) :: boolean
|
187
187
|
%t190 = call core.and(%t177, %t189) :: boolean
|
188
188
|
%t194 = call core.clamp(%t185, %t174, %t192) :: integer
|
189
|
-
%t195 =
|
189
|
+
%t195 = gather %t182, %t194 :: integer
|
190
190
|
%t197 = select %t190, %t195, %t174 :: integer
|
191
191
|
yield %t197
|
192
192
|
end_loop
|
@@ -194,7 +194,7 @@
|
|
194
194
|
)
|
195
195
|
(Declaration se
|
196
196
|
%t198 = load_input "rows" :: array
|
197
|
-
%t203 =
|
197
|
+
%t203 = length %t198 :: integer
|
198
198
|
%t204 = const 1 :: integer
|
199
199
|
%t206 = const 0 :: integer
|
200
200
|
%t211 = call core.sub(%t203, %t204) :: integer
|
@@ -204,8 +204,8 @@
|
|
204
204
|
%t208 = call core.lt(%t205, %t203) :: boolean
|
205
205
|
%t213 = call core.clamp(%t205, %t206, %t211) :: integer
|
206
206
|
%t209 = call core.and(%t207, %t208) :: boolean
|
207
|
-
%t214 =
|
208
|
-
%t215 =
|
207
|
+
%t214 = gather %t198, %t213 :: any
|
208
|
+
%t215 = length %t214 :: integer
|
209
209
|
%t224 = call core.sub(%t215, %t204) :: integer
|
210
210
|
loop col id=L18 in %rows_el_199 as el=%col_el_201, idx=%col_i_202
|
211
211
|
%t217 = call core.sub(%col_i_202, %t204) :: integer
|
@@ -214,7 +214,7 @@
|
|
214
214
|
%t221 = call core.and(%t219, %t220) :: boolean
|
215
215
|
%t222 = call core.and(%t209, %t221) :: boolean
|
216
216
|
%t226 = call core.clamp(%t217, %t206, %t224) :: integer
|
217
|
-
%t227 =
|
217
|
+
%t227 = gather %t214, %t226 :: integer
|
218
218
|
%t229 = select %t222, %t227, %t206 :: integer
|
219
219
|
yield %t229
|
220
220
|
end_loop
|
@@ -222,7 +222,7 @@
|
|
222
222
|
)
|
223
223
|
(Declaration neighbors
|
224
224
|
%t230 = load_input "rows" :: array
|
225
|
-
%t295 =
|
225
|
+
%t295 = length %t230 :: integer
|
226
226
|
%t296 = const -1 :: integer
|
227
227
|
%t298 = const 0 :: integer
|
228
228
|
%t302 = const 1 :: integer
|
@@ -239,14 +239,14 @@
|
|
239
239
|
%t325 = call core.clamp(%t317, %t298, %t303) :: integer
|
240
240
|
%t337 = call core.add(%t336, %t295) :: integer
|
241
241
|
%t301 = call core.and(%t299, %t300) :: boolean
|
242
|
-
%t306 =
|
242
|
+
%t306 = gather %t230, %t305 :: any
|
243
243
|
%t321 = call core.and(%t319, %t320) :: boolean
|
244
|
-
%t326 =
|
244
|
+
%t326 = gather %t230, %t325 :: any
|
245
245
|
%t338 = call core.mod(%t337, %t295) :: integer
|
246
|
-
%t307 =
|
247
|
-
%t327 =
|
248
|
-
%t339 =
|
249
|
-
%t340 =
|
246
|
+
%t307 = length %t306 :: integer
|
247
|
+
%t327 = length %t326 :: integer
|
248
|
+
%t339 = gather %t230, %t338 :: any
|
249
|
+
%t340 = length %t339 :: integer
|
250
250
|
%t396 = call core.sub(%t307, %t302) :: integer
|
251
251
|
%t452 = call core.sub(%t327, %t302) :: integer
|
252
252
|
%t348 = call core.sub(%t340, %t302) :: integer
|
@@ -254,53 +254,53 @@
|
|
254
254
|
%t308 = call core.mod(%col_i_234, %t307) :: integer
|
255
255
|
%t309 = call core.add(%t308, %t307) :: integer
|
256
256
|
%t310 = call core.mod(%t309, %t307) :: integer
|
257
|
-
%t311 =
|
257
|
+
%t311 = gather %t306, %t310 :: integer
|
258
258
|
%t313 = select %t301, %t311, %t298 :: integer
|
259
259
|
%t328 = call core.mod(%col_i_234, %t327) :: integer
|
260
260
|
%t329 = call core.add(%t328, %t327) :: integer
|
261
261
|
%t330 = call core.mod(%t329, %t327) :: integer
|
262
|
-
%t331 =
|
262
|
+
%t331 = gather %t326, %t330 :: integer
|
263
263
|
%t333 = select %t321, %t331, %t298 :: integer
|
264
264
|
%t342 = call core.sub(%col_i_234, %t296) :: integer
|
265
265
|
%t344 = call core.gte(%t342, %t298) :: boolean
|
266
266
|
%t345 = call core.lt(%t342, %t340) :: boolean
|
267
267
|
%t346 = call core.and(%t344, %t345) :: boolean
|
268
268
|
%t350 = call core.clamp(%t342, %t298, %t348) :: integer
|
269
|
-
%t351 =
|
269
|
+
%t351 = gather %t339, %t350 :: integer
|
270
270
|
%t353 = select %t346, %t351, %t298 :: integer
|
271
271
|
%t362 = call core.sub(%col_i_234, %t302) :: integer
|
272
272
|
%t364 = call core.gte(%t362, %t298) :: boolean
|
273
273
|
%t365 = call core.lt(%t362, %t340) :: boolean
|
274
274
|
%t366 = call core.and(%t364, %t365) :: boolean
|
275
275
|
%t370 = call core.clamp(%t362, %t298, %t348) :: integer
|
276
|
-
%t371 =
|
276
|
+
%t371 = gather %t339, %t370 :: integer
|
277
277
|
%t373 = select %t366, %t371, %t298 :: integer
|
278
278
|
%t392 = call core.lt(%t342, %t307) :: boolean
|
279
279
|
%t393 = call core.and(%t344, %t392) :: boolean
|
280
280
|
%t394 = call core.and(%t301, %t393) :: boolean
|
281
281
|
%t398 = call core.clamp(%t342, %t298, %t396) :: integer
|
282
|
-
%t399 =
|
282
|
+
%t399 = gather %t306, %t398 :: integer
|
283
283
|
%t401 = select %t394, %t399, %t298 :: integer
|
284
284
|
%t420 = call core.lt(%t362, %t307) :: boolean
|
285
285
|
%t421 = call core.and(%t364, %t420) :: boolean
|
286
286
|
%t422 = call core.and(%t301, %t421) :: boolean
|
287
287
|
%t426 = call core.clamp(%t362, %t298, %t396) :: integer
|
288
|
-
%t427 =
|
288
|
+
%t427 = gather %t306, %t426 :: integer
|
289
289
|
%t429 = select %t422, %t427, %t298 :: integer
|
290
290
|
%t448 = call core.lt(%t342, %t327) :: boolean
|
291
291
|
%t449 = call core.and(%t344, %t448) :: boolean
|
292
292
|
%t450 = call core.and(%t321, %t449) :: boolean
|
293
293
|
%t454 = call core.clamp(%t342, %t298, %t452) :: integer
|
294
|
-
%t455 =
|
294
|
+
%t455 = gather %t326, %t454 :: integer
|
295
295
|
%t457 = select %t450, %t455, %t298 :: integer
|
296
296
|
%t476 = call core.lt(%t362, %t327) :: boolean
|
297
297
|
%t477 = call core.and(%t364, %t476) :: boolean
|
298
298
|
%t478 = call core.and(%t321, %t477) :: boolean
|
299
299
|
%t482 = call core.clamp(%t362, %t298, %t452) :: integer
|
300
|
-
%t483 =
|
300
|
+
%t483 = gather %t326, %t482 :: integer
|
301
301
|
%t485 = select %t478, %t483, %t298 :: integer
|
302
302
|
%t243 = make_tuple(%t313, %t333, %t353, %t373, %t401, %t429, %t457, %t485) :: tuple<integer>
|
303
|
-
%t244 =
|
303
|
+
%t244 = fold %t243 fn="agg.sum" ::
|
304
304
|
yield %t244
|
305
305
|
end_loop
|
306
306
|
end_loop
|
@@ -317,7 +317,7 @@
|
|
317
317
|
)
|
318
318
|
(Declaration n3_alive
|
319
319
|
%t253 = load_input "rows" :: array
|
320
|
-
%t530 =
|
320
|
+
%t530 = length %t253 :: integer
|
321
321
|
%t531 = const -1 :: integer
|
322
322
|
%t533 = const 0 :: integer
|
323
323
|
%t537 = const 1 :: integer
|
@@ -335,14 +335,14 @@
|
|
335
335
|
%t560 = call core.clamp(%t552, %t533, %t538) :: integer
|
336
336
|
%t572 = call core.add(%t571, %t530) :: integer
|
337
337
|
%t536 = call core.and(%t534, %t535) :: boolean
|
338
|
-
%t541 =
|
338
|
+
%t541 = gather %t253, %t540 :: any
|
339
339
|
%t556 = call core.and(%t554, %t555) :: boolean
|
340
|
-
%t561 =
|
340
|
+
%t561 = gather %t253, %t560 :: any
|
341
341
|
%t573 = call core.mod(%t572, %t530) :: integer
|
342
|
-
%t542 =
|
343
|
-
%t562 =
|
344
|
-
%t574 =
|
345
|
-
%t575 =
|
342
|
+
%t542 = length %t541 :: integer
|
343
|
+
%t562 = length %t561 :: integer
|
344
|
+
%t574 = gather %t253, %t573 :: any
|
345
|
+
%t575 = length %t574 :: integer
|
346
346
|
%t631 = call core.sub(%t542, %t537) :: integer
|
347
347
|
%t687 = call core.sub(%t562, %t537) :: integer
|
348
348
|
%t583 = call core.sub(%t575, %t537) :: integer
|
@@ -350,53 +350,53 @@
|
|
350
350
|
%t543 = call core.mod(%col_i_257, %t542) :: integer
|
351
351
|
%t544 = call core.add(%t543, %t542) :: integer
|
352
352
|
%t545 = call core.mod(%t544, %t542) :: integer
|
353
|
-
%t546 =
|
353
|
+
%t546 = gather %t541, %t545 :: integer
|
354
354
|
%t548 = select %t536, %t546, %t533 :: integer
|
355
355
|
%t563 = call core.mod(%col_i_257, %t562) :: integer
|
356
356
|
%t564 = call core.add(%t563, %t562) :: integer
|
357
357
|
%t565 = call core.mod(%t564, %t562) :: integer
|
358
|
-
%t566 =
|
358
|
+
%t566 = gather %t561, %t565 :: integer
|
359
359
|
%t568 = select %t556, %t566, %t533 :: integer
|
360
360
|
%t577 = call core.sub(%col_i_257, %t531) :: integer
|
361
361
|
%t579 = call core.gte(%t577, %t533) :: boolean
|
362
362
|
%t580 = call core.lt(%t577, %t575) :: boolean
|
363
363
|
%t581 = call core.and(%t579, %t580) :: boolean
|
364
364
|
%t585 = call core.clamp(%t577, %t533, %t583) :: integer
|
365
|
-
%t586 =
|
365
|
+
%t586 = gather %t574, %t585 :: integer
|
366
366
|
%t588 = select %t581, %t586, %t533 :: integer
|
367
367
|
%t597 = call core.sub(%col_i_257, %t537) :: integer
|
368
368
|
%t599 = call core.gte(%t597, %t533) :: boolean
|
369
369
|
%t600 = call core.lt(%t597, %t575) :: boolean
|
370
370
|
%t601 = call core.and(%t599, %t600) :: boolean
|
371
371
|
%t605 = call core.clamp(%t597, %t533, %t583) :: integer
|
372
|
-
%t606 =
|
372
|
+
%t606 = gather %t574, %t605 :: integer
|
373
373
|
%t608 = select %t601, %t606, %t533 :: integer
|
374
374
|
%t627 = call core.lt(%t577, %t542) :: boolean
|
375
375
|
%t628 = call core.and(%t579, %t627) :: boolean
|
376
376
|
%t629 = call core.and(%t536, %t628) :: boolean
|
377
377
|
%t633 = call core.clamp(%t577, %t533, %t631) :: integer
|
378
|
-
%t634 =
|
378
|
+
%t634 = gather %t541, %t633 :: integer
|
379
379
|
%t636 = select %t629, %t634, %t533 :: integer
|
380
380
|
%t655 = call core.lt(%t597, %t542) :: boolean
|
381
381
|
%t656 = call core.and(%t599, %t655) :: boolean
|
382
382
|
%t657 = call core.and(%t536, %t656) :: boolean
|
383
383
|
%t661 = call core.clamp(%t597, %t533, %t631) :: integer
|
384
|
-
%t662 =
|
384
|
+
%t662 = gather %t541, %t661 :: integer
|
385
385
|
%t664 = select %t657, %t662, %t533 :: integer
|
386
386
|
%t683 = call core.lt(%t577, %t562) :: boolean
|
387
387
|
%t684 = call core.and(%t579, %t683) :: boolean
|
388
388
|
%t685 = call core.and(%t556, %t684) :: boolean
|
389
389
|
%t689 = call core.clamp(%t577, %t533, %t687) :: integer
|
390
|
-
%t690 =
|
390
|
+
%t690 = gather %t561, %t689 :: integer
|
391
391
|
%t692 = select %t685, %t690, %t533 :: integer
|
392
392
|
%t711 = call core.lt(%t597, %t562) :: boolean
|
393
393
|
%t712 = call core.and(%t599, %t711) :: boolean
|
394
394
|
%t713 = call core.and(%t556, %t712) :: boolean
|
395
395
|
%t717 = call core.clamp(%t597, %t533, %t687) :: integer
|
396
|
-
%t718 =
|
396
|
+
%t718 = gather %t561, %t717 :: integer
|
397
397
|
%t720 = select %t713, %t718, %t533 :: integer
|
398
398
|
%t496 = make_tuple(%t548, %t568, %t588, %t608, %t636, %t664, %t692, %t720) :: tuple<integer>
|
399
|
-
%t497 =
|
399
|
+
%t497 = fold %t496 fn="agg.sum" ::
|
400
400
|
%t260 = call core.eq(%t497, %t259) :: boolean
|
401
401
|
yield %t260
|
402
402
|
end_loop
|
@@ -404,7 +404,7 @@
|
|
404
404
|
)
|
405
405
|
(Declaration n2_alive
|
406
406
|
%t261 = load_input "rows" :: array
|
407
|
-
%t722 =
|
407
|
+
%t722 = length %t261 :: integer
|
408
408
|
%t723 = const -1 :: integer
|
409
409
|
%t725 = const 0 :: integer
|
410
410
|
%t729 = const 1 :: integer
|
@@ -422,14 +422,14 @@
|
|
422
422
|
%t752 = call core.clamp(%t744, %t725, %t730) :: integer
|
423
423
|
%t764 = call core.add(%t763, %t722) :: integer
|
424
424
|
%t728 = call core.and(%t726, %t727) :: boolean
|
425
|
-
%t733 =
|
425
|
+
%t733 = gather %t261, %t732 :: any
|
426
426
|
%t748 = call core.and(%t746, %t747) :: boolean
|
427
|
-
%t753 =
|
427
|
+
%t753 = gather %t261, %t752 :: any
|
428
428
|
%t765 = call core.mod(%t764, %t722) :: integer
|
429
|
-
%t734 =
|
430
|
-
%t754 =
|
431
|
-
%t766 =
|
432
|
-
%t767 =
|
429
|
+
%t734 = length %t733 :: integer
|
430
|
+
%t754 = length %t753 :: integer
|
431
|
+
%t766 = gather %t261, %t765 :: any
|
432
|
+
%t767 = length %t766 :: integer
|
433
433
|
%t823 = call core.sub(%t734, %t729) :: integer
|
434
434
|
%t879 = call core.sub(%t754, %t729) :: integer
|
435
435
|
%t775 = call core.sub(%t767, %t729) :: integer
|
@@ -437,53 +437,53 @@
|
|
437
437
|
%t735 = call core.mod(%col_i_265, %t734) :: integer
|
438
438
|
%t736 = call core.add(%t735, %t734) :: integer
|
439
439
|
%t737 = call core.mod(%t736, %t734) :: integer
|
440
|
-
%t738 =
|
440
|
+
%t738 = gather %t733, %t737 :: integer
|
441
441
|
%t740 = select %t728, %t738, %t725 :: integer
|
442
442
|
%t755 = call core.mod(%col_i_265, %t754) :: integer
|
443
443
|
%t756 = call core.add(%t755, %t754) :: integer
|
444
444
|
%t757 = call core.mod(%t756, %t754) :: integer
|
445
|
-
%t758 =
|
445
|
+
%t758 = gather %t753, %t757 :: integer
|
446
446
|
%t760 = select %t748, %t758, %t725 :: integer
|
447
447
|
%t769 = call core.sub(%col_i_265, %t723) :: integer
|
448
448
|
%t771 = call core.gte(%t769, %t725) :: boolean
|
449
449
|
%t772 = call core.lt(%t769, %t767) :: boolean
|
450
450
|
%t773 = call core.and(%t771, %t772) :: boolean
|
451
451
|
%t777 = call core.clamp(%t769, %t725, %t775) :: integer
|
452
|
-
%t778 =
|
452
|
+
%t778 = gather %t766, %t777 :: integer
|
453
453
|
%t780 = select %t773, %t778, %t725 :: integer
|
454
454
|
%t789 = call core.sub(%col_i_265, %t729) :: integer
|
455
455
|
%t791 = call core.gte(%t789, %t725) :: boolean
|
456
456
|
%t792 = call core.lt(%t789, %t767) :: boolean
|
457
457
|
%t793 = call core.and(%t791, %t792) :: boolean
|
458
458
|
%t797 = call core.clamp(%t789, %t725, %t775) :: integer
|
459
|
-
%t798 =
|
459
|
+
%t798 = gather %t766, %t797 :: integer
|
460
460
|
%t800 = select %t793, %t798, %t725 :: integer
|
461
461
|
%t819 = call core.lt(%t769, %t734) :: boolean
|
462
462
|
%t820 = call core.and(%t771, %t819) :: boolean
|
463
463
|
%t821 = call core.and(%t728, %t820) :: boolean
|
464
464
|
%t825 = call core.clamp(%t769, %t725, %t823) :: integer
|
465
|
-
%t826 =
|
465
|
+
%t826 = gather %t733, %t825 :: integer
|
466
466
|
%t828 = select %t821, %t826, %t725 :: integer
|
467
467
|
%t847 = call core.lt(%t789, %t734) :: boolean
|
468
468
|
%t848 = call core.and(%t791, %t847) :: boolean
|
469
469
|
%t849 = call core.and(%t728, %t848) :: boolean
|
470
470
|
%t853 = call core.clamp(%t789, %t725, %t823) :: integer
|
471
|
-
%t854 =
|
471
|
+
%t854 = gather %t733, %t853 :: integer
|
472
472
|
%t856 = select %t849, %t854, %t725 :: integer
|
473
473
|
%t875 = call core.lt(%t769, %t754) :: boolean
|
474
474
|
%t876 = call core.and(%t771, %t875) :: boolean
|
475
475
|
%t877 = call core.and(%t748, %t876) :: boolean
|
476
476
|
%t881 = call core.clamp(%t769, %t725, %t879) :: integer
|
477
|
-
%t882 =
|
477
|
+
%t882 = gather %t753, %t881 :: integer
|
478
478
|
%t884 = select %t877, %t882, %t725 :: integer
|
479
479
|
%t903 = call core.lt(%t789, %t754) :: boolean
|
480
480
|
%t904 = call core.and(%t791, %t903) :: boolean
|
481
481
|
%t905 = call core.and(%t748, %t904) :: boolean
|
482
482
|
%t909 = call core.clamp(%t789, %t725, %t879) :: integer
|
483
|
-
%t910 =
|
483
|
+
%t910 = gather %t753, %t909 :: integer
|
484
484
|
%t912 = select %t905, %t910, %t725 :: integer
|
485
485
|
%t507 = make_tuple(%t740, %t760, %t780, %t800, %t828, %t856, %t884, %t912) :: tuple<integer>
|
486
|
-
%t508 =
|
486
|
+
%t508 = fold %t507 fn="agg.sum" ::
|
487
487
|
%t268 = call core.eq(%t508, %t267) :: boolean
|
488
488
|
yield %t268
|
489
489
|
end_loop
|
@@ -491,7 +491,7 @@
|
|
491
491
|
)
|
492
492
|
(Declaration keep_alive
|
493
493
|
%t269 = load_input "rows" :: array
|
494
|
-
%t915 =
|
494
|
+
%t915 = length %t269 :: integer
|
495
495
|
%t916 = const -1 :: integer
|
496
496
|
%t918 = const 0 :: integer
|
497
497
|
%t922 = const 1 :: integer
|
@@ -509,14 +509,14 @@
|
|
509
509
|
%t945 = call core.clamp(%t937, %t918, %t923) :: integer
|
510
510
|
%t957 = call core.add(%t956, %t915) :: integer
|
511
511
|
%t921 = call core.and(%t919, %t920) :: boolean
|
512
|
-
%t926 =
|
512
|
+
%t926 = gather %t269, %t925 :: any
|
513
513
|
%t941 = call core.and(%t939, %t940) :: boolean
|
514
|
-
%t946 =
|
514
|
+
%t946 = gather %t269, %t945 :: any
|
515
515
|
%t958 = call core.mod(%t957, %t915) :: integer
|
516
|
-
%t927 =
|
517
|
-
%t947 =
|
518
|
-
%t959 =
|
519
|
-
%t960 =
|
516
|
+
%t927 = length %t926 :: integer
|
517
|
+
%t947 = length %t946 :: integer
|
518
|
+
%t959 = gather %t269, %t958 :: any
|
519
|
+
%t960 = length %t959 :: integer
|
520
520
|
%t1016 = call core.sub(%t927, %t922) :: integer
|
521
521
|
%t1072 = call core.sub(%t947, %t922) :: integer
|
522
522
|
%t968 = call core.sub(%t960, %t922) :: integer
|
@@ -524,53 +524,53 @@
|
|
524
524
|
%t928 = call core.mod(%col_i_273, %t927) :: integer
|
525
525
|
%t929 = call core.add(%t928, %t927) :: integer
|
526
526
|
%t930 = call core.mod(%t929, %t927) :: integer
|
527
|
-
%t931 =
|
527
|
+
%t931 = gather %t926, %t930 :: integer
|
528
528
|
%t933 = select %t921, %t931, %t918 :: integer
|
529
529
|
%t948 = call core.mod(%col_i_273, %t947) :: integer
|
530
530
|
%t949 = call core.add(%t948, %t947) :: integer
|
531
531
|
%t950 = call core.mod(%t949, %t947) :: integer
|
532
|
-
%t951 =
|
532
|
+
%t951 = gather %t946, %t950 :: integer
|
533
533
|
%t953 = select %t941, %t951, %t918 :: integer
|
534
534
|
%t962 = call core.sub(%col_i_273, %t916) :: integer
|
535
535
|
%t964 = call core.gte(%t962, %t918) :: boolean
|
536
536
|
%t965 = call core.lt(%t962, %t960) :: boolean
|
537
537
|
%t966 = call core.and(%t964, %t965) :: boolean
|
538
538
|
%t970 = call core.clamp(%t962, %t918, %t968) :: integer
|
539
|
-
%t971 =
|
539
|
+
%t971 = gather %t959, %t970 :: integer
|
540
540
|
%t973 = select %t966, %t971, %t918 :: integer
|
541
541
|
%t982 = call core.sub(%col_i_273, %t922) :: integer
|
542
542
|
%t984 = call core.gte(%t982, %t918) :: boolean
|
543
543
|
%t985 = call core.lt(%t982, %t960) :: boolean
|
544
544
|
%t986 = call core.and(%t984, %t985) :: boolean
|
545
545
|
%t990 = call core.clamp(%t982, %t918, %t968) :: integer
|
546
|
-
%t991 =
|
546
|
+
%t991 = gather %t959, %t990 :: integer
|
547
547
|
%t993 = select %t986, %t991, %t918 :: integer
|
548
548
|
%t1012 = call core.lt(%t962, %t927) :: boolean
|
549
549
|
%t1013 = call core.and(%t964, %t1012) :: boolean
|
550
550
|
%t1014 = call core.and(%t921, %t1013) :: boolean
|
551
551
|
%t1018 = call core.clamp(%t962, %t918, %t1016) :: integer
|
552
|
-
%t1019 =
|
552
|
+
%t1019 = gather %t926, %t1018 :: integer
|
553
553
|
%t1021 = select %t1014, %t1019, %t918 :: integer
|
554
554
|
%t1040 = call core.lt(%t982, %t927) :: boolean
|
555
555
|
%t1041 = call core.and(%t984, %t1040) :: boolean
|
556
556
|
%t1042 = call core.and(%t921, %t1041) :: boolean
|
557
557
|
%t1046 = call core.clamp(%t982, %t918, %t1016) :: integer
|
558
|
-
%t1047 =
|
558
|
+
%t1047 = gather %t926, %t1046 :: integer
|
559
559
|
%t1049 = select %t1042, %t1047, %t918 :: integer
|
560
560
|
%t1068 = call core.lt(%t962, %t947) :: boolean
|
561
561
|
%t1069 = call core.and(%t964, %t1068) :: boolean
|
562
562
|
%t1070 = call core.and(%t941, %t1069) :: boolean
|
563
563
|
%t1074 = call core.clamp(%t962, %t918, %t1072) :: integer
|
564
|
-
%t1075 =
|
564
|
+
%t1075 = gather %t946, %t1074 :: integer
|
565
565
|
%t1077 = select %t1070, %t1075, %t918 :: integer
|
566
566
|
%t1096 = call core.lt(%t982, %t947) :: boolean
|
567
567
|
%t1097 = call core.and(%t984, %t1096) :: boolean
|
568
568
|
%t1098 = call core.and(%t941, %t1097) :: boolean
|
569
569
|
%t1102 = call core.clamp(%t982, %t918, %t1072) :: integer
|
570
|
-
%t1103 =
|
570
|
+
%t1103 = gather %t946, %t1102 :: integer
|
571
571
|
%t1105 = select %t1098, %t1103, %t918 :: integer
|
572
572
|
%t1106 = make_tuple(%t933, %t953, %t973, %t993, %t1021, %t1049, %t1077, %t1105) :: tuple<integer>
|
573
|
-
%t1107 =
|
573
|
+
%t1107 = fold %t1106 fn="agg.sum" ::
|
574
574
|
%t512 = call core.eq(%t1107, %t511) :: boolean
|
575
575
|
%t516 = call core.gt(%col_el_272, %t918) :: boolean
|
576
576
|
%t276 = call core.and(%t512, %t516) :: boolean
|
@@ -580,7 +580,7 @@
|
|
580
580
|
)
|
581
581
|
(Declaration next_alive
|
582
582
|
%t277 = load_input "rows" :: array
|
583
|
-
%t1111 =
|
583
|
+
%t1111 = length %t277 :: integer
|
584
584
|
%t1112 = const -1 :: integer
|
585
585
|
%t1114 = const 0 :: integer
|
586
586
|
%t1118 = const 1 :: integer
|
@@ -599,14 +599,14 @@
|
|
599
599
|
%t1141 = call core.clamp(%t1133, %t1114, %t1119) :: integer
|
600
600
|
%t1153 = call core.add(%t1152, %t1111) :: integer
|
601
601
|
%t1117 = call core.and(%t1115, %t1116) :: boolean
|
602
|
-
%t1122 =
|
602
|
+
%t1122 = gather %t277, %t1121 :: any
|
603
603
|
%t1137 = call core.and(%t1135, %t1136) :: boolean
|
604
|
-
%t1142 =
|
604
|
+
%t1142 = gather %t277, %t1141 :: any
|
605
605
|
%t1154 = call core.mod(%t1153, %t1111) :: integer
|
606
|
-
%t1123 =
|
607
|
-
%t1143 =
|
608
|
-
%t1155 =
|
609
|
-
%t1156 =
|
606
|
+
%t1123 = length %t1122 :: integer
|
607
|
+
%t1143 = length %t1142 :: integer
|
608
|
+
%t1155 = gather %t277, %t1154 :: any
|
609
|
+
%t1156 = length %t1155 :: integer
|
610
610
|
%t1212 = call core.sub(%t1123, %t1118) :: integer
|
611
611
|
%t1268 = call core.sub(%t1143, %t1118) :: integer
|
612
612
|
%t1164 = call core.sub(%t1156, %t1118) :: integer
|
@@ -614,53 +614,53 @@
|
|
614
614
|
%t1124 = call core.mod(%col_i_281, %t1123) :: integer
|
615
615
|
%t1125 = call core.add(%t1124, %t1123) :: integer
|
616
616
|
%t1126 = call core.mod(%t1125, %t1123) :: integer
|
617
|
-
%t1127 =
|
617
|
+
%t1127 = gather %t1122, %t1126 :: integer
|
618
618
|
%t1129 = select %t1117, %t1127, %t1114 :: integer
|
619
619
|
%t1144 = call core.mod(%col_i_281, %t1143) :: integer
|
620
620
|
%t1145 = call core.add(%t1144, %t1143) :: integer
|
621
621
|
%t1146 = call core.mod(%t1145, %t1143) :: integer
|
622
|
-
%t1147 =
|
622
|
+
%t1147 = gather %t1142, %t1146 :: integer
|
623
623
|
%t1149 = select %t1137, %t1147, %t1114 :: integer
|
624
624
|
%t1158 = call core.sub(%col_i_281, %t1112) :: integer
|
625
625
|
%t1160 = call core.gte(%t1158, %t1114) :: boolean
|
626
626
|
%t1161 = call core.lt(%t1158, %t1156) :: boolean
|
627
627
|
%t1162 = call core.and(%t1160, %t1161) :: boolean
|
628
628
|
%t1166 = call core.clamp(%t1158, %t1114, %t1164) :: integer
|
629
|
-
%t1167 =
|
629
|
+
%t1167 = gather %t1155, %t1166 :: integer
|
630
630
|
%t1169 = select %t1162, %t1167, %t1114 :: integer
|
631
631
|
%t1178 = call core.sub(%col_i_281, %t1118) :: integer
|
632
632
|
%t1180 = call core.gte(%t1178, %t1114) :: boolean
|
633
633
|
%t1181 = call core.lt(%t1178, %t1156) :: boolean
|
634
634
|
%t1182 = call core.and(%t1180, %t1181) :: boolean
|
635
635
|
%t1186 = call core.clamp(%t1178, %t1114, %t1164) :: integer
|
636
|
-
%t1187 =
|
636
|
+
%t1187 = gather %t1155, %t1186 :: integer
|
637
637
|
%t1189 = select %t1182, %t1187, %t1114 :: integer
|
638
638
|
%t1208 = call core.lt(%t1158, %t1123) :: boolean
|
639
639
|
%t1209 = call core.and(%t1160, %t1208) :: boolean
|
640
640
|
%t1210 = call core.and(%t1117, %t1209) :: boolean
|
641
641
|
%t1214 = call core.clamp(%t1158, %t1114, %t1212) :: integer
|
642
|
-
%t1215 =
|
642
|
+
%t1215 = gather %t1122, %t1214 :: integer
|
643
643
|
%t1217 = select %t1210, %t1215, %t1114 :: integer
|
644
644
|
%t1236 = call core.lt(%t1178, %t1123) :: boolean
|
645
645
|
%t1237 = call core.and(%t1180, %t1236) :: boolean
|
646
646
|
%t1238 = call core.and(%t1117, %t1237) :: boolean
|
647
647
|
%t1242 = call core.clamp(%t1178, %t1114, %t1212) :: integer
|
648
|
-
%t1243 =
|
648
|
+
%t1243 = gather %t1122, %t1242 :: integer
|
649
649
|
%t1245 = select %t1238, %t1243, %t1114 :: integer
|
650
650
|
%t1264 = call core.lt(%t1158, %t1143) :: boolean
|
651
651
|
%t1265 = call core.and(%t1160, %t1264) :: boolean
|
652
652
|
%t1266 = call core.and(%t1137, %t1265) :: boolean
|
653
653
|
%t1270 = call core.clamp(%t1158, %t1114, %t1268) :: integer
|
654
|
-
%t1271 =
|
654
|
+
%t1271 = gather %t1142, %t1270 :: integer
|
655
655
|
%t1273 = select %t1266, %t1271, %t1114 :: integer
|
656
656
|
%t1292 = call core.lt(%t1178, %t1143) :: boolean
|
657
657
|
%t1293 = call core.and(%t1180, %t1292) :: boolean
|
658
658
|
%t1294 = call core.and(%t1137, %t1293) :: boolean
|
659
659
|
%t1298 = call core.clamp(%t1178, %t1114, %t1268) :: integer
|
660
|
-
%t1299 =
|
660
|
+
%t1299 = gather %t1142, %t1298 :: integer
|
661
661
|
%t1301 = select %t1294, %t1299, %t1114 :: integer
|
662
662
|
%t1302 = make_tuple(%t1129, %t1149, %t1169, %t1189, %t1217, %t1245, %t1273, %t1301) :: tuple<integer>
|
663
|
-
%t1303 =
|
663
|
+
%t1303 = fold %t1302 fn="agg.sum" ::
|
664
664
|
%t520 = call core.eq(%t1303, %t519) :: boolean
|
665
665
|
%t1317 = call core.eq(%t1303, %t1316) :: boolean
|
666
666
|
%t1321 = call core.gt(%col_el_280, %t1114) :: boolean
|
@@ -672,7 +672,7 @@
|
|
672
672
|
)
|
673
673
|
(Declaration next_state
|
674
674
|
%t285 = load_input "rows" :: array
|
675
|
-
%t1539 =
|
675
|
+
%t1539 = length %t285 :: integer
|
676
676
|
%t1540 = const -1 :: integer
|
677
677
|
%t1542 = const 0 :: integer
|
678
678
|
%t1546 = const 1 :: integer
|
@@ -691,14 +691,14 @@
|
|
691
691
|
%t1569 = call core.clamp(%t1561, %t1542, %t1547) :: integer
|
692
692
|
%t1581 = call core.add(%t1580, %t1539) :: integer
|
693
693
|
%t1545 = call core.and(%t1543, %t1544) :: boolean
|
694
|
-
%t1550 =
|
694
|
+
%t1550 = gather %t285, %t1549 :: any
|
695
695
|
%t1565 = call core.and(%t1563, %t1564) :: boolean
|
696
|
-
%t1570 =
|
696
|
+
%t1570 = gather %t285, %t1569 :: any
|
697
697
|
%t1582 = call core.mod(%t1581, %t1539) :: integer
|
698
|
-
%t1551 =
|
699
|
-
%t1571 =
|
700
|
-
%t1583 =
|
701
|
-
%t1584 =
|
698
|
+
%t1551 = length %t1550 :: integer
|
699
|
+
%t1571 = length %t1570 :: integer
|
700
|
+
%t1583 = gather %t285, %t1582 :: any
|
701
|
+
%t1584 = length %t1583 :: integer
|
702
702
|
%t1640 = call core.sub(%t1551, %t1546) :: integer
|
703
703
|
%t1696 = call core.sub(%t1571, %t1546) :: integer
|
704
704
|
%t1592 = call core.sub(%t1584, %t1546) :: integer
|
@@ -706,53 +706,53 @@
|
|
706
706
|
%t1552 = call core.mod(%col_i_289, %t1551) :: integer
|
707
707
|
%t1553 = call core.add(%t1552, %t1551) :: integer
|
708
708
|
%t1554 = call core.mod(%t1553, %t1551) :: integer
|
709
|
-
%t1555 =
|
709
|
+
%t1555 = gather %t1550, %t1554 :: integer
|
710
710
|
%t1557 = select %t1545, %t1555, %t1542 :: integer
|
711
711
|
%t1572 = call core.mod(%col_i_289, %t1571) :: integer
|
712
712
|
%t1573 = call core.add(%t1572, %t1571) :: integer
|
713
713
|
%t1574 = call core.mod(%t1573, %t1571) :: integer
|
714
|
-
%t1575 =
|
714
|
+
%t1575 = gather %t1570, %t1574 :: integer
|
715
715
|
%t1577 = select %t1565, %t1575, %t1542 :: integer
|
716
716
|
%t1586 = call core.sub(%col_i_289, %t1540) :: integer
|
717
717
|
%t1588 = call core.gte(%t1586, %t1542) :: boolean
|
718
718
|
%t1589 = call core.lt(%t1586, %t1584) :: boolean
|
719
719
|
%t1590 = call core.and(%t1588, %t1589) :: boolean
|
720
720
|
%t1594 = call core.clamp(%t1586, %t1542, %t1592) :: integer
|
721
|
-
%t1595 =
|
721
|
+
%t1595 = gather %t1583, %t1594 :: integer
|
722
722
|
%t1597 = select %t1590, %t1595, %t1542 :: integer
|
723
723
|
%t1606 = call core.sub(%col_i_289, %t1546) :: integer
|
724
724
|
%t1608 = call core.gte(%t1606, %t1542) :: boolean
|
725
725
|
%t1609 = call core.lt(%t1606, %t1584) :: boolean
|
726
726
|
%t1610 = call core.and(%t1608, %t1609) :: boolean
|
727
727
|
%t1614 = call core.clamp(%t1606, %t1542, %t1592) :: integer
|
728
|
-
%t1615 =
|
728
|
+
%t1615 = gather %t1583, %t1614 :: integer
|
729
729
|
%t1617 = select %t1610, %t1615, %t1542 :: integer
|
730
730
|
%t1636 = call core.lt(%t1586, %t1551) :: boolean
|
731
731
|
%t1637 = call core.and(%t1588, %t1636) :: boolean
|
732
732
|
%t1638 = call core.and(%t1545, %t1637) :: boolean
|
733
733
|
%t1642 = call core.clamp(%t1586, %t1542, %t1640) :: integer
|
734
|
-
%t1643 =
|
734
|
+
%t1643 = gather %t1550, %t1642 :: integer
|
735
735
|
%t1645 = select %t1638, %t1643, %t1542 :: integer
|
736
736
|
%t1664 = call core.lt(%t1606, %t1551) :: boolean
|
737
737
|
%t1665 = call core.and(%t1608, %t1664) :: boolean
|
738
738
|
%t1666 = call core.and(%t1545, %t1665) :: boolean
|
739
739
|
%t1670 = call core.clamp(%t1606, %t1542, %t1640) :: integer
|
740
|
-
%t1671 =
|
740
|
+
%t1671 = gather %t1550, %t1670 :: integer
|
741
741
|
%t1673 = select %t1666, %t1671, %t1542 :: integer
|
742
742
|
%t1692 = call core.lt(%t1586, %t1571) :: boolean
|
743
743
|
%t1693 = call core.and(%t1588, %t1692) :: boolean
|
744
744
|
%t1694 = call core.and(%t1565, %t1693) :: boolean
|
745
745
|
%t1698 = call core.clamp(%t1586, %t1542, %t1696) :: integer
|
746
|
-
%t1699 =
|
746
|
+
%t1699 = gather %t1570, %t1698 :: integer
|
747
747
|
%t1701 = select %t1694, %t1699, %t1542 :: integer
|
748
748
|
%t1720 = call core.lt(%t1606, %t1571) :: boolean
|
749
749
|
%t1721 = call core.and(%t1608, %t1720) :: boolean
|
750
750
|
%t1722 = call core.and(%t1565, %t1721) :: boolean
|
751
751
|
%t1726 = call core.clamp(%t1606, %t1542, %t1696) :: integer
|
752
|
-
%t1727 =
|
752
|
+
%t1727 = gather %t1570, %t1726 :: integer
|
753
753
|
%t1729 = select %t1722, %t1727, %t1542 :: integer
|
754
754
|
%t1332 = make_tuple(%t1557, %t1577, %t1597, %t1617, %t1645, %t1673, %t1701, %t1729) :: tuple<integer>
|
755
|
-
%t1333 =
|
755
|
+
%t1333 = fold %t1332 fn="agg.sum" ::
|
756
756
|
%t1335 = call core.eq(%t1333, %t1334) :: boolean
|
757
757
|
%t1340 = call core.eq(%t1333, %t1339) :: boolean
|
758
758
|
%t1344 = call core.gt(%col_el_288, %t1542) :: boolean
|