Skip to content

Commit

Permalink
fix mono tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Anton-4 committed Oct 7, 2023
1 parent b7923ac commit 44eedf7
Show file tree
Hide file tree
Showing 39 changed files with 1,834 additions and 1,834 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,88 +2,88 @@ procedure Bool.11 (#Attr.2, #Attr.3):
let Bool.24 : Int1 = lowlevel Eq #Attr.2 #Attr.3;
ret Bool.24;

procedure List.26 (List.172, List.173, List.174):
let List.550 : [C U64, C U64] = CallByName List.96 List.172 List.173 List.174;
let List.553 : U8 = 1i64;
let List.554 : U8 = GetTagId List.550;
let List.555 : Int1 = lowlevel Eq List.553 List.554;
if List.555 then
let List.175 : U64 = UnionAtIndex (Id 1) (Index 0) List.550;
ret List.175;
procedure List.26 (List.174, List.175, List.176):
let List.560 : [C U64, C U64] = CallByName List.98 List.174 List.175 List.176;
let List.563 : U8 = 1i64;
let List.564 : U8 = GetTagId List.560;
let List.565 : Int1 = lowlevel Eq List.563 List.564;
if List.565 then
let List.177 : U64 = UnionAtIndex (Id 1) (Index 0) List.560;
ret List.177;
else
let List.176 : U64 = UnionAtIndex (Id 0) (Index 0) List.550;
ret List.176;
let List.178 : U64 = UnionAtIndex (Id 0) (Index 0) List.560;
ret List.178;

procedure List.29 (List.317, List.318):
let List.549 : U64 = CallByName List.6 List.317;
let List.319 : U64 = CallByName Num.77 List.549 List.318;
let List.535 : List U8 = CallByName List.43 List.317 List.319;
ret List.535;
procedure List.29 (List.319, List.320):
let List.559 : U64 = CallByName List.6 List.319;
let List.321 : U64 = CallByName Num.77 List.559 List.320;
let List.545 : List U8 = CallByName List.43 List.319 List.321;
ret List.545;

procedure List.43 (List.315, List.316):
let List.547 : U64 = CallByName List.6 List.315;
let List.546 : U64 = CallByName Num.77 List.547 List.316;
let List.537 : {U64, U64} = Struct {List.316, List.546};
let List.536 : List U8 = CallByName List.49 List.315 List.537;
ret List.536;
procedure List.43 (List.317, List.318):
let List.557 : U64 = CallByName List.6 List.317;
let List.556 : U64 = CallByName Num.77 List.557 List.318;
let List.547 : {U64, U64} = Struct {List.318, List.556};
let List.546 : List U8 = CallByName List.49 List.317 List.547;
ret List.546;

procedure List.49 (List.390, List.391):
let List.544 : U64 = StructAtIndex 0 List.391;
let List.545 : U64 = 0i64;
let List.542 : Int1 = CallByName Bool.11 List.544 List.545;
if List.542 then
dec List.390;
let List.543 : List U8 = Array [];
ret List.543;
procedure List.49 (List.392, List.393):
let List.554 : U64 = StructAtIndex 0 List.393;
let List.555 : U64 = 0i64;
let List.552 : Int1 = CallByName Bool.11 List.554 List.555;
if List.552 then
dec List.392;
let List.553 : List U8 = Array [];
ret List.553;
else
let List.539 : U64 = StructAtIndex 1 List.391;
let List.540 : U64 = StructAtIndex 0 List.391;
let List.538 : List U8 = CallByName List.72 List.390 List.539 List.540;
ret List.538;
let List.549 : U64 = StructAtIndex 1 List.393;
let List.550 : U64 = StructAtIndex 0 List.393;
let List.548 : List U8 = CallByName List.72 List.392 List.549 List.550;
ret List.548;

procedure List.6 (#Attr.2):
let List.548 : U64 = lowlevel ListLen #Attr.2;
ret List.548;
let List.558 : U64 = lowlevel ListLen #Attr.2;
ret List.558;

procedure List.66 (#Attr.2, #Attr.3):
let List.571 : U8 = lowlevel ListGetUnsafe #Attr.2 #Attr.3;
ret List.571;
let List.581 : U8 = lowlevel ListGetUnsafe #Attr.2 #Attr.3;
ret List.581;

procedure List.72 (#Attr.2, #Attr.3, #Attr.4):
let List.541 : List U8 = lowlevel ListSublist #Attr.2 #Attr.3 #Attr.4;
ret List.541;
let List.551 : List U8 = lowlevel ListSublist #Attr.2 #Attr.3 #Attr.4;
ret List.551;

procedure List.80 (#Derived_gen.0, #Derived_gen.1, #Derived_gen.2, #Derived_gen.3, #Derived_gen.4):
joinpoint List.559 List.453 List.454 List.455 List.456 List.457:
let List.561 : Int1 = CallByName Num.22 List.456 List.457;
if List.561 then
let List.570 : U8 = CallByName List.66 List.453 List.456;
let List.562 : [C U64, C U64] = CallByName Test.4 List.454 List.570;
let List.567 : U8 = 1i64;
let List.568 : U8 = GetTagId List.562;
let List.569 : Int1 = lowlevel Eq List.567 List.568;
if List.569 then
let List.458 : U64 = UnionAtIndex (Id 1) (Index 0) List.562;
let List.565 : U64 = 1i64;
let List.564 : U64 = CallByName Num.51 List.456 List.565;
jump List.559 List.453 List.458 List.455 List.564 List.457;
joinpoint List.569 List.463 List.464 List.465 List.466 List.467:
let List.571 : Int1 = CallByName Num.22 List.466 List.467;
if List.571 then
let List.580 : U8 = CallByName List.66 List.463 List.466;
let List.572 : [C U64, C U64] = CallByName Test.4 List.464 List.580;
let List.577 : U8 = 1i64;
let List.578 : U8 = GetTagId List.572;
let List.579 : Int1 = lowlevel Eq List.577 List.578;
if List.579 then
let List.468 : U64 = UnionAtIndex (Id 1) (Index 0) List.572;
let List.575 : U64 = 1i64;
let List.574 : U64 = CallByName Num.51 List.466 List.575;
jump List.569 List.463 List.468 List.465 List.574 List.467;
else
dec List.453;
let List.459 : U64 = UnionAtIndex (Id 0) (Index 0) List.562;
let List.566 : [C U64, C U64] = TagId(0) List.459;
ret List.566;
dec List.463;
let List.469 : U64 = UnionAtIndex (Id 0) (Index 0) List.572;
let List.576 : [C U64, C U64] = TagId(0) List.469;
ret List.576;
else
dec List.453;
let List.560 : [C U64, C U64] = TagId(1) List.454;
ret List.560;
dec List.463;
let List.570 : [C U64, C U64] = TagId(1) List.464;
ret List.570;
in
jump List.559 #Derived_gen.0 #Derived_gen.1 #Derived_gen.2 #Derived_gen.3 #Derived_gen.4;
jump List.569 #Derived_gen.0 #Derived_gen.1 #Derived_gen.2 #Derived_gen.3 #Derived_gen.4;

procedure List.96 (List.450, List.451, List.452):
let List.557 : U64 = 0i64;
let List.558 : U64 = CallByName List.6 List.450;
let List.556 : [C U64, C U64] = CallByName List.80 List.450 List.451 List.452 List.557 List.558;
ret List.556;
procedure List.98 (List.460, List.461, List.462):
let List.567 : U64 = 0i64;
let List.568 : U64 = CallByName List.6 List.460;
let List.566 : [C U64, C U64] = CallByName List.80 List.460 List.461 List.462 List.567 List.568;
ret List.566;

procedure Num.22 (#Attr.2, #Attr.3):
let Num.294 : Int1 = lowlevel NumLt #Attr.2 #Attr.3;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
procedure List.5 (#Attr.2, #Attr.3):
let List.535 : List {} = lowlevel ListMap { xs: `#Attr.#arg1` } #Attr.2 Test.2 #Attr.3;
let List.545 : List {} = lowlevel ListMap { xs: `#Attr.#arg1` } #Attr.2 Test.2 #Attr.3;
decref #Attr.2;
ret List.535;
ret List.545;

procedure Test.2 (Test.3):
let Test.7 : {} = Struct {};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
procedure List.5 (#Attr.2, #Attr.3):
let List.535 : List [] = lowlevel ListMap { xs: `#Attr.#arg1` } #Attr.2 Test.2 #Attr.3;
let List.545 : List [] = lowlevel ListMap { xs: `#Attr.#arg1` } #Attr.2 Test.2 #Attr.3;
decref #Attr.2;
ret List.535;
ret List.545;

procedure Test.2 (Test.3):
let Test.7 : {} = Struct {};
Expand Down
44 changes: 22 additions & 22 deletions crates/compiler/test_mono/generated/capture_void_layout_task.txt
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
procedure List.18 (List.145, List.146, List.147):
let List.536 : U64 = 0i64;
let List.537 : U64 = CallByName List.6 List.145;
let List.535 : [<r>C {}, C *self {{}, []}] = CallByName List.86 List.145 List.146 List.147 List.536 List.537;
ret List.535;
procedure List.18 (List.147, List.148, List.149):
let List.546 : U64 = 0i64;
let List.547 : U64 = CallByName List.6 List.147;
let List.545 : [<r>C {}, C *self {{}, []}] = CallByName List.87 List.147 List.148 List.149 List.546 List.547;
ret List.545;

procedure List.6 (#Attr.2):
let List.546 : U64 = lowlevel ListLen #Attr.2;
ret List.546;
let List.556 : U64 = lowlevel ListLen #Attr.2;
ret List.556;

procedure List.66 (#Attr.2, #Attr.3):
let List.545 : [] = lowlevel ListGetUnsafe #Attr.2 #Attr.3;
ret List.545;

procedure List.86 (#Derived_gen.13, #Derived_gen.14, #Derived_gen.15, #Derived_gen.16, #Derived_gen.17):
joinpoint List.538 List.148 List.149 List.150 List.151 List.152:
let List.540 : Int1 = CallByName Num.22 List.151 List.152;
if List.540 then
let List.544 : [] = CallByName List.66 List.148 List.151;
let List.153 : [<r>C {}, C *self {{}, []}] = CallByName Test.29 List.149 List.544 List.150;
let List.543 : U64 = 1i64;
let List.542 : U64 = CallByName Num.51 List.151 List.543;
jump List.538 List.148 List.153 List.150 List.542 List.152;
let List.555 : [] = lowlevel ListGetUnsafe #Attr.2 #Attr.3;
ret List.555;

procedure List.87 (#Derived_gen.13, #Derived_gen.14, #Derived_gen.15, #Derived_gen.16, #Derived_gen.17):
joinpoint List.548 List.150 List.151 List.152 List.153 List.154:
let List.550 : Int1 = CallByName Num.22 List.153 List.154;
if List.550 then
let List.554 : [] = CallByName List.66 List.150 List.153;
let List.155 : [<r>C {}, C *self {{}, []}] = CallByName Test.29 List.151 List.554 List.152;
let List.553 : U64 = 1i64;
let List.552 : U64 = CallByName Num.51 List.153 List.553;
jump List.548 List.150 List.155 List.152 List.552 List.154;
else
dec List.148;
ret List.149;
dec List.150;
ret List.151;
in
jump List.538 #Derived_gen.13 #Derived_gen.14 #Derived_gen.15 #Derived_gen.16 #Derived_gen.17;
jump List.548 #Derived_gen.13 #Derived_gen.14 #Derived_gen.15 #Derived_gen.16 #Derived_gen.17;

procedure Num.22 (#Attr.2, #Attr.3):
let Num.292 : Int1 = lowlevel NumLt #Attr.2 #Attr.3;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,49 +2,49 @@ procedure Bool.1 ():
let Bool.24 : Int1 = false;
ret Bool.24;

procedure List.2 (List.100, List.101):
let List.549 : U64 = CallByName List.6 List.100;
let List.545 : Int1 = CallByName Num.22 List.101 List.549;
if List.545 then
let List.547 : Str = CallByName List.66 List.100 List.101;
inc List.547;
dec List.100;
let List.546 : [C {}, C Str] = TagId(1) List.547;
ret List.546;
procedure List.2 (List.102, List.103):
let List.559 : U64 = CallByName List.6 List.102;
let List.555 : Int1 = CallByName Num.22 List.103 List.559;
if List.555 then
let List.557 : Str = CallByName List.66 List.102 List.103;
inc List.557;
dec List.102;
let List.556 : [C {}, C Str] = TagId(1) List.557;
ret List.556;
else
dec List.100;
let List.544 : {} = Struct {};
let List.543 : [C {}, C Str] = TagId(0) List.544;
ret List.543;
dec List.102;
let List.554 : {} = Struct {};
let List.553 : [C {}, C Str] = TagId(0) List.554;
ret List.553;

procedure List.5 (#Attr.2, #Attr.3):
let List.551 : List Str = lowlevel ListMap { xs: `#Attr.#arg1` } #Attr.2 Test.10 #Attr.3;
let List.561 : List Str = lowlevel ListMap { xs: `#Attr.#arg1` } #Attr.2 Test.10 #Attr.3;
decref #Attr.2;
ret List.551;
ret List.561;

procedure List.6 (#Attr.2):
let List.550 : U64 = lowlevel ListLen #Attr.2;
ret List.550;
let List.560 : U64 = lowlevel ListLen #Attr.2;
ret List.560;

procedure List.66 (#Attr.2, #Attr.3):
let List.548 : Str = lowlevel ListGetUnsafe #Attr.2 #Attr.3;
ret List.548;
let List.558 : Str = lowlevel ListGetUnsafe #Attr.2 #Attr.3;
ret List.558;

procedure List.9 (List.306):
let List.542 : U64 = 0i64;
let List.535 : [C {}, C Str] = CallByName List.2 List.306 List.542;
let List.539 : U8 = 1i64;
let List.540 : U8 = GetTagId List.535;
let List.541 : Int1 = lowlevel Eq List.539 List.540;
if List.541 then
let List.307 : Str = UnionAtIndex (Id 1) (Index 0) List.535;
let List.536 : [C {}, C Str] = TagId(1) List.307;
ret List.536;
procedure List.9 (List.308):
let List.552 : U64 = 0i64;
let List.545 : [C {}, C Str] = CallByName List.2 List.308 List.552;
let List.549 : U8 = 1i64;
let List.550 : U8 = GetTagId List.545;
let List.551 : Int1 = lowlevel Eq List.549 List.550;
if List.551 then
let List.309 : Str = UnionAtIndex (Id 1) (Index 0) List.545;
let List.546 : [C {}, C Str] = TagId(1) List.309;
ret List.546;
else
dec List.535;
let List.538 : {} = Struct {};
let List.537 : [C {}, C Str] = TagId(0) List.538;
ret List.537;
dec List.545;
let List.548 : {} = Struct {};
let List.547 : [C {}, C Str] = TagId(0) List.548;
ret List.547;

procedure Num.22 (#Attr.2, #Attr.3):
let Num.291 : Int1 = lowlevel NumLt #Attr.2 #Attr.3;
Expand Down
4 changes: 2 additions & 2 deletions crates/compiler/test_mono/generated/closure_in_list.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
procedure List.6 (#Attr.2):
let List.535 : U64 = lowlevel ListLen #Attr.2;
ret List.535;
let List.545 : U64 = lowlevel ListLen #Attr.2;
ret List.545;

procedure Test.1 (Test.5):
let Test.2 : I64 = 41i64;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,34 @@ procedure Bool.2 ():
let Bool.23 : Int1 = true;
ret Bool.23;

procedure List.18 (List.145, List.146, List.147):
let List.536 : U64 = 0i64;
let List.537 : U64 = CallByName List.6 List.145;
let List.535 : [<rnw><null>, C *self Int1, C *self Int1] = CallByName List.86 List.145 List.146 List.147 List.536 List.537;
ret List.535;
procedure List.18 (List.147, List.148, List.149):
let List.546 : U64 = 0i64;
let List.547 : U64 = CallByName List.6 List.147;
let List.545 : [<rnw><null>, C *self Int1, C *self Int1] = CallByName List.87 List.147 List.148 List.149 List.546 List.547;
ret List.545;

procedure List.6 (#Attr.2):
let List.546 : U64 = lowlevel ListLen #Attr.2;
ret List.546;
let List.556 : U64 = lowlevel ListLen #Attr.2;
ret List.556;

procedure List.66 (#Attr.2, #Attr.3):
let List.545 : Int1 = lowlevel ListGetUnsafe #Attr.2 #Attr.3;
ret List.545;
let List.555 : Int1 = lowlevel ListGetUnsafe #Attr.2 #Attr.3;
ret List.555;

procedure List.86 (#Derived_gen.3, #Derived_gen.4, #Derived_gen.5, #Derived_gen.6, #Derived_gen.7):
joinpoint List.538 List.148 List.149 List.150 List.151 List.152:
let List.540 : Int1 = CallByName Num.22 List.151 List.152;
if List.540 then
let List.544 : Int1 = CallByName List.66 List.148 List.151;
let List.153 : [<rnw><null>, C *self Int1, C *self Int1] = CallByName Test.6 List.149 List.544 List.150;
let List.543 : U64 = 1i64;
let List.542 : U64 = CallByName Num.51 List.151 List.543;
jump List.538 List.148 List.153 List.150 List.542 List.152;
procedure List.87 (#Derived_gen.5, #Derived_gen.6, #Derived_gen.7, #Derived_gen.8, #Derived_gen.9):
joinpoint List.548 List.150 List.151 List.152 List.153 List.154:
let List.550 : Int1 = CallByName Num.22 List.153 List.154;
if List.550 then
let List.554 : Int1 = CallByName List.66 List.150 List.153;
let List.155 : [<rnw><null>, C *self Int1, C *self Int1] = CallByName Test.6 List.151 List.554 List.152;
let List.553 : U64 = 1i64;
let List.552 : U64 = CallByName Num.51 List.153 List.553;
jump List.548 List.150 List.155 List.152 List.552 List.154;
else
dec List.148;
ret List.149;
dec List.150;
ret List.151;
in
jump List.538 #Derived_gen.3 #Derived_gen.4 #Derived_gen.5 #Derived_gen.6 #Derived_gen.7;
jump List.548 #Derived_gen.5 #Derived_gen.6 #Derived_gen.7 #Derived_gen.8 #Derived_gen.9;

procedure Num.22 (#Attr.2, #Attr.3):
let Num.292 : Int1 = lowlevel NumLt #Attr.2 #Attr.3;
Expand All @@ -46,7 +46,7 @@ procedure Str.3 (#Attr.2, #Attr.3):
procedure Test.1 (Test.5):
ret Test.5;

procedure Test.11 (#Derived_gen.8, #Derived_gen.9):
procedure Test.11 (#Derived_gen.3, #Derived_gen.4):
joinpoint Test.27 Test.12 #Attr.12:
let Test.34 : Int1 = UnionAtIndex (Id 2) (Index 1) #Attr.12;
let Test.33 : [<rnw><null>, C *self Int1, C *self Int1] = UnionAtIndex (Id 2) (Index 0) #Attr.12;
Expand Down Expand Up @@ -86,7 +86,7 @@ procedure Test.11 (#Derived_gen.8, #Derived_gen.9):
decref #Attr.12;
jump #Derived_gen.12;
in
jump Test.27 #Derived_gen.8 #Derived_gen.9;
jump Test.27 #Derived_gen.3 #Derived_gen.4;

procedure Test.2 (Test.13):
ret Test.13;
Expand Down
Loading

0 comments on commit 44eedf7

Please sign in to comment.