Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

implementation of EIP-4844: Shard Blob Transactions #1440

Merged
merged 15 commits into from
Jun 24, 2023
Merged
Prev Previous commit
disable blobHash test when evmc_enable
  • Loading branch information
jangko committed Jun 23, 2023
commit a19c072d497cb4986b2139598d2b0f28f634d080
1 change: 1 addition & 0 deletions tests/test_blockchain_json.nim
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,7 @@ proc blockchainJsonMain*(debugMode = false) =
testFixture(n, testStatusIMPL, debugMode = true, config.trace)

when isMainModule:
import std/times
var message: string

let start = getTime()
Expand Down
1 change: 1 addition & 0 deletions tests/test_generalstate_json.nim
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,7 @@ proc generalStateJsonMain*(debugMode = false) =
testFixture(n, testStatusIMPL, config.trace, true)

when isMainModule:
import std/times
var message: string

let start = getTime()
Expand Down
139 changes: 70 additions & 69 deletions tests/test_op_env.nim
Original file line number Diff line number Diff line change
Expand Up @@ -377,75 +377,76 @@ proc opEnvMain*() =
# from here onward, versionedHashes is taken from
# tx.versionedHashes = @[EMPTY_UNCLE_HASH, EMPTY_SHA3]
# preset in macro_assembler: createSignedTx
assembler:
title: "EIP-4844: BlobHash 1"
code:
PUSH1 "0x01"
BlobHash
STOP
stack:
"0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 0"
code:
PUSH1 "0x00"
BlobHash
STOP
stack:
"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 2"
code:
PUSH1 "0x02"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 32 Bit high"
code:
PUSH4 "0xffffffff"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 64 Bit high"
code:
PUSH8 "0xffffffffffffffff"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 128 Bit high"
code:
PUSH16 "0xffffffffffffffffffffffffffffffff"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 256 Bit high"
code:
PUSH32 "0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun
when not defined(evmc_enabled):
assembler:
title: "EIP-4844: BlobHash 1"
code:
PUSH1 "0x01"
BlobHash
STOP
stack:
"0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 0"
code:
PUSH1 "0x00"
BlobHash
STOP
stack:
"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 2"
code:
PUSH1 "0x02"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 32 Bit high"
code:
PUSH4 "0xffffffff"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 64 Bit high"
code:
PUSH8 "0xffffffffffffffff"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 128 Bit high"
code:
PUSH16 "0xffffffffffffffffffffffffffffffff"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

assembler:
title: "EIP-4844: BlobHash 256 Bit high"
code:
PUSH32 "0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"
BlobHash
STOP
stack:
"0x0000000000000000000000000000000000000000000000000000000000000000"
fork: Cancun

when isMainModule:
opEnvMain()