mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
yul: Add new optimizer rules for create and create2 builtins
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
{
|
||||
let a := and(create2(0, 0, 0x20, 0), 0xffffffffffffffffffffffffffffffffffffffff)
|
||||
let b := and(0xffffffffffffffffffffffffffffffffffffffff, create2(0, 0, 0x20, 0))
|
||||
}
|
||||
// ====
|
||||
// step: expressionSimplifier
|
||||
// EVMVersion: >=constantinople
|
||||
// ----
|
||||
// {
|
||||
// let a := create2(0, 0, 0x20, 0)
|
||||
// let b := create2(0, 0, 0x20, 0)
|
||||
// }
|
||||
@@ -0,0 +1,11 @@
|
||||
{
|
||||
let a := and(create(0, 0, 0x20), 0xffffffffffffffffffffffffffffffffffffffff)
|
||||
let b := and(0xffffffffffffffffffffffffffffffffffffffff, create(0, 0, 0x20))
|
||||
}
|
||||
// ====
|
||||
// step: expressionSimplifier
|
||||
// ----
|
||||
// {
|
||||
// let a := create(0, 0, 0x20)
|
||||
// let b := create(0, 0, 0x20)
|
||||
// }
|
||||
Reference in New Issue
Block a user