L1/L2 differences

Goshen is designed to be Ethereum-equivalent in terms of the low-level state storage, EVM bytecode execution, account system, definition of block and transaction structure, and public RPC APIs. In this way, Dapp development process on Goshen and Etheruem remains the same. Still, there are a few minor parameters tuned.

Transaction type

Because Ethereum is backward-compatible, some outdated features can still be used in later versions. For example, early transactions that does not support EIP-155 do not have replay attack protection. Although modern wallets do not construct such transactions, the Ethereum blockchain still can accept and execute them. On Goshen, we removed such support to avoid replay attacks like what Optimism experienced.

Transaction nonce

You can send transactions to Goshen and let the Sequencer publish them to Ethereum in batches, or send transactions from Goshen to Ethereum directly by yourself. The direct sent transactions will be placed in the transaction queue by the smart contract, hence are called "enqueue transactions". The nonce values of enqueue transactions are managed by the smart contract. The value grows every time when a transaction is sent from the starting value of 1<<63. Valid nonce ranges for the two types of transactions are as follows:

Nonce rangeTransaction source

[0,1<<62)

Goshen native transactions

[1<<63,1<<64)

Enqueue transactions on Ethereum

Block header structure

The structure of the block header in Goshen and Ethereum are identical. However, the block header contains fields associated with the PoW consensus, and Goshen does not support PoW like Ethereum does, so these fields are assigned with special meaning as listed in the table.

FieldMeaning in Goshen

coinbase

Fee Collector Address: 0xfee0000000000000000000000000000000000fee

difficulty

difficulty -1 = Total enqueue transactions from genesis block

nonce

MMR size

mixHash

MMR root

Intrinsic gas calculation

On Ethereum, the intrinsic gas already includes the transaction data fee. As mentioned in the Gas fee section, this part of fee is enlarged 100 times as much to cover the cost for publishing transactions on Ethereum.

EVM

Goshen supports the Istanbul hard fork version of EVM, so any Ethereum opcode introduced after this version (e.g. basefee) is not supported.

Last updated