Skip to content

Commit 82c82a1

Browse files
authored
Merge all bench into gigasim (#4390)
Makes gigasim the single storage benchmark. It already ran the whole `GigaStorageManager` stack end to end; this closes the gaps that kept blocksim (block ledger only), cryptosim (state DB only) and walsim (WAL only) around, then deletes those three and their dashboards. **Workload** - New `TransactionType`: `erc20` (default) or `transfer`. - ERC20: reads token code, the sender's account and both balance slots; writes the sender's account and both slots. The recipient's account is not touched, as on chain. - Transfer: reads and writes both accounts' native balances; no contract code or storage. Always 21,000 gas. - ERC20 balance slots are keyed by token contract address + holder, so a hot token is a hot key range. Each account holds `Erc20InteractionsPerAccount` tokens and sends one of them. - Accounts are read and written through the native balance field (was the code hash as a stand-in). - Blocks can carry more transactions than a ledger block's 2,000 payload entries: `ledgerPayload` packs several per entry, still within the 2 MiB byte budget. **Config changes** - Added: - `TransactionType` (default `erc20`) - `Erc20GasPerTransaction` (50,000) - `MaxTps` (0 = unthrottled), replacing `MaxBlocksPerSecond` - `PprofAddr` (empty = off), `MutexProfileFraction` (0), `BlockProfileRate` (0) - `AccountCacheSizeBytes` (1 GiB), `CodeCacheSizeBytes` (1 GiB), `StorageCacheSizeBytes` (4 GiB) - Removed: - `MaxBlocksPerSecond` (use `MaxTps`) - `LogDir`: logs always go to `DataDir/logs` - Changed defaults: - `TransactionsPerBlock` 2,000 → 10,000 - `BytesPerTransaction` 256 → 200 - `MaxPendingExecutionQueueSize` 100 → 20 - `FlushIntervalBlocks` 10 → 1 - `Erc20ContractSize` 4,096 → 2,048 - `LookbackWindow` 1,000,000 → 100,000 - `CheckpointIntervalSeconds` 60 → 300 - `CheckpointBlockInterval` 0 → 5,000 - Changed meaning: - `Erc20InteractionsPerAccount`: number of tokens each account holds - `HotErc20ContractProbability`: share of holdings (and so of transfers) in the hot token set - `TransactionsPerBlock`: now capped at 1,000,000 instead of 2,000 - Shipped configs: - `standard.json` renamed to `full-node.json`, with `LookbackWindow` 1,000,000 - New `archive-node.json`: `LookbackWindow` -1, keeps all history - `validator.json`: `LookbackWindow` 0 - `debug.json`: `MaxBlocksPerSecond` 10 → `MaxTps` 1,000 - All set `TransactionType` explicitly, and none set `LogDir` **Metrics and dashboard** - New gigasim metrics: `gigasim_gas_used_total`, `gigasim_store_keys_written_total{store}`, and a `type` label on `gigasim_transactions_executed_total`. - Dashboard: gigagas/sec, state keys written/sec per store, TPS by transaction type, per-read latency percentiles, process I/O, a Retention row, and the Pebble rows ported from the cryptosim dashboard. All panels have transparent backgrounds. - Prometheus scrape job `cryptosim` renamed to `gigasim`. **Removed** - `sei-db/bench/blocksim`, `cryptosim` and `walsim`, plus the `blocksim` and `cryptosim` dashboards. Cryptosim's Ubuntu setup script moves to `gigasim/tools/`, and its Prometheus/Grafana and AWS instructions move into the gigasim README. **Risk** - One change outside the benchmark: the storage garbage collector (`sei-db/controller`) now publishes `storage_gc_*` metrics (cut lines, per-store rollback floors, per-store prune duration and errors). Pruning decisions are unchanged, but nodes running the collector will export these metrics too. - Existing gigasim data directories should be rebuilt: account and balance-slot keys changed. - Configs that set `MaxBlocksPerSecond` or `LogDir` now fail to load (unknown fields are rejected). **Validation** - gigasim, controller, common metrics and block store tests pass under `-race`. - Live runs of both transaction types confirmed the gas and keys-written numbers.
1 parent 2362063 commit 82c82a1

93 files changed

Lines changed: 22612 additions & 32161 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.gitignore‎

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,5 @@ contracts/artifacts
6464
integration_test/dapp_tests/artifacts
6565

6666
# DB benchmark data and artifacts
67-
sei-db/bench/cryptosim/data/**
68-
sei-db/bench/cryptosim/bin/
69-
sei-db/bench/cryptosim/logs/
70-
sei-db/bench/blocksim/bin/
7167
sei-db/bench/gigasim/bin/
72-
sei-db/bench/walsim/bin/
7368
sei-db/db_engine/litt/bin/

‎docker/monitornode/config/prometheus.yaml‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,13 @@ global:
33
evaluation_interval: 15s
44

55
scrape_configs:
6-
- job_name: 'cryptosim'
6+
# The gigasim benchmark, at its default MetricsAddr.
7+
- job_name: 'gigasim'
78
static_configs:
89
- targets: ['host.docker.internal:9090']
910
scrape_interval: 5s
1011

11-
# evmonly-loadtest, which defaults to this port rather than the 9090 the sims use. It serves the
12+
# evmonly-loadtest, which defaults to this port rather than the 9090 gigasim uses. It serves the
1213
# storage stack's OTel instruments alongside its own counters, so the phase timers behind a slow
1314
# block arrive on the same scrape.
1415
- job_name: 'evmonly-loadtest'

0 commit comments

Comments
 (0)