Skip to content

Commit

Permalink
snapshots
Browse files Browse the repository at this point in the history
  • Loading branch information
oflatt committed May 29, 2024
1 parent 47bfd2b commit e8ecb97
Show file tree
Hide file tree
Showing 55 changed files with 946 additions and 946 deletions.
6 changes: 3 additions & 3 deletions tests/snapshots/files__add-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ source: tests/files.rs
expression: visualization.result
---
@main {
.v0_:
v1_: int = const 3;
print v1_;
.b0_:
c1_: int = const 3;
print c1_;
}
6 changes: 3 additions & 3 deletions tests/snapshots/files__add_block_indirection-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ source: tests/files.rs
expression: visualization.result
---
@main {
.v0_:
v1_: int = const 3;
print v1_;
.b0_:
c1_: int = const 3;
print c1_;
}
54 changes: 27 additions & 27 deletions tests/snapshots/files__block-diamond-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,35 +3,35 @@ source: tests/files.rs
expression: visualization.result
---
@main(v0: int) {
.v1_:
v2_: int = const 2;
v3_: bool = lt v0 v2_;
.b1_:
c2_: int = const 2;
v3_: bool = lt v0 c2_;
v4_: bool = not v3_;
v5_: int = const 0;
v6_: int = const 1;
v7_: int = const 5;
v8_: bool = const true;
v9_: int = id v6_;
v10_: int = id v6_;
v11_: int = id v2_;
v12_: bool = id v8_;
br v3_ .v13_ .v14_;
.v13_:
v15_: int = const 4;
v16_: bool = const false;
v9_: int = id v15_;
v10_: int = id v6_;
v11_: int = id v2_;
v12_: bool = id v16_;
.v14_:
c5_: int = const 0;
c6_: int = const 1;
c7_: int = const 5;
c8_: bool = const true;
v9_: int = id c6_;
v10_: int = id c6_;
v11_: int = id c2_;
v12_: bool = id c8_;
br v3_ .b13_ .b14_;
.b13_:
c15_: int = const 4;
c16_: bool = const false;
v9_: int = id c15_;
v10_: int = id c6_;
v11_: int = id c2_;
v12_: bool = id c16_;
.b14_:
v17_: int = id v9_;
v18_: int = id v6_;
br v4_ .v19_ .v20_;
.v19_:
v21_: int = add v2_ v9_;
v18_: int = id c6_;
br v4_ .b19_ .b20_;
.b19_:
v21_: int = add c2_ v9_;
v17_: int = id v21_;
v18_: int = id v6_;
.v20_:
v22_: int = add v17_ v6_;
v18_: int = id c6_;
.b20_:
v22_: int = add c6_ v17_;
print v22_;
}
6 changes: 3 additions & 3 deletions tests/snapshots/files__bool-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ source: tests/files.rs
expression: visualization.result
---
@main {
.v0_:
v1_: bool = const true;
print v1_;
.b0_:
c1_: bool = const true;
print c1_;
}
16 changes: 8 additions & 8 deletions tests/snapshots/files__branch_duplicate_work-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,19 @@ source: tests/files.rs
expression: visualization.result
---
@main(v0: int) {
.v1_:
v2_: int = const 2;
v3_: bool = lt v0 v2_;
br v3_ .v4_ .v5_;
.v4_:
.b1_:
c2_: int = const 2;
v3_: bool = lt v0 c2_;
br v3_ .b4_ .b5_;
.b4_:
v6_: int = add v0 v0;
v7_: int = id v6_;
print v7_;
ret;
.v5_:
.b5_:
v8_: int = add v0 v0;
v9_: int = mul v2_ v8_;
v9_: int = mul c2_ v8_;
v7_: int = id v9_;
.v10_:
.b10_:
print v7_;
}
52 changes: 26 additions & 26 deletions tests/snapshots/files__collatz_redundant_computation-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,72 +3,72 @@ source: tests/files.rs
expression: visualization.result
---
@main(v0: int) {
.v1_:
v2_: int = const 1;
v3_: int = const 3;
v4_: int = const 2;
v5_: int = const 0;
.b1_:
c2_: int = const 1;
c3_: int = const 3;
c4_: int = const 2;
c5_: int = const 0;
v6_: int = id v0;
v7_: int = id v0;
v8_: int = id v2_;
v9_: int = id v3_;
v10_: int = id v4_;
v11_: int = id v5_;
.v12_:
v8_: int = id c2_;
v9_: int = id c3_;
v10_: int = id c4_;
v11_: int = id c5_;
.b12_:
v13_: bool = eq v7_ v8_;
v14_: bool = const false;
c14_: bool = const false;
v15_: int = id v6_;
v16_: bool = id v14_;
v16_: bool = id c14_;
v17_: int = id v7_;
v18_: int = id v7_;
v19_: int = id v9_;
v20_: int = id v10_;
v21_: int = id v11_;
br v13_ .v22_ .v23_;
.v23_:
br v13_ .b22_ .b23_;
.b23_:
v24_: int = div v7_ v10_;
v25_: int = mul v10_ v24_;
v26_: int = sub v7_ v25_;
v27_: bool = eq v11_ v26_;
print v7_;
v28_: int = mul v7_ v9_;
v29_: int = add v28_ v8_;
v30_: bool = const true;
c30_: bool = const true;
v31_: int = id v6_;
v32_: bool = id v30_;
v32_: bool = id c30_;
v33_: int = id v29_;
v34_: int = id v8_;
v35_: int = id v9_;
v36_: int = id v10_;
v37_: int = id v11_;
br v27_ .v38_ .v39_;
.v38_:
v40_: bool = const true;
br v27_ .b38_ .b39_;
.b38_:
c40_: bool = const true;
v31_: int = id v6_;
v32_: bool = id v40_;
v32_: bool = id c40_;
v33_: int = id v24_;
v34_: int = id v8_;
v35_: int = id v9_;
v36_: int = id v10_;
v37_: int = id v11_;
.v39_:
v41_: bool = const true;
.b39_:
c41_: bool = const true;
v15_: int = id v6_;
v16_: bool = id v41_;
v16_: bool = id c41_;
v17_: int = id v33_;
v18_: int = id v8_;
v19_: int = id v9_;
v20_: int = id v10_;
v21_: int = id v11_;
.v22_:
.b22_:
v42_: bool = not v13_;
v6_: int = id v6_;
v7_: int = id v17_;
v8_: int = id v8_;
v9_: int = id v9_;
v10_: int = id v10_;
v11_: int = id v11_;
br v42_ .v12_ .v43_;
.v43_:
br v42_ .b12_ .b43_;
.b43_:
print v0;
}
8 changes: 4 additions & 4 deletions tests/snapshots/files__constant_fold_simple-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ source: tests/files.rs
expression: visualization.result
---
@main {
.v0_:
v1_: int = const 3;
v2_: int = const 2;
v3_: int = div v1_ v2_;
.b0_:
c1_: int = const 3;
c2_: int = const 2;
v3_: int = div c1_ c2_;
print v3_;
}
18 changes: 9 additions & 9 deletions tests/snapshots/files__diamond-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ source: tests/files.rs
expression: visualization.result
---
@main(v0: int) {
.v1_:
.b1_:
v2_: bool = lt v0 v0;
br v2_ .v3_ .v4_;
.v3_:
v5_: int = const 1;
print v5_;
br v2_ .b3_ .b4_;
.b3_:
c5_: int = const 1;
print c5_;
ret;
.v4_:
v6_: int = const 2;
print v6_;
.v7_:
.b4_:
c6_: int = const 2;
print c6_;
.b7_:
}
18 changes: 9 additions & 9 deletions tests/snapshots/files__duplicate_branch-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ source: tests/files.rs
expression: visualization.result
---
@main(v0: int) {
.v1_:
v2_: int = const 4;
v3_: bool = lt v2_ v0;
v4_: int = id v2_;
br v3_ .v5_ .v6_;
.v5_:
v4_: int = id v2_;
.v6_:
print v2_;
.b1_:
c2_: int = const 4;
v3_: bool = lt c2_ v0;
v4_: int = id c2_;
br v3_ .b5_ .b6_;
.b5_:
v4_: int = id c2_;
.b6_:
print c2_;
}
6 changes: 3 additions & 3 deletions tests/snapshots/files__eliminate_gamma-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ source: tests/files.rs
expression: visualization.result
---
@main {
.v0_:
v1_: int = const 1;
print v1_;
.b0_:
c1_: int = const 1;
print c1_;
}
30 changes: 15 additions & 15 deletions tests/snapshots/files__eliminate_gamma_interval-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,19 @@ source: tests/files.rs
expression: visualization.result
---
@main(v0: int) {
.v1_:
v2_: bool = const false;
v3_: int = const 10;
v4_: bool = lt v0 v3_;
v5_: int = const 5;
v6_: int = const 3;
v7_: int = id v3_;
v8_: int = id v6_;
br v4_ .v9_ .v10_;
.v9_:
v11_: int = const 7;
v7_: int = id v3_;
v8_: int = id v11_;
.v10_:
print v2_;
.b1_:
c2_: bool = const false;
c3_: int = const 10;
v4_: bool = lt v0 c3_;
c5_: int = const 5;
c6_: int = const 3;
v7_: int = id c3_;
v8_: int = id c6_;
br v4_ .b9_ .b10_;
.b9_:
c11_: int = const 7;
v7_: int = id c3_;
v8_: int = id c11_;
.b10_:
print c2_;
}
6 changes: 3 additions & 3 deletions tests/snapshots/files__eliminate_loop-optimize.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ source: tests/files.rs
expression: visualization.result
---
@main {
.v0_:
v1_: int = const 1;
print v1_;
.b0_:
c1_: int = const 1;
print c1_;
}
Loading

0 comments on commit e8ecb97

Please sign in to comment.