Skip to content

Commit

Permalink
Merge branch 'evm-equivalence-yul' into interpreter-system-calls
Browse files Browse the repository at this point in the history
  • Loading branch information
IAvecilla committed Aug 23, 2024
2 parents 81fd48d + 5cdc5dd commit f16dc4d
Show file tree
Hide file tree
Showing 4 changed files with 737 additions and 834 deletions.
7 changes: 1 addition & 6 deletions system-contracts/contracts/EvmInterpreter.template.yul
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,7 @@ object "EVMInterpreter" {
// This error should never be triggered
// require(offset > 100, "Offset too small");

mstore8(sub(offset, 100), 0xd9)
mstore8(sub(offset, 99), 0xeb)
mstore8(sub(offset, 98), 0x76)
mstore8(sub(offset, 97), 0xb2)
mstore(sub(offset, 100), 0xD9EB76B200000000000000000000000000000000000000000000000000000000)
mstore(sub(offset, 96), gasLeft)
mstore(sub(offset, 64), 0x40)
mstore(sub(offset, 32), len)
Expand Down Expand Up @@ -60,8 +57,6 @@ object "EVMInterpreter" {

function validateCorrectBytecode(offset, len, gasToReturn) -> returnGas {
if len {
// let firstByte := shr(mload(offset), 248)
// FIXME: Check this.
let firstByte := shr(248, mload(offset))
if eq(firstByte, 0xEF) {
revert(0, 0)
Expand Down
Loading

0 comments on commit f16dc4d

Please sign in to comment.