EIP-3860

공식 웹사이트:
소셜 프로필:
블록체인:

IQ AI를 발표했습니다.

확인해보세요

EIP-3860

EIP-3860 proposes changes to the maximum size limit of initcode in , as well as the introduction of a gas charge for every 32-byte chunk of initcode, as part of the Shanghai  of the Shapella Upgrade. This proposal was made to ensure that the initcode is fairly charged, with costs being proportional to the length of the initcode.

Overview

On July 16th, 2021, -3860 was created to update the initcode in order to minimize risk. The lack of a limit on the size of initcode has caused lengthy discussions for some EVM proposals, influencing the design, or even causing a delay or cancellation of a feature. By introducing a limit, the proposal aims to simplify EVM engines by setting explicit limits, such as code size, code offsets, and jump offsets, to fit 16 bits. [1][3]

Initcode is the code that is executed during the creation of a new contract, and the current maximum value for initcode was set to 24576 bytes in EIP-170. However, EIP-3860 proposes that the new maximum value of initcode should be increased to 49152 bytes, which is twice the current maximum size. This change would double the maximum contract size and enable contracts to have more sophisticated functionality. [1]

Details

The gas cost per byte of initcode will add 0.0625 gas, and the cost of deploying gas to the contract will also increase slightly. Additionally, there is an extra gas cost of 2 for every 32-byte chunk of initcode, which is meant to represent the cost of jumpdest-analysis during contract creation. [2]

The EIP-3860 proposal sets rules for creating new programs on the Ethereum blockchain. Two important rules are INITCODE_WORD_COST, which is a cost of 2, and MAX_INITCODE_SIZE, which is twice the size of the maximum code size allowed. If a transaction's program code is larger than MAX_INITCODE_SIZE, the transaction is invalid. Also, the cost of the program code is included in the total cost of the transaction, and if the transaction doesn't have enough gas to cover the cost, it's invalid. For the CREATE and CREATE2 instructions, there's an extra gas cost that's deducted before the program code is executed. The cost constant for INITCODE_WORD_COST is determined by performance benchmarks, with a baseline of KECCAK256 hashing in geth 1.10.9. [2]

Authors

  • Martin Holst Swende
  • Paweł Bylica
  • Alex Beregszaszi
  • Andrei Maiboroda

[2]

See something wrong?

가격

$3,338.91

5.44%

시가 총액

$402,282,500,849.00

5.34%

희석된 시가 총액

$402,003,716,568.62

5.34%

거래량

$30,063,590,732.46

3.57%

Ethereum

ETH

USD

USD

평균 평점

아직 평가가 없습니다

경험은 어땠나요?

빠른 평가를 해서 우리에게 알려주세요!

편집자

Profile picture of Anonymous uservzbrv

편집 날짜

March 31, 2023

참고 문헌.

[1]

Medium post on EIP-3860

Mar 14, 2023

[2]

EIPS EIP-3860

Mar 14, 2023

[3]

Ethereum Cat Herders' video on EIP-3860

Mar 14, 2023