aboutsummaryrefslogtreecommitdiffstats
path: root/test/libyul/yulOptimizerTests/rematerialiser/branches_for2.yul
diff options
context:
space:
mode:
authorchriseth <chris@ethereum.org>2019-01-07 21:23:40 +0800
committerGitHub <noreply@github.com>2019-01-07 21:23:40 +0800
commit3631df5d883f0b3465dc8400067e28e206f05d57 (patch)
tree5ff8de0f92939071acd00ff22b02591cd18ec2ae /test/libyul/yulOptimizerTests/rematerialiser/branches_for2.yul
parent64027265ab0eb5cd326ef2d884acb08f322697e2 (diff)
parent2e9c70add0490a5157f393c78e29bb86f67111d7 (diff)
downloaddexon-solidity-3631df5d883f0b3465dc8400067e28e206f05d57.tar.gz
dexon-solidity-3631df5d883f0b3465dc8400067e28e206f05d57.tar.zst
dexon-solidity-3631df5d883f0b3465dc8400067e28e206f05d57.zip
Merge pull request #5620 from ethereum/rematOnlyOne
[Yul] Use rematerializer if variable is only referenced once or value is "cheap".
Diffstat (limited to 'test/libyul/yulOptimizerTests/rematerialiser/branches_for2.yul')
-rw-r--r--test/libyul/yulOptimizerTests/rematerialiser/branches_for2.yul14
1 files changed, 7 insertions, 7 deletions
diff --git a/test/libyul/yulOptimizerTests/rematerialiser/branches_for2.yul b/test/libyul/yulOptimizerTests/rematerialiser/branches_for2.yul
index 6a52e045..eb092e95 100644
--- a/test/libyul/yulOptimizerTests/rematerialiser/branches_for2.yul
+++ b/test/libyul/yulOptimizerTests/rematerialiser/branches_for2.yul
@@ -1,7 +1,7 @@
{
- let a := 1
+ let a := caller()
for { pop(a) } a { pop(a) } {
- a := 7
+ a := address()
let c := a
}
let x := a
@@ -9,17 +9,17 @@
// ----
// rematerialiser
// {
-// let a := 1
+// let a := caller()
// for {
-// pop(1)
+// pop(caller())
// }
// a
// {
-// pop(7)
+// pop(address())
// }
// {
-// a := 7
-// let c := 7
+// a := address()
+// let c := address()
// }
// let x := a
// }