aboutsummaryrefslogtreecommitdiffstats
path: root/test/libyul/yulOptimizerTests/splitJoin/control_flow.yul
diff options
context:
space:
mode:
Diffstat (limited to 'test/libyul/yulOptimizerTests/splitJoin/control_flow.yul')
-rw-r--r--test/libyul/yulOptimizerTests/splitJoin/control_flow.yul26
1 files changed, 26 insertions, 0 deletions
diff --git a/test/libyul/yulOptimizerTests/splitJoin/control_flow.yul b/test/libyul/yulOptimizerTests/splitJoin/control_flow.yul
new file mode 100644
index 00000000..ad609c74
--- /dev/null
+++ b/test/libyul/yulOptimizerTests/splitJoin/control_flow.yul
@@ -0,0 +1,26 @@
+{
+ if mul(add(calldataload(0), 2), 3) {
+ for { let a := 2 } lt(a, mload(a)) { a := add(a, mul(a, 2)) } {
+ let b := mul(add(a, 2), 4)
+ sstore(b, mul(b, 2))
+ }
+ }
+}
+// ----
+// splitJoin
+// {
+// if mul(add(calldataload(0), 2), 3)
+// {
+// for {
+// let a := 2
+// }
+// lt(a, mload(a))
+// {
+// a := add(a, mul(a, 2))
+// }
+// {
+// let b := mul(add(a, 2), 4)
+// sstore(b, mul(b, 2))
+// }
+// }
+// }