aboutsummaryrefslogtreecommitdiffstats
path: root/test/libyul/yulOptimizerTests/ssaAndBack/multi_assign_switch.yul
diff options
context:
space:
mode:
Diffstat (limited to 'test/libyul/yulOptimizerTests/ssaAndBack/multi_assign_switch.yul')
-rw-r--r--test/libyul/yulOptimizerTests/ssaAndBack/multi_assign_switch.yul32
1 files changed, 32 insertions, 0 deletions
diff --git a/test/libyul/yulOptimizerTests/ssaAndBack/multi_assign_switch.yul b/test/libyul/yulOptimizerTests/ssaAndBack/multi_assign_switch.yul
new file mode 100644
index 00000000..1efbbde7
--- /dev/null
+++ b/test/libyul/yulOptimizerTests/ssaAndBack/multi_assign_switch.yul
@@ -0,0 +1,32 @@
+{
+ let a := mload(0)
+ switch mload(1)
+ case 0 {
+ a := mload(1)
+ a := mload(2)
+ a := mload(3)
+ }
+ default {
+ a := mload(4)
+ a := mload(5)
+ a := mload(6)
+ }
+ mstore(a, 0)
+}
+// ----
+// ssaAndBack
+// {
+// let a := mload(0)
+// switch mload(1)
+// case 0 {
+// pop(mload(1))
+// pop(mload(2))
+// a := mload(3)
+// }
+// default {
+// pop(mload(4))
+// pop(mload(5))
+// a := mload(6)
+// }
+// mstore(a, 0)
+// }