Skip to content

Commit 811ebfe

Browse files
committed
fix rebase issues
1 parent 2334cb7 commit 811ebfe

File tree

4 files changed

+6
-12
lines changed

4 files changed

+6
-12
lines changed

core/state_processor_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -481,7 +481,7 @@ func TestProcessVerkle(t *testing.T) {
481481
txCost1 := params.TxGas
482482
txCost2 := params.TxGas
483483
contractCreationCost := intrinsicContractCreationGas + uint64(2039 /* execution costs */)
484-
codeWithExtCodeCopyGas := intrinsicCodeWithExtCodeCopyGas + uint64(293644 /* execution costs */)
484+
codeWithExtCodeCopyGas := intrinsicCodeWithExtCodeCopyGas + uint64(179444 /* execution costs */)
485485
blockGasUsagesExpected := []uint64{
486486
txCost1*2 + txCost2,
487487
txCost1*2 + txCost2 + contractCreationCost + codeWithExtCodeCopyGas,

core/vm/evm.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -457,16 +457,10 @@ func (evm *EVM) create(caller ContractRef, codeAndHash *codeAndHash, gas uint64,
457457
return nil, common.Address{}, gas, ErrNonceUintOverflow
458458
}
459459
evm.StateDB.SetNonce(caller.Address(), nonce+1)
460-
<<<<<<< HEAD
461460

462461
// We add this to the access list _before_ taking a snapshot. Even if the
463462
// creation fails, the access-list change should not be rolled back.
464-
if evm.chainRules.IsBerlin {
465-
=======
466-
// We add this to the access list _before_ taking a snapshot. Even if the creation fails,
467-
// the access-list change should not be rolled back
468463
if evm.chainRules.IsEIP2929 {
469-
>>>>>>> fc62f50eb (cmd, core, params, trie: Add verkle access witness)
470464
evm.StateDB.AddAddressToAccessList(address)
471465
}
472466
// Ensure there's no existing contract already at the designated address.

eth/state_accessor.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ func (eth *Ethereum) stateAtTransaction(ctx context.Context, block *types.Block,
237237
if beaconRoot := block.BeaconRoot(); beaconRoot != nil {
238238
context := core.NewEVMBlockContext(block.Header(), eth.blockchain, nil)
239239
vmenv := vm.NewEVM(context, vm.TxContext{}, statedb, eth.blockchain.Config(), vm.Config{})
240-
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb)
240+
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb, block.Number(), block.Time())
241241
}
242242
if txIndex == 0 && len(block.Transactions()) == 0 {
243243
return nil, vm.BlockContext{}, statedb, release, nil

eth/tracers/api.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ func (api *API) traceChain(start, end *types.Block, config *TraceConfig, closed
381381
if beaconRoot := next.BeaconRoot(); beaconRoot != nil {
382382
context := core.NewEVMBlockContext(next.Header(), api.chainContext(ctx), nil)
383383
vmenv := vm.NewEVM(context, vm.TxContext{}, statedb, api.backend.ChainConfig(), vm.Config{})
384-
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb)
384+
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb, vmenv.Context.BlockNumber, vmenv.Context.Time)
385385
}
386386
// Clean out any pending release functions of trace state. Note this
387387
// step must be done after constructing tracing state, because the
@@ -533,7 +533,7 @@ func (api *API) IntermediateRoots(ctx context.Context, hash common.Hash, config
533533
)
534534
if beaconRoot := block.BeaconRoot(); beaconRoot != nil {
535535
vmenv := vm.NewEVM(vmctx, vm.TxContext{}, statedb, chainConfig, vm.Config{})
536-
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb)
536+
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb, vmenv.Context.BlockNumber, vmenv.Context.Time)
537537
}
538538
for i, tx := range block.Transactions() {
539539
if err := ctx.Err(); err != nil {
@@ -612,7 +612,7 @@ func (api *API) traceBlock(ctx context.Context, block *types.Block, config *Trac
612612
)
613613
if beaconRoot := block.BeaconRoot(); beaconRoot != nil {
614614
vmenv := vm.NewEVM(blockCtx, vm.TxContext{}, statedb, api.backend.ChainConfig(), vm.Config{})
615-
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb)
615+
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb, vmenv.Context.BlockNumber, vmenv.Context.Time)
616616
}
617617
for i, tx := range txs {
618618
// Generate the next state snapshot fast without tracing
@@ -770,7 +770,7 @@ func (api *API) standardTraceBlockToFile(ctx context.Context, block *types.Block
770770
}
771771
if beaconRoot := block.BeaconRoot(); beaconRoot != nil {
772772
vmenv := vm.NewEVM(vmctx, vm.TxContext{}, statedb, chainConfig, vm.Config{})
773-
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb)
773+
core.ProcessBeaconBlockRoot(*beaconRoot, vmenv, statedb, vmenv.Context.BlockNumber, vmenv.Context.Time)
774774
}
775775
for i, tx := range block.Transactions() {
776776
// Prepare the transaction for un-traced execution

0 commit comments

Comments
 (0)