Commit graph

2090 commits

Author SHA1 Message Date
HAOYUatHZ
8f8ef30931
feat(txpool): add more logs to runReorg (#1019)
* feat(txpool): add more logs to `runReorg`

* chore: auto version bump [bot]

* improve

* chore: auto version bump [bot]

---------

Co-authored-by: HAOYUatHZ <HAOYUatHZ@users.noreply.github.com>
2024-09-05 09:31:49 +10:00
Ömer Faruk Irmak
e9259b783f
feat: implement and integrate counter-based CCC (#982)
Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
Co-authored-by: Zhang Zhuo <mycinbrin@gmail.com>
Co-authored-by: Xi Lin <zimpha@gmail.com>
2024-09-04 13:33:51 +03:00
colin
c252ee1ee0
feat(tx-pool): fast reject known skipped txs (#1004)
* feat(tx-pool): fast reject known skipped txs (#1001)

* feat(tx-pool): fast reject known skipped txs

* fix make lint

* add miner flag to tx pool

* bump version
2024-08-26 22:48:44 +08:00
Péter Garamvölgyi
ff23c5272a
feat: schedule DarwinV2 (#1002)
* refactor: add darwinV2 to tests, improve log format

* feat: schedule DarwinV2
2024-08-26 16:15:56 +02:00
colin
03f3b2b60d
fix(rollup-verifier): delete committed batch meta when reverting a batch (#1000)
* fix(rollup-verifier): delete committed batch metadata when reverting a batch

* chore: auto version bump [bot]

* remove a comment

---------

Co-authored-by: colinlyguo <colinlyguo@users.noreply.github.com>
2024-08-26 11:15:29 +02:00
Ömer Faruk Irmak
233a6adc15
feat: async ccc checker (#996) 2024-08-23 11:04:12 +03:00
colin
9de4980851
feat(rollup-verifier): codecv4 (#991)
* feat(rollup-verifier): codecv4

* fix golint

* enhancements

* rename

* rename

* feat: add darwinv2 in genesis config

* bump version

* fix typo

* Update params/config.go

Co-authored-by: georgehao <haohongfan@gmail.com>

* add DarwinV2

* address comments

* move a comment to other places

* small refactors

* chore: auto version bump [bot]

* update da-codec commit

* fix a bug

---------

Co-authored-by: georgehao <haohongfan@gmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
Co-authored-by: colinlyguo <colinlyguo@users.noreply.github.com>
2024-08-23 14:50:08 +08:00
georgehao
2ccacff1bf
feat(metrics): calculate the real pending tx (#983)
* calculate the real pending tx

* update

* move realPendingTx to miner

* update

* calculate the real pending tx by statsWithMinBaseFee

* update

* fix lint

* address comments

* add metrics to StatsWithMinBaseFee

* change read_lock to write_lock
2024-08-20 15:39:28 +08:00
georgehao
4b85bbcbd8
calculate tx the lifecycle duration (#839)
* feat: add transactions len metrics of block processer

* calculate tx lifecycle median duration

* chore: auto version bump [bot]

* fix

* fix

* fix

* chore: auto version bump [bot]

* address comments

* remove error code

* address comment

* update

* Update core/tx_pool.go

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>

* Update core/types/transaction.go

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>

* Update core/tx_pool.go

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>

* Update core/tx_pool.go

---------

Co-authored-by: georgehao <georgehao@users.noreply.github.com>
Co-authored-by: Ömer Faruk Irmak <omerfirmak@gmail.com>
Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
2024-08-13 16:45:01 +08:00
Ömer Faruk Irmak
096b98a85c
feat: allow calculating diffs between two row consumptions (#980) 2024-08-12 22:22:38 +03:00
Ömer Faruk Irmak
2411ae063e
refactor: rename CCC package for less repetition (#967) 2024-08-09 08:21:14 +03:00
Zhang Zhuo
3f5fb275ef
fix: enable correct string encoding of new opcodes (#815) 2024-08-08 13:11:26 +03:00
Ömer Faruk Irmak
2ba5ea3058
Revert "refactor: reduce number of heap allocations in tracing (#952)" (#959)
This reverts commit b84f4ed6f8.
2024-08-02 21:59:50 +08:00
HAOYUatHZ
ee0410ec10
feat: update L2 base fee formula (#951)
* update `CalcBaseFee`

* update `TestCalcBaseFee`

* update `TestStateProcessorErrors`

* bump version

* update threshold
2024-08-02 10:09:33 +08:00
Ömer Faruk Irmak
b84f4ed6f8
refactor: reduce number of heap allocations in tracing (#952) 2024-08-01 14:52:43 +03:00
Ömer Faruk Irmak
9abdd5b9aa
feat: defer txpool reorg until worker fetches txns for the next block (#905) 2024-07-26 10:25:58 +03:00
Zhang Zhuo
0cecc1986e
refactor(trace): clean outdated fields (#842)
* clean trace: remove ExtraData, disable prestateTracer, collect bytecodes in top level

* fix

* fix

* fix

* fix

* fix

* more cleanup

* more cleanup

* refactor(trace): clean outdated fields

* fix bytecodes in trace

* chore: auto version bump [bot]

* chore: auto version bump [bot]

* use hexutil.Bytes

---------

Co-authored-by: Ömer Faruk Irmak <omerfirmak@gmail.com>
Co-authored-by: omerfirmak <omerfirmak@users.noreply.github.com>
Co-authored-by: lispc <lispc@users.noreply.github.com>
2024-07-15 20:36:00 +08:00
Péter Garamvölgyi
0b5146bdef
feat(txpool): use GasFeeCapIntCmp to check min fee (#901)
* feat(txpool): use GasFeeCapIntCmp to check min fee

* fix test
2024-07-12 11:56:35 +02:00
Jonas Theis
8c7a3aed74
feat(txpool): StatsWithMinBaseFee (#884)
* feat(txpool): implement StatsWithMinBaseFee

* feat(gpo): use StatsWithMinBaseFee to filter out tx below the current blocks base fee

* feat(les/txpool): implement StatsWithMinBaseFee

* use flatten() (lowercase) to avoid copying of tx list

* chore: auto version bump [bot]

---------

Co-authored-by: jonastheis <jonastheis@users.noreply.github.com>
2024-07-10 11:10:58 +02:00
Péter Garamvölgyi
f56dbb7c43
feat: update L2 base fee formula (#891)
* feat: update L2 base fee formula

* update test tx hashes
2024-07-09 12:54:00 +02:00
HAOYUatHZ
a40ef3f6e0
fix(signer): update LatestSigner logic (#880) 2024-07-05 18:38:21 +08:00
Mengran Lan
ef980a2059
feat(rollup_sync_service): handle multiple batches in FinalizeBatch event (#865)
* feat: now FinalizeBatch event will influence one or more batches

* fix bug && add unit test

* fix typo

* Update core/rawdb/accessors_rollup_event_test.go

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>

* trivial fix

* chore: auto version bump [bot]

* trivial change: move write finalized things logic out of loop

* utilize code && comment

* remove redundant check

* two log level changing case

---------

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
Co-authored-by: Thegaram <Thegaram@users.noreply.github.com>
2024-07-01 22:24:32 +08:00
Péter Garamvölgyi
418bc6f728
feat: rename next upgrade to Darwin (#863) 2024-06-26 14:54:36 +02:00
Ömer Faruk Irmak
50a6bc6f42
feat: make descartes a timestamp based fork (#852)
* feat: make descartes a timestamp based fork

* chore: auto version bump [bot]

---------

Co-authored-by: omerfirmak <omerfirmak@users.noreply.github.com>
2024-06-26 12:35:04 +08:00
Ömer Faruk Irmak
316138099f
refactor: remove unused storage traces (#819) 2024-06-14 15:02:00 +03:00
Péter Garamvölgyi
fc9db9f65f
fix(txpool): compare gas tip cap instead of effective gas tip cap (#825)
fix: compare gas tip cap instead of effective gas tip cap
2024-06-13 15:21:34 +02:00
Jonas Theis
c2d7bd8935
feat: implement RIP-7212/EIP-7212 (#798)
Implement RIP-7212/EIP-7212 according to reference implementation at https://github.com/ulerdogan/go-ethereum/pull/1

Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
2024-06-06 13:40:37 +02:00
Péter Garamvölgyi
9ec83a509a
fix: use correct encoding for L1 data fee of EIP2718 transactions (#793)
* fix: use correct encoding for L1 data fee of EIP2718 transactions

* add tests

* lint

* Update rollup/fees/rollup_fee.go

Co-authored-by: Ömer Faruk Irmak <omerfirmak@gmail.com>

---------

Co-authored-by: Ömer Faruk Irmak <omerfirmak@gmail.com>
2024-06-03 16:24:03 +02:00
Péter Garamvölgyi
bfe803001b
feat: update L1 data fee in Curie hard fork (#755)
* update fee calculation

* add missing GPO slots to trace

* add placeholder for contract update logic

* nit

* update fee calculation

* update formula

* update GPO slots

* update L1GPO bytecode

* apply Curie in new worker

* move bytecode to config

* create an empty block for curie hard fork

* initialize L1GasPriceOracle storage slots

* add comments

* add test

* add IsCurie to traces and tests

* group GPO storage slots into a struct

* update unit test

* chore: auto version bump [bot]

* trigger ci

* update bytecode

* remove leading 0x

* update comments

* include rollup fee tests in CI

---------

Co-authored-by: Ömer Faruk Irmak <omerfirmak@gmail.com>
Co-authored-by: Thegaram <Thegaram@users.noreply.github.com>
2024-05-28 14:12:39 +02:00
Ömer Faruk Irmak
c7990a3eb1
feat(worker): pipeline block building (#735) 2024-05-21 16:11:06 +03:00
Ömer Faruk Irmak
12871c7745
feat(worker): try to limit the number of txns miner has to deal with (#745)
to reduce the effect of having a huge backlog on performance
2024-05-13 09:20:55 +03:00
Péter Garamvölgyi
c3b7678ccc
fix: temporarily disable string encoding for new opcodes (#737)
feat: temporarily disable string encoding for new opcodes
2024-05-02 17:46:11 +08:00
Nazarii Denha
3592139384
(feat)all: add EIP-1153 - transient storage (#721)
* all: implement EIP-1153 transient storage (#26003)

Implements TSTORE and TLOAD as specified by the following EIP:

https://eips.ethereum.org/EIPS/eip-1153
https://ethereum-magicians.org/t/eip-1153-transient-storage-opcodes/553

Co-authored-by: Sara Reynolds <snreynolds2506@gmail.com>
Co-authored-by: Martin Holst Swende <martin@swende.se>
Co-authored-by: Gary Rong <garyrong0905@gmail.com>

* core/vm: move TSTORE,TLOAD to correct opcode nums (#27613)

* core/vm: move TSTORE,TLOAD to correct opcode nums

* core/vm: cleanup

* fix tests, rename

* goimports

* enable 1153 at Curie

* bump version

* comment fix

* improve test

* version

* testchainconfig

* fix another test that affects newly added

* fix previous test to clenaup after

---------

Co-authored-by: Mark Tyneway <mark.tyneway@gmail.com>
Co-authored-by: Sara Reynolds <snreynolds2506@gmail.com>
Co-authored-by: Martin Holst Swende <martin@swende.se>
Co-authored-by: Gary Rong <garyrong0905@gmail.com>
Co-authored-by: Marius van der Wijden <m.vanderwijden@live.de>
2024-04-28 15:59:26 +08:00
Nazarii Denha
005db0370e
(feat)core/vm: Add Upgrade #4 fork configuration (#698)
* Add Upgrade #4 fork configuration

* bump version

* chore: auto version bump [bot]

* trigger ci

---------

Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
Co-authored-by: Thegaram <Thegaram@users.noreply.github.com>
2024-04-24 18:01:47 +08:00
Nazarii Denha
ecca1069d3
(feat) core/vm: implement EIP-5656, mcopy opcode (#697)
* core/vm: implement EIP-5656, mcopy instruction (#26181)

Implements [EIP 5656](https://eips.ethereum.org/EIPS/eip-5656), MCOPY instruction, and enables it for Cancun.

---------

Co-authored-by: Martin Holst Swende <martin@swende.se>

* update version

* goimports

---------

Co-authored-by: Charles Cooper <cooper.charles.m@gmail.com>
Co-authored-by: Martin Holst Swende <martin@swende.se>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
Co-authored-by: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com>
2024-04-24 17:41:50 +08:00
Péter Garamvölgyi
0252f85816
feat: add block time metric (#707)
* feat: add block time metric

* chore: auto version bump [bot]

* trigger ci

---------

Co-authored-by: Thegaram <Thegaram@users.noreply.github.com>
2024-04-18 11:25:03 +08:00
georgehao
678a9fcb69
feat: add more state_transition, worker, and tracing metrics (#700)
* feat: add transactions len metrics of block processer

* feat: (worker): add metrics

* feat: add commitTransaction loops

* feat: add metrics to rollup tracing

* feat: add metrics to getTxResult

* feat: bump version

* add state revert metric timer

* feat: add commitNewWrok metrics

* feat: fix comments

* feat: remove the consume part metrics

* feat: update

* Apply suggestions from code review

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>

* feat: update

* feat: address comments

* chore: auto version bump [bot]

* feat: bump version

* add tests

* Revert "add tests"

This reverts commit 175d544a68fc964dcc062b46c1a010ed821a0996.

---------

Co-authored-by: Ömer Faruk Irmak <omerfirmak@gmail.com>
Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
Co-authored-by: georgehao <georgehao@users.noreply.github.com>
Co-authored-by: colinlyguo <colinlyguo@scroll.io>
2024-04-16 16:05:21 +08:00
georgehao
4c2b567116
fix(txpool): rollback false optimization (#694)
* feat: add transactions len metrics of block processer

* feat: rollback false optimize

* feat: update

* feat: bump version
2024-04-08 10:13:43 +08:00
HAOYUatHZ
0bccb7bc50
fix(state): fix iterativeDump.OnAccount (#649)
* fix `iterativeDump.OnAccount`

* chore: auto version bump [bot]

* chore: auto version bump [bot]

---------

Co-authored-by: HAOYUatHZ <HAOYUatHZ@users.noreply.github.com>
2024-04-05 11:48:09 +08:00
Péter Garamvölgyi
5faeeaaf62
feat: add metrics to block validation (#677)
* feat: add metrics to block validation

* more metrics

* bump version
2024-03-27 16:36:08 +00:00
vyzo
d1e4b59eec
fix: Check L1DataFee in txpool promoteExecutables and demoteUnexecutables (#627)
* Check L1DataFee in txpool promoteExecutables

* bump version

* implement L1 data fee in demoteUnexecutables as well

* Update core/tx_list.go

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>

* Update core/tx_pool.go

Co-authored-by: Péter Garamvölgyi <peter@scroll.io>

* feat: consider l1 data fee in txpool costcap (#681)

* feat(txpool): consider l1 data fee in costcap

* fix CI

* simplify logic

* remove one db read op

* bump version

---------

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
Co-authored-by: georgehao <haohongfan@gmail.com>
2024-03-27 15:31:51 +00:00
Péter Garamvölgyi
0f0cd99f7a
feat: update upcoming fork names (#680)
* feat: update upcoming fork names

* bump version

* Apply suggestions from code review

Co-authored-by: Nazarii Denha <dengaaa2002@gmail.com>

* bump version

---------

Co-authored-by: Nazarii Denha <dengaaa2002@gmail.com>
2024-03-26 14:41:32 +00:00
Péter Garamvölgyi
411889ef92
fix: ensure L1 messages are stored in db consistently (#679)
* fix: ensure L1 messages are stored in db consistently

* check db iterator errors
2024-03-26 14:02:03 +00:00
colin
4553f5f269
feat(ethclient & gethclient): support blob transaction (#661)
* feat: support blob transaction

* sync tx encoding/decoding

* more fixes

* add uint236 support in rlp encoding decoding

* revert a format change

* trigger ci
2024-03-14 17:51:30 +08:00
Péter Garamvölgyi
ccec84ce63
feat: re-enable EIP-1559 in Banach hard fork (#634)
* feat: re-enable EIP-1559 in Banach hard fork

* enable BASEFEE opcode

* do not double gas limit on Banach fork block

* do not burn base fee

* update base fee calculation logic

* fix gas price oracle

* fix ethapi backend

* typo

* reorder worker code

* update genesis base fee

* add MaximumL2BaseFee

* add base fee metrics

* handle nil base fee

* revert state-transition change

* bump version

* remove TODO

* update test

* fix typo

* fix typo

* update traces

* fix test

* update london to banach

* handle error

* bump version

* bump version
2024-03-11 13:57:52 +00:00
colin
a807a41fd1
fix(txJSON): L1 message type MarshalJSON (#630)
* fix(txJSON): L1 message type MarshalJSON

* address comments

* bump version

* trigger ci

* bump version

* bump version
2024-03-05 20:12:10 +08:00
georgehao
06a21f327d
feat: add transactions len metrics of block processer (#650)
* feat: add transactions len metrics of block processer

* feat: bump version
2024-03-04 10:21:05 +08:00
georgehao
bfa7abcc50
feat: add metric to evm call (#646)
* feat: add metric to evm

* feat: bump version
2024-02-28 09:45:38 +08:00
Nazarii Denha
ee381b2451
feat: setup configuration for upcoming hard fork and re-enable sha256 precompile (#562)
* setup configuration for upcoming hard fork

* bump version

* bump version

* enable sha256

* rename to kepler

* update

* update lint

* rename Kepler to Banach

* goimports

* reorder precompile forks

* typo

---------

Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
2024-02-09 13:46:33 +01:00
Péter Garamvölgyi
7e3a7ae744
ci: fix goimports lint in CI (#628)
* ci: fix goimports lint in CI

* use different go versions for goimports and go mod tidy

* goimports
2024-02-09 13:25:59 +01:00