mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Merge pull request #7390 from ethereum/sloadTest
Load resolver involving staticcall.
This commit is contained in:
commit
143e867353
27
test/libyul/yulOptimizerTests/loadResolver/staticcall.yul
Normal file
27
test/libyul/yulOptimizerTests/loadResolver/staticcall.yul
Normal file
@ -0,0 +1,27 @@
|
||||
{
|
||||
let a := 0
|
||||
let b := 1
|
||||
let c := 2
|
||||
sstore(a, b)
|
||||
mstore(900, 7)
|
||||
let d := staticcall(10000, 10, 0, 200, 0, 200)
|
||||
sstore(add(a, 1), mload(900))
|
||||
// Main test objective: replace this sload.
|
||||
mstore(0, sload(a))
|
||||
}
|
||||
// ====
|
||||
// step: loadResolver
|
||||
// EVMVersion: >=byzantium
|
||||
// ----
|
||||
// {
|
||||
// let a := 0
|
||||
// let b := 1
|
||||
// sstore(a, b)
|
||||
// let _1 := 7
|
||||
// let _2 := 900
|
||||
// mstore(_2, _1)
|
||||
// let _3 := 200
|
||||
// pop(staticcall(10000, 10, a, _3, a, _3))
|
||||
// sstore(1, mload(_2))
|
||||
// mstore(a, b)
|
||||
// }
|
Loading…
Reference in New Issue
Block a user