Merge pull request #6425 from ethereum/test-requiring-constantinople

Add bitshift optimizer tests
This commit is contained in:
chriseth 2019-04-03 22:41:22 +02:00 committed by GitHub
commit d29ea5c4ed
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 32 additions and 0 deletions

View File

@ -0,0 +1,16 @@
{
let a := and(0xff, shr(248, calldataload(0)))
let b := and(shr(248, calldataload(0)), 0xff)
let c := and(shr(249, calldataload(0)), 0xfa)
let d := and(shr(247, calldataload(0)), 0xff)
}
// ====
// EVMVersion: >byzantium
// step: expressionSimplifier
// ----
// {
// let a := shr(248, calldataload(0))
// let b := shr(248, calldataload(0))
// let c := and(shr(249, calldataload(0)), 0xfa)
// let d := and(shr(247, calldataload(0)), 0xff)
// }

View File

@ -0,0 +1,16 @@
{
let a := shl(299, calldataload(0))
let b := shr(299, calldataload(1))
let c := shl(255, calldataload(2))
let d := shr(255, calldataload(3))
}
// ====
// EVMVersion: >byzantium
// step: expressionSimplifier
// ----
// {
// let a := 0
// let b := 0
// let c := shl(255, calldataload(2))
// let d := shr(255, calldataload(3))
// }