contifier bug
Stephen Weeks
MLton@sourcelight.com
Wed, 26 Sep 2001 18:23:15 -0700
I am working on implementing MLton.Exn.history, and in doing so, tickled another
contifier bug, where the contifier produces a program in which a continuation is
called before its definition (yeah, yeah, SSA will be there RSN).
Anyways, the bug is on fft.sml, in the contify2 pass. The sources which show
the bug are at
http://www.star-lab.com/sweeks/src.tgz
Matthew, can you take a look?
The shrinker call that the contifier generates is below.
Cps.shrinkExp ==> let
fun L_0 (x_215) =
let
val _ = HandlerPop
val x_216 = Ref_deref (x_217)
fun L_1 (env_22) =
let
fun L_2 (x_218) =
let
val _ = HandlerPop
val x_219 = Stdio_print (global_18)
val x_220 = MLton_halt (global_3)
in
()
end
val _ = HandlerPush L_2
val x_221 = Stdio_print (global_19)
fun L_4 () =
let
val x_222 = Stdio_print (global_20)
fun L_7 () =
let
val _ = HandlerPop
in
()
end
in
L_7 (exit_0 (env_22, global_3))
end
fun L_21 () =
let
fun L_13 (x_223) =
let
val x_224 = Stdio_print (x_223)
in
L_4 ()
end
fun L_16 () =
L_13 (global_21)
fun L_17 () =
L_13 (global_22)
fun L_18 () =
L_13 (global_23)
fun L_20 () =
L_13 (global_24)
fun L_487 (x_225) =
L_13 (global_25)
in
case x_215 of
Subscript_0 => L_20
| Fail_0 => L_487
| Div_0 => L_18
| Size_0 => L_17
| Overflow => L_16
end
fun L_22 (x_226) =
let
val x_227 = Stdio_print (global_26)
val x_228 = Stdio_print (x_226)
in
L_4 ()
end
in
case x_215 of
Fail_0 => L_22 | _ => L_21
end
fun L_25 () =
let
val x_229 = MLton_bug (global_27)
in
()
end
in
case x_216 of
Env_1 => L_25 | Env_0 => L_1
end
val _ = HandlerPush L_0
fun loop_1 (x_230) =
let
fun L_26 () =
let
val tuple_0 = (global_29, global_30)
val tuple_1 = (global_30, global_29, global_31)
val tuple_2 = (global_32,
global_30,
global_30,
global_30)
val x_231 = (global_31, global_29, global_31)
fun L_27 (x_232) =
let
val tuple_3 = (x_231, tuple_1)
val x_233 = Env_0 (tuple_3)
val x_234 = Ref_assign (x_217, x_233)
fun L_28 (x_235) =
let
val x_237 = (x_235, global_34)
val x_238 = ::_0 (x_237)
val x_239 = (global_35, x_238)
val x_236 = ::_0 (x_239)
fun L_29 (x_240) =
let
val x_241 = Real_mul (global_38,
global_37)
val tuple_4 = (global_29,
global_31,
global_29,
global_31,
tuple_1,
x_240,
x_232,
x_241,
global_31,
global_30,
global_31,
tuple_0,
global_30,
global_30,
tuple_2,
x_231)
fun loop_2 (x_244,
x_243,
x_242) =
let
val x_245 = MLton_eq (x_242,
global_1)
fun L_30 () =
let
fun L_31 () =
let
val _ = HandlerPop
in
()
end
in
L_31 (exit_0 (tuple_3,
global_1))
end
fun L_32 () =
let
fun x_1 (env_23,
x_246) =
let
val x_248 = #18 env_23
val x_249 = #17 env_23
val div_3 = #16 env_23
val x_250 = #15 env_23
val x_251 = #14 env_23
val new_1 = #13 env_23
val update_6 = #12 env_23
val x_252 = #11 env_23
val sub_13 = #10 env_23
val tpi_2 = #9 env_23
val buffer_1 = #8 env_23
val x_253 = #7 env_23
val concat_3 = #6 env_23
val x_254 = #5 env_23
val array_6 = #4 env_23
val sub_14 = #3 env_23
val array_7 = #2 env_23
val loop_np_1 = #1 env_23
fun L_33 () =
let
fun L_35 () =
raise (x_243)
val x_255 = Int_subCheck (x_242,
global_3) Overflow L_35
in
loop_2 (x_244,
x_243,
x_255)
end
fun L_36 () =
let
fun L_37 () =
let
val x_258 = Real_fromInt (x_246)
val x_257 = (x_246,
global_39)
fun L_38 (x_259) =
let
fun L_40 () =
raise (x_250)
val x_261 = Int_subCheck (x_259,
global_3) Overflow L_40
fun L_42 () =
raise (x_251)
val x_260 = Int_addCheck (x_246,
global_39) Overflow L_42
fun L_43 (x_262) =
let
fun L_45 () =
raise (x_251)
val x_263 = Int_addCheck (x_246,
global_39) Overflow L_45
fun L_46 (x_264) =
let
val x_266 = Real_div (global_37,
x_258)
val x_267 = Real_sub (x_258,
global_40)
val x_268 = Real_mul (x_267,
global_41)
val x_265 = (x_262,
global_3,
x_268)
fun L_47 () =
let
val x_269 = (x_264,
global_3,
global_2)
fun L_48 () =
let
val x_270 = (x_246,
global_39)
fun L_49 (x_271) =
let
fun L_51 () =
raise (x_251)
val x_273 = Int_addCheck (x_271,
global_3) Overflow L_51
val x_272 = (x_262,
x_273,
global_42)
fun L_52 () =
let
fun L_54 () =
raise (x_251)
val x_275 = Int_addCheck (x_271,
global_3) Overflow L_54
val x_274 = (x_264,
x_275,
global_2)
fun L_55 () =
let
fun loop_i_0 (x_284,
x_283,
x_282,
x_281,
x_280,
x_279,
x_278,
x_277,
x_276) =
let
fun L_56 () =
let
val tuple_5 = (x_251,
x_246)
fun x_2 (x_290,
x_289,
x_288,
x_287,
x_286) =
let
fun L_57 () =
let
fun L_59 () =
raise (x_289)
val x_293 = Int_addCheck (x_287,
x_287) Overflow L_59
val x_294 = #2 x_290
val x_295 = #1 x_290
fun L_62 () =
raise (x_289)
val x_292 = Int_addCheck (x_286,
global_3) Overflow L_62
in
x_2 (x_290,
x_295,
x_294,
x_293,
x_292)
end
fun L_63 () =
let
fun L_64 () =
let
val tuple_6 = (x_250,
x_252,
x_264,
update_6,
sub_13,
x_262,
x_251,
x_287,
tpi_2,
div_3,
x_286)
fun x_3 (env_24,
x_297) =
let
val x_299 = #13 env_24
val m_1 = #12 env_24
val div_5 = #11 env_24
val tpi_3 = #10 env_24
val n_5 = #9 env_24
val x_300 = #8 env_24
val pxr_8 = #7 env_24
val sub_15 = #6 env_24
val update_8 = #5 env_24
val pxi_8 = #4 env_24
val x_301 = #3 env_24
val x_302 = #2 env_24
val loop_k_1 = #1 env_24
fun L_65 () =
let
val tuple_7 = (x_250,
x_252,
x_264,
update_6,
sub_13,
x_262,
x_251,
x_287)
fun x_4 (env_25,
x_303) =
let
val x_305 = #10 env_25
val n_6 = #9 env_25
val x_306 = #8 env_25
val pxr_9 = #7 env_25
val sub_16 = #6 env_25
val update_9 = #5 env_25
val pxi_9 = #4 env_25
val x_307 = #3 env_25
val x_308 = #2 env_25
val loop_is_1 = #1 env_25
fun L_66 () =
let
val tuple_8 = (x_251,
div_3,
x_250,
x_264,
update_6,
sub_13,
x_262,
x_287)
fun x_5 (env_26,
x_309) =
let
val x_311 = #10 env_26
val n_7 = #9 env_26
val pxr_10 = #8 env_26
val sub_17 = #7 env_26
val update_10 = #6 env_26
val pxi_10 = #5 env_26
val x_312 = #4 env_26
val div_6 = #3 env_26
val x_313 = #2 env_26
val loop_i_4 = #1 env_26
fun L_67 () =
let
val tuple_9 = (x_246,
x_251,
x_262,
sub_13,
x_264)
fun x_6 (env_27) =
let
val x_315 = #9 env_27
val x_316 = #8 env_27
val x_317 = #7 env_27
val pxr_11 = #6 env_27
val sub_18 = #5 env_27
val x_318 = #4 env_27
val pxi_11 = #3 env_27
val x_319 = #2 env_27
val loop_i_6 = #1 env_27
fun L_68 () =
let
fun L_69 (x_320) =
let
fun L_70 (x_321) =
let
fun L_71 (x_323) =
let
val x_324 = Real_class (x_323)
fun L_72 () =
let
fun L_74 () =
raise (x_251)
val x_325 = Int_addCheck (x_248,
global_3) Overflow L_74
fun L_75 (x_326) =
let
fun L_77 () =
raise (x_252)
val x_327 = Int_mulCheck (x_246,
global_39) Overflow L_77
in
x_1 (x_326,
x_327)
end
in
L_75 (loop_np_0 (loop_np_1,
x_325))
end
fun L_80 () =
let
val x_329 = (x_253,
global_43)
val x_328 = ::_0 (x_329)
fun L_82 (x_330) =
let
val x_332 = Stdio_sprintf (buffer_1,
x_330,
x_323)
val x_333 = Array_length (buffer_1)
fun L_83 () =
raise (x_254)
fun L_84 () =
let
fun L_132 (x_334) =
let
fun loop_11 (x_339,
x_338,
x_337,
x_336,
x_335) =
let
val x_340 = MLton_eq (x_335,
x_339)
fun L_133 () =
let
val x_343 = Vector_fromArray (x_334)
val x_342 = String_fromCharVector (x_343)
val x_344 = String_size (x_342)
fun L_87 () =
raise (x_250)
val x_341 = Int_subCheck (x_344,
global_3) Overflow L_87
fun loop_3 (x_349,
x_348,
x_347,
x_346,
x_345) =
let
fun L_88 () =
let
fun loop_4 (x_354,
x_353,
x_352,
x_351) =
let
fun L_89 () =
let
fun loop_5 (x_356,
x_355) =
let
fun L_90 () =
let
fun L_488 (x_357) =
L_72 ()
in
L_488 (concat_1 (concat_3,
x_355))
end
fun L_92 (x_358) =
let
val x_360 = #2 x_358
val x_361 = #1 x_358
val x_362 = (x_361,
x_355)
val x_359 = ::_0 (x_362)
in
loop_5 (x_360,
x_359)
end
in
case x_356 of
::_0 => L_92
| nil_0 => L_90
end
in
loop_5 (x_351,
global_14)
end
fun L_93 (x_363) =
let
val x_365 = #2 x_363
val x_364 = #1 x_363
fun L_94 (x_366) =
let
val x_368 = (x_366,
x_351)
val x_367 = ::_0 (x_368)
in
loop_4 (x_354,
x_353,
x_365,
x_367)
end
fun L_95 () =
let
fun L_107 (x_369) =
let
fun loop_8 (x_373,
x_372,
x_371,
x_370) =
let
val x_374 = MLton_eq (x_370,
global_3)
fun L_108 () =
L_94 (x_47 (x_369))
fun L_109 () =
let
val x_376 = Array_update (x_372,
x_370,
x_373)
fun L_112 () =
raise (x_371)
val x_375 = Int_addCheck (x_370,
global_3) Overflow L_112
in
loop_8 (x_373,
x_372,
x_371,
x_375)
end
in
case x_374 of
false => L_109
| true => L_108
end
in
loop_8 (x_364,
x_369,
x_353,
global_1)
end
in
L_107 (array_3 (x_354,
global_3))
end
fun L_114 () =
L_94 (global_44)
in
case x_364 of
- => L_114
| _ => L_95
end
in
case x_352 of
::_1 => L_93
| nil_1 => L_89
end
in
loop_4 (array_7,
x_251,
x_345,
global_14)
end
fun L_115 () =
let
fun L_117 () =
raise (x_349)
val x_378 = Int_subCheck (x_346,
global_3) Overflow L_117
val x_377 = (x_348,
x_346)
fun L_118 (x_379) =
let
val x_381 = (x_379,
x_345)
val x_380 = ::_1 (x_381)
in
loop_3 (x_349,
x_348,
x_347,
x_378,
x_380)
end
in
L_118 (sub_1 (x_347,
x_377))
end
val x_350 = Int_lt (x_346,
global_1)
in
case x_350 of
false => L_115
| true => L_88
end
in
loop_3 (x_250,
x_342,
sub_14,
x_341,
global_12)
end
fun L_134 () =
let
fun L_135 (x_383) =
let
val x_385 = Array_update (x_337,
x_335,
x_383)
fun L_137 () =
raise (x_336)
val x_384 = Int_addCheck (x_335,
global_3) Overflow L_137
in
loop_11 (x_339,
x_338,
x_337,
x_336,
x_384)
end
fun x_382 (env_28,
x_386) =
let
val x_387 = Array_sub (env_28,
x_386)
in
L_135 (x_387)
end
in
x_382 (x_338,
x_335)
end
in
case x_340 of
false => L_134
| true => L_133
end
in
loop_11 (x_332,
buffer_1,
x_334,
x_251,
global_1)
end
fun array_8 (env_29,
x_388) =
L_132 (x_39 (env_29,
x_388))
in
array_8 (array_6,
x_332)
end
fun L_140 () =
let
val x_390 = Int_sub (x_333,
x_332)
val x_389 = Int_gt (global_1,
x_390)
in
case x_389 of
false => L_84
| true => L_83
end
val x_331 = Int_lt (x_332,
global_1)
in
case x_331 of
false => L_140
| true => L_83
end
in
L_82 (concat_1 (concat_3,
x_328))
end
fun L_149 () =
raise (global_45)
in
case x_324 of
0 => L_72
| 1 => L_72
| 2 => L_72
| 3 => L_72
| 4 => L_80
| 5 => L_80
| _ => L_149
end
fun L_152 () =
L_71 (x_319)
fun L_153 () =
L_71 (x_318)
val x_322 = Real_lt (x_320,
x_321)
in
case x_322 of
false => L_153
| true => L_152
end
in
L_70 (abs_0 (x_319))
end
in
L_69 (abs_0 (x_318))
end
fun L_156 () =
let
fun L_158 () =
raise (x_317)
val x_392 = Int_addCheck (x_315,
global_3) Overflow L_158
val x_391 = (pxr_11,
x_392)
fun L_159 (x_393) =
let
val x_395 = Real_fromInt (x_315)
val x_394 = Real_sub (x_393,
x_395)
fun L_160 (x_396) =
let
fun L_161 (x_398) =
let
fun L_163 () =
raise (x_317)
val x_400 = Int_addCheck (x_315,
global_3) Overflow L_163
val x_399 = (pxi_11,
x_400)
fun L_164 (x_401) =
let
fun L_165 (x_402) =
let
fun L_166 (x_404) =
let
fun L_168 () =
raise (x_317)
val x_405 = Int_addCheck (x_315,
global_3) Overflow L_168
fun L_171 (env_30) =
x_406 (env_30)
fun L_173 (env_31) =
L_171 (x_407 (env_31,
x_404))
fun L_175 (env_32) =
L_173 (x_408 (env_32,
x_398))
in
L_175 (loop_i_5 (loop_i_6,
x_405))
end
fun L_178 () =
L_166 (x_402)
fun L_179 () =
L_166 (x_319)
val x_403 = Real_lt (x_319,
x_402)
in
case x_403 of
false => L_179
| true => L_178
end
in
L_165 (abs_0 (x_401))
end
in
L_164 (sub_19 (sub_18,
x_399))
end
fun L_182 () =
L_161 (x_396)
fun L_183 () =
L_161 (x_318)
val x_397 = Real_lt (x_318,
x_396)
in
case x_397 of
false => L_183
| true => L_182
end
in
L_160 (abs_0 (x_394))
end
in
L_159 (sub_19 (sub_18,
x_391))
end
val x_314 = Int_ge (x_315,
x_316)
in
case x_314 of
false => L_156
| true => L_68
end
fun x_406 (env_33) =
let
val loop_i_7 = #9 env_33
val x_410 = #8 env_33
val pxi_12 = #7 env_33
val x_411 = #6 env_33
val sub_20 = #5 env_33
val pxr_12 = #4 env_33
val x_412 = #3 env_33
val x_413 = #2 env_33
val x_414 = #1 env_33
val x_409 = (loop_i_7,
x_410,
pxi_12,
x_411,
sub_20,
pxr_12,
x_412,
x_413,
x_414)
in
x_6 (x_409)
end
fun L_188 (env_34) =
x_406 (env_34)
fun L_190 (env_35) =
L_188 (x_407 (env_35,
global_2))
fun L_192 (env_36) =
L_190 (x_408 (env_36,
global_2))
in
L_192 (loop_i_5 (tuple_9,
global_1))
end
fun L_194 () =
let
fun L_195 () =
let
val tuple_10 = (x_312,
div_6,
x_313)
val x_416 = (n_7,
global_39)
fun L_196 (x_417) =
let
fun x_7 (x_423,
x_422,
x_421,
x_420,
x_419,
x_418) =
let
fun L_197 () =
let
val x_425 = (x_419,
global_39)
fun L_198 (x_426) =
let
val x_428 = #3 x_422
val div_7 = #2 x_422
val x_429 = #1 x_422
fun L_201 () =
raise (x_423)
val x_427 = Int_subCheck (x_418,
x_419) Overflow L_201
in
x_7 (x_429,
x_422,
div_7,
x_428,
x_426,
x_427)
end
in
L_198 (div_4 (x_421,
x_425))
end
fun L_203 () =
let
fun L_205 () =
raise (x_420)
val x_431 = Int_addCheck (x_418,
x_419) Overflow L_205
fun L_207 () =
raise (x_313)
val x_430 = Int_addCheck (x_311,
global_3) Overflow L_207
fun L_208 (env_37) =
x_5 (env_37,
x_431)
in
L_208 (loop_i_3 (loop_i_4,
x_430))
end
val x_424 = Int_lt (x_419,
x_418)
in
case x_424 of
false => L_203
| true => L_197
end
in
x_7 (x_312,
tuple_10,
div_6,
x_313,
x_417,
x_309)
end
in
L_196 (div_4 (div_6,
x_416))
end
fun L_212 () =
let
val x_432 = (pxr_10,
x_309)
fun L_213 (x_433) =
let
val x_434 = (pxr_10,
x_311)
fun L_214 (x_435) =
let
val x_436 = (pxr_10,
x_309,
x_435)
fun L_215 () =
let
val x_437 = (pxr_10,
x_311,
x_433)
fun L_216 () =
let
val x_438 = (pxi_10,
x_309)
fun L_217 (x_439) =
let
val x_440 = (pxi_10,
x_311)
fun L_218 (x_441) =
let
val x_442 = (pxi_10,
x_309,
x_441)
fun L_219 () =
let
val x_443 = (pxi_10,
x_311,
x_439)
in
L_195 (update_7 (update_10,
x_443))
end
in
L_219 (update_7 (update_10,
x_442))
end
in
L_218 (sub_19 (sub_17,
x_440))
end
in
L_217 (sub_19 (sub_17,
x_438))
end
in
L_216 (update_7 (update_10,
x_437))
end
in
L_215 (update_7 (update_10,
x_436))
end
in
L_214 (sub_19 (sub_17,
x_434))
end
in
L_213 (sub_19 (sub_17,
x_432))
end
val x_415 = Int_lt (x_311,
x_309)
in
case x_415 of
false => L_195
| true => L_212
end
val x_310 = Int_ge (x_311,
n_7)
in
case x_310 of
false => L_194
| true => L_67
end
fun L_229 (env_38) =
x_5 (env_38,
global_3)
in
L_229 (loop_i_3 (tuple_8,
global_3))
end
fun L_231 () =
let
fun loop_i0_0 (x_451,
x_450,
x_449,
x_448,
x_447,
x_446,
x_445,
x_444) =
let
fun L_232 () =
let
fun L_234 () =
raise (x_307)
val x_454 = Int_mulCheck (global_39,
x_303) Overflow L_234
fun L_236 () =
raise (x_308)
val x_453 = Int_subCheck (x_454,
global_3) Overflow L_236
fun L_237 (x_455) =
let
fun L_239 () =
raise (x_307)
val x_456 = Int_mulCheck (global_46,
x_303) Overflow L_239
in
x_4 (x_455,
x_456)
end
in
L_237 (loop_is_0 (loop_is_1,
x_453))
end
fun L_242 () =
let
fun L_244 () =
raise (x_450)
val x_458 = Int_addCheck (x_444,
global_3) Overflow L_244
val x_457 = (x_449,
x_444)
fun L_245 (x_459) =
let
val x_460 = (x_449,
x_458)
fun L_246 (x_461) =
let
val x_463 = Real_add (x_459,
x_461)
val x_462 = (x_449,
x_444,
x_463)
fun L_247 () =
let
val x_464 = (x_449,
x_458)
fun L_248 (x_465) =
let
val x_467 = Real_sub (x_459,
x_465)
val x_466 = (x_449,
x_458,
x_467)
fun L_249 () =
let
val x_468 = (x_446,
x_444)
fun L_250 (x_469) =
let
val x_470 = (x_446,
x_458)
fun L_251 (x_471) =
let
val x_473 = Real_add (x_469,
x_471)
val x_472 = (x_446,
x_444,
x_473)
fun L_252 () =
let
val x_474 = (x_446,
x_458)
fun L_253 (x_475) =
let
val x_477 = Real_sub (x_469,
x_475)
val x_476 = (x_446,
x_458,
x_477)
fun L_254 () =
let
fun L_256 () =
raise (x_450)
val x_478 = Int_addCheck (x_444,
x_445) Overflow L_256
in
loop_i0_0 (x_451,
x_450,
x_449,
x_448,
x_447,
x_446,
x_445,
x_478)
end
in
L_254 (update_7 (x_447,
x_476))
end
in
L_253 (sub_19 (x_448,
x_474))
end
in
L_252 (update_7 (x_447,
x_472))
end
in
L_251 (sub_19 (x_448,
x_470))
end
in
L_250 (sub_19 (x_448,
x_468))
end
in
L_249 (update_7 (x_447,
x_466))
end
in
L_248 (sub_19 (x_448,
x_464))
end
in
L_247 (update_7 (x_447,
x_462))
end
in
L_246 (sub_19 (x_448,
x_460))
end
in
L_245 (sub_19 (x_448,
x_457))
end
val x_452 = Int_gt (x_444,
x_451)
in
case x_452 of
false => L_242
| true => L_232
end
in
loop_i0_0 (n_6,
x_306,
pxr_9,
sub_16,
update_9,
pxi_9,
x_303,
x_305)
end
val x_304 = Int_ge (x_305,
n_6)
in
case x_304 of
false => L_231
| true => L_66
end
fun L_267 (env_39) =
x_4 (env_39,
global_46)
in
L_267 (loop_is_0 (tuple_7,
global_3))
end
fun L_269 () =
let
val x_479 = (x_297,
global_46)
fun L_270 (x_480) =
let
val x_481 = Real_fromInt (x_297)
val x_482 = Real_div (tpi_3,
x_481)
val tuple_11 = (x_482,
n_5,
x_300,
pxr_8,
sub_15,
update_8,
pxi_8,
x_301,
x_297,
x_302,
x_480)
fun x_8 (env_40,
x_483) =
let
val x_485 = #13 env_40
val n4_2 = #12 env_40
val x_486 = #11 env_40
val x_487 = #10 env_40
val x_488 = #9 env_40
val pxi_13 = #8 env_40
val update_11 = #7 env_40
val sub_21 = #6 env_40
val pxr_13 = #5 env_40
val x_489 = #4 env_40
val n_8 = #3 env_40
val loop_j_1 = #2 env_40
val e_1 = #1 env_40
fun L_271 () =
let
fun L_273 () =
raise (x_300)
val x_490 = Int_addCheck (x_299,
global_3) Overflow L_273
fun L_274 (x_491) =
let
val x_492 = (x_297,
global_39)
fun L_275 (x_493) =
x_3 (x_491,
x_493)
in
L_275 (div_4 (div_5,
x_492))
end
in
L_274 (loop_k_0 (loop_k_1,
x_490))
end
fun L_279 () =
let
val x_494 = Real_mul (global_47,
x_483)
val x_495 = Real_Math_cos (x_483)
val x_496 = Real_Math_sin (x_483)
val x_497 = Real_Math_cos (x_494)
val x_498 = Real_Math_sin (x_494)
val tuple_12 = (x_485,
x_486,
x_487,
x_488,
x_498,
x_497,
x_496,
x_495,
pxi_13,
update_11,
sub_21,
pxr_13,
x_489,
n4_2,
n_8)
fun L_280 (x_499) =
let
fun L_282 () =
raise (x_488)
val x_500 = Int_mulCheck (global_39,
x_487) Overflow L_282
fun x_9 (env_41,
x_501) =
let
val x_503 = #17 env_41
val n_9 = #16 env_41
val n4_3 = #15 env_41
val x_504 = #14 env_41
val pxr_14 = #13 env_41
val sub_22 = #12 env_41
val update_12 = #11 env_41
val pxi_14 = #10 env_41
val cc1_1 = #9 env_41
val ss1_1 = #8 env_41
val cc3_1 = #7 env_41
val ss3_1 = #6 env_41
val x_505 = #5 env_41
val x_506 = #4 env_41
val x_507 = #3 env_41
val x_508 = #2 env_41
val loop_is_3 = #1 env_41
fun L_283 () =
let
fun L_285 () =
raise (x_489)
val x_509 = Int_addCheck (x_485,
global_3) Overflow L_285
fun L_286 (x_510) =
let
val x_512 = Real_fromInt (x_485)
val x_511 = Real_mul (e_1,
x_512)
in
x_8 (x_510,
x_511)
end
in
L_286 (loop_j_0 (loop_j_1,
x_509))
end
fun L_289 () =
let
fun loop_i0_1 (x_525,
x_524,
x_523,
x_522,
x_521,
x_520,
x_519,
x_518,
x_517,
x_516,
x_515,
x_514,
x_513) =
let
fun L_290 () =
let
fun L_292 () =
raise (x_505)
val x_528 = Int_mulCheck (global_39,
x_501) Overflow L_292
fun L_294 () =
raise (x_507)
val x_529 = Int_subCheck (x_528,
x_506) Overflow L_294
fun L_296 () =
raise (x_504)
val x_527 = Int_addCheck (x_529,
x_508) Overflow L_296
fun L_297 (x_530) =
let
fun L_299 () =
raise (x_505)
val x_531 = Int_mulCheck (global_46,
x_501) Overflow L_299
in
x_9 (x_530,
x_531)
end
in
L_297 (loop_is_2 (loop_is_3,
x_527))
end
fun L_302 () =
let
fun L_304 () =
raise (x_523)
val x_533 = Int_addCheck (x_513,
x_524) Overflow L_304
fun L_306 () =
raise (x_523)
val x_534 = Int_addCheck (x_533,
x_524) Overflow L_306
fun L_308 () =
raise (x_523)
val x_535 = Int_addCheck (x_534,
x_524) Overflow L_308
val x_532 = (x_522,
x_513)
fun L_309 (x_536) =
let
val x_537 = (x_522,
x_534)
fun L_310 (x_538) =
let
val x_540 = Real_sub (x_536,
x_538)
val x_539 = (x_522,
x_513)
fun L_311 (x_541) =
let
val x_542 = (x_522,
x_534)
fun L_312 (x_543) =
let
val x_545 = Real_add (x_541,
x_543)
val x_544 = (x_522,
x_513,
x_545)
fun L_313 () =
let
val x_546 = (x_522,
x_533)
fun L_314 (x_547) =
let
val x_548 = (x_522,
x_535)
fun L_315 (x_549) =
let
val x_551 = Real_sub (x_547,
x_549)
val x_550 = (x_522,
x_533)
fun L_316 (x_552) =
let
val x_553 = (x_522,
x_535)
fun L_317 (x_554) =
let
val x_556 = Real_add (x_552,
x_554)
val x_555 = (x_522,
x_533,
x_556)
fun L_318 () =
let
val x_557 = (x_519,
x_513)
fun L_319 (x_558) =
let
val x_559 = (x_519,
x_534)
fun L_320 (x_560) =
let
val x_562 = Real_sub (x_558,
x_560)
val x_561 = (x_519,
x_513)
fun L_321 (x_563) =
let
val x_564 = (x_519,
x_534)
fun L_322 (x_565) =
let
val x_567 = Real_add (x_563,
x_565)
val x_566 = (x_519,
x_513,
x_567)
fun L_323 () =
let
val x_568 = (x_519,
x_533)
fun L_324 (x_569) =
let
val x_570 = (x_519,
x_535)
fun L_325 (x_571) =
let
val x_573 = Real_sub (x_569,
x_571)
val x_572 = (x_519,
x_533)
fun L_326 (x_574) =
let
val x_575 = (x_519,
x_535)
fun L_327 (x_576) =
let
val x_578 = Real_add (x_574,
x_576)
val x_577 = (x_519,
x_533,
x_578)
fun L_328 () =
let
val x_580 = Real_sub (x_540,
x_573)
val x_581 = Real_add (x_540,
x_573)
val x_582 = Real_sub (x_551,
x_562)
val x_583 = Real_add (x_551,
x_562)
val x_584 = Real_mul (x_581,
x_518)
val x_585 = Real_mul (x_582,
x_517)
val x_586 = Real_sub (x_584,
x_585)
val x_579 = (x_522,
x_534,
x_586)
fun L_329 () =
let
val x_588 = Real_neg (x_582)
val x_589 = Real_mul (x_588,
x_518)
val x_590 = Real_mul (x_581,
x_517)
val x_591 = Real_sub (x_589,
x_590)
val x_587 = (x_519,
x_534,
x_591)
fun L_330 () =
let
val x_593 = Real_mul (x_580,
x_516)
val x_594 = Real_mul (x_583,
x_515)
val x_595 = Real_add (x_593,
x_594)
val x_592 = (x_522,
x_535,
x_595)
fun L_331 () =
let
val x_597 = Real_mul (x_583,
x_516)
val x_598 = Real_mul (x_580,
x_515)
val x_599 = Real_sub (x_597,
x_598)
val x_596 = (x_519,
x_535,
x_599)
fun L_332 () =
let
fun L_334 () =
raise (x_523)
val x_600 = Int_addCheck (x_513,
x_514) Overflow L_334
in
loop_i0_1 (x_525,
x_524,
x_523,
x_522,
x_521,
x_520,
x_519,
x_518,
x_517,
x_516,
x_515,
x_514,
x_600)
end
in
L_332 (update_7 (x_520,
x_596))
end
in
L_331 (update_7 (x_520,
x_592))
end
in
L_330 (update_7 (x_520,
x_587))
end
in
L_329 (update_7 (x_520,
x_579))
end
in
L_328 (update_7 (x_520,
x_577))
end
in
L_327 (sub_19 (x_521,
x_575))
end
in
L_326 (sub_19 (x_521,
x_572))
end
in
L_325 (sub_19 (x_521,
x_570))
end
in
L_324 (sub_19 (x_521,
x_568))
end
in
L_323 (update_7 (x_520,
x_566))
end
in
L_322 (sub_19 (x_521,
x_564))
end
in
L_321 (sub_19 (x_521,
x_561))
end
in
L_320 (sub_19 (x_521,
x_559))
end
in
L_319 (sub_19 (x_521,
x_557))
end
in
L_318 (update_7 (x_520,
x_555))
end
in
L_317 (sub_19 (x_521,
x_553))
end
in
L_316 (sub_19 (x_521,
x_550))
end
in
L_315 (sub_19 (x_521,
x_548))
end
in
L_314 (sub_19 (x_521,
x_546))
end
in
L_313 (update_7 (x_520,
x_544))
end
in
L_312 (sub_19 (x_521,
x_542))
end
in
L_311 (sub_19 (x_521,
x_539))
end
in
L_310 (sub_19 (x_521,
x_537))
end
in
L_309 (sub_19 (x_521,
x_532))
end
val x_526 = Int_ge (x_513,
x_525)
in
case x_526 of
false => L_302
| true => L_290
end
in
loop_i0_1 (n_9,
n4_3,
x_504,
pxr_14,
sub_22,
update_12,
pxi_14,
cc1_1,
ss1_1,
cc3_1,
ss3_1,
x_501,
x_503)
end
val x_502 = Int_ge (x_503,
n_9)
in
case x_502 of
false => L_289
| true => L_283
end
in
x_9 (x_499,
x_500)
end
in
L_280 (loop_is_2 (tuple_12,
x_485))
end
val x_484 = Int_gt (x_485,
n4_2)
in
case x_484 of
false => L_279
| true => L_271
end
fun L_360 (env_42) =
x_8 (env_42,
global_2)
in
L_360 (loop_j_0 (tuple_11,
global_3))
end
in
L_270 (div_4 (div_5,
x_479))
end
val x_298 = Int_ge (x_299,
m_1)
in
case x_298 of
false => L_269
| true => L_65
end
fun L_363 (env_43) =
x_3 (env_43,
x_287)
in
L_363 (loop_k_0 (tuple_6,
global_3))
end
fun L_365 () =
let
fun L_367 () =
raise (x_251)
val x_601 = Int_addCheck (x_246,
global_3) Overflow L_367
fun loop_12 (x_607,
x_606,
x_605,
x_604,
x_603,
x_602) =
let
fun L_368 () =
L_64 (x_256 (x_249,
x_287))
fun L_371 () =
let
val x_609 = (x_606,
x_602,
global_2)
fun L_372 () =
let
val x_610 = (x_604,
x_602,
global_2)
fun L_373 () =
let
fun L_375 () =
raise (x_603)
val x_611 = Int_addCheck (x_602,
global_3) Overflow L_375
in
loop_12 (x_607,
x_606,
x_605,
x_604,
x_603,
x_611)
end
in
L_373 (update_7 (x_605,
x_610))
end
in
L_372 (update_7 (x_605,
x_609))
end
val x_608 = Int_gt (x_602,
x_607)
in
case x_608 of
false => L_371
| true => L_368
end
in
loop_12 (x_287,
x_262,
update_6,
x_264,
x_251,
x_601)
end
val x_296 = MLton_eq (x_287,
x_246)
in
case x_296 of
false => L_365
| true => L_64
end
val x_291 = Int_lt (x_287,
x_288)
in
case x_291 of
false => L_63
| true => L_57
end
in
x_2 (tuple_5,
x_251,
x_246,
global_39,
global_3)
end
fun L_380 () =
let
fun L_382 () =
raise (x_282)
val x_613 = Int_subCheck (x_283,
x_276) Overflow L_382
fun L_384 () =
raise (x_281)
val x_614 = Int_addCheck (x_276,
global_3) Overflow L_384
val x_612 = (x_280,
x_614,
global_42)
fun L_385 () =
let
fun L_387 () =
raise (x_281)
val x_616 = Int_addCheck (x_613,
global_3) Overflow L_387
val x_615 = (x_280,
x_616,
global_42)
fun L_388 () =
let
val x_618 = Real_fromInt (x_276)
val x_619 = Real_mul (x_278,
x_618)
val x_620 = Real_Math_cos (x_619)
val x_621 = Real_Math_sin (x_619)
val x_622 = Real_div (x_620,
x_621)
val x_623 = Real_mul (global_42,
x_622)
fun L_390 () =
raise (x_281)
val x_624 = Int_addCheck (x_276,
global_3) Overflow L_390
val x_617 = (x_277,
x_624,
x_623)
fun L_391 () =
let
fun L_393 () =
raise (x_281)
val x_626 = Int_addCheck (x_613,
global_3) Overflow L_393
val x_627 = Real_neg (x_623)
val x_625 = (x_277,
x_626,
x_627)
fun L_394 () =
let
fun L_396 () =
raise (x_281)
val x_628 = Int_addCheck (x_276,
global_3) Overflow L_396
in
loop_i_0 (x_284,
x_283,
x_282,
x_281,
x_280,
x_279,
x_278,
x_277,
x_628)
end
in
L_394 (update_7 (x_279,
x_625))
end
in
L_391 (update_7 (x_279,
x_617))
end
in
L_388 (update_7 (x_279,
x_615))
end
in
L_385 (update_7 (x_279,
x_612))
end
val x_285 = Int_gt (x_276,
x_284)
in
case x_285 of
false => L_380
| true => L_56
end
in
loop_i_0 (x_261,
x_246,
x_250,
x_251,
x_262,
update_6,
x_266,
x_264,
global_3)
end
in
L_55 (update_7 (update_6,
x_274))
end
in
L_52 (update_7 (update_6,
x_272))
end
in
L_49 (div_4 (div_3,
x_270))
end
in
L_48 (update_7 (update_6,
x_269))
end
in
L_47 (update_7 (update_6,
x_265))
end
in
L_46 (new_2 (new_1,
x_263))
end
in
L_43 (new_2 (new_1,
x_260))
end
in
L_38 (div_4 (div_3,
x_257))
end
in
L_37 (x_256 (x_249,
x_246))
end
val x_247 = Int_gt (x_248,
global_48)
in
case x_247 of
false => L_36
| true => L_33
end
fun L_410 (env_44) =
x_1 (env_44,
global_49)
in
L_410 (loop_np_0 (x_244,
global_3))
end
in
case x_245 of
false => L_32
| true => L_30
end
in
loop_2 (tuple_4,
global_30,
global_36)
end
in
L_29 (concat_1 (tuple_1, x_236))
end
in
L_28 (x_151 (x_231, global_33))
end
fun makeBuffer_0 (env_45, x_629) =
L_27 (x_39 (env_45, x_629))
in
makeBuffer_0 (global_29, global_28)
end
in
case x_230 of
::_2 => loop_1 | nil_2 => L_26
end
in
loop_1 (global_17)
end
==> raise: x_406 has no Shrink.info property