mirror of
https://github.com/status-im/eth2.0-specs.git
synced 2025-01-20 15:38:55 +00:00
Whisk: add preset files (#3424)
* Add Whisk preset files * Use N=8 for minimal preset * Update spec_object var location
This commit is contained in:
parent
cc4c810b8f
commit
c90d724392
20
presets/mainnet/whisk.yaml
Normal file
20
presets/mainnet/whisk.yaml
Normal file
@ -0,0 +1,20 @@
|
||||
# Mainnet preset - Whisk
|
||||
|
||||
# Misc
|
||||
# ---------------------------------------------------------------
|
||||
# `uint64(4)`
|
||||
CURDLEPROOFS_N_BLINDERS: 4
|
||||
# `uint64(2**14)`
|
||||
WHISK_CANDIDATE_TRACKERS_COUNT: 16384
|
||||
# `uint64(2**13)` must be < WHISK_CANDIDATE_TRACKERS_COUNT
|
||||
WHISK_PROPOSER_TRACKERS_COUNT: 8192
|
||||
# `Epoch(2**8)`
|
||||
WHISK_EPOCHS_PER_SHUFFLING_PHASE: 256
|
||||
# `uint64(2**7 - CURDLEPROOFS_N_BLINDERS)`
|
||||
WHISK_VALIDATORS_PER_SHUFFLE: 124
|
||||
# `Epoch(2)`
|
||||
WHISK_PROPOSER_SELECTION_GAP: 2
|
||||
# `uint64(2**15)` TODO: will be replaced by a fix format once there's a serialized format
|
||||
WHISK_MAX_SHUFFLE_PROOF_SIZE: 32768
|
||||
# `uint64(2**10)` TODO: will be replaced by a fix format once there's a serialized format
|
||||
WHISK_MAX_OPENING_PROOF_SIZE: 1024
|
20
presets/minimal/whisk.yaml
Normal file
20
presets/minimal/whisk.yaml
Normal file
@ -0,0 +1,20 @@
|
||||
# Minimal preset - Whisk
|
||||
|
||||
# Misc
|
||||
# ---------------------------------------------------------------
|
||||
# [customized]
|
||||
CURDLEPROOFS_N_BLINDERS: 4
|
||||
# [customized]
|
||||
WHISK_CANDIDATE_TRACKERS_COUNT: 32
|
||||
# [customized]
|
||||
WHISK_PROPOSER_TRACKERS_COUNT: 16
|
||||
# [customized]
|
||||
WHISK_EPOCHS_PER_SHUFFLING_PHASE: 4
|
||||
# [customized]
|
||||
WHISK_VALIDATORS_PER_SHUFFLE: 4
|
||||
# [customized]
|
||||
WHISK_PROPOSER_SELECTION_GAP: 1
|
||||
# `uint64(2**15)` TODO: will be replaced by a fix format once there's a serialized format
|
||||
WHISK_MAX_SHUFFLE_PROOF_SIZE: 32768
|
||||
# `uint64(2**10)` TODO: will be replaced by a fix format once there's a serialized format
|
||||
WHISK_MAX_OPENING_PROOF_SIZE: 1024
|
4
setup.py
4
setup.py
@ -793,8 +793,8 @@ from eth2spec.capella import {preset_name} as capella
|
||||
def hardcoded_custom_type_dep_constants(cls, spec_object) -> str:
|
||||
# Necessary for custom types `WhiskShuffleProof` and `WhiskTrackerProof`
|
||||
constants = {
|
||||
'WHISK_MAX_SHUFFLE_PROOF_SIZE': spec_object.constant_vars['WHISK_MAX_SHUFFLE_PROOF_SIZE'].value,
|
||||
'WHISK_MAX_OPENING_PROOF_SIZE': spec_object.constant_vars['WHISK_MAX_OPENING_PROOF_SIZE'].value,
|
||||
'WHISK_MAX_SHUFFLE_PROOF_SIZE': spec_object.preset_vars['WHISK_MAX_SHUFFLE_PROOF_SIZE'].value,
|
||||
'WHISK_MAX_OPENING_PROOF_SIZE': spec_object.preset_vars['WHISK_MAX_OPENING_PROOF_SIZE'].value,
|
||||
}
|
||||
return {**super().hardcoded_custom_type_dep_constants(spec_object), **constants}
|
||||
|
||||
|
@ -10,6 +10,8 @@
|
||||
|
||||
- [Introduction](#introduction)
|
||||
- [Constants](#constants)
|
||||
- [Domain types](#domain-types)
|
||||
- [Preset](#preset)
|
||||
- [Cryptography](#cryptography)
|
||||
- [BLS](#bls)
|
||||
- [Curdleproofs and opening proofs](#curdleproofs-and-opening-proofs)
|
||||
@ -35,15 +37,7 @@ This document details the beacon chain additions and changes of to support the W
|
||||
|
||||
## Constants
|
||||
|
||||
| Name | Value | Description |
|
||||
| ---------------------------------- | -------------------------- | ----------------------------------------------------------- |
|
||||
| `WHISK_CANDIDATE_TRACKERS_COUNT` | `uint64(2**14)` (= 16,384) | number of candidate trackers |
|
||||
| `WHISK_PROPOSER_TRACKERS_COUNT` | `uint64(2**13)` (= 8,192) | number of proposer trackers |
|
||||
| `WHISK_EPOCHS_PER_SHUFFLING_PHASE` | `Epoch(2**8)` (= 256) | epochs per shuffling phase |
|
||||
| `WHISK_VALIDATORS_PER_SHUFFLE` | `uint64(2**7)` (= 128) | number of validators shuffled per shuffle step |
|
||||
| `WHISK_PROPOSER_SELECTION_GAP` | `Epoch(2)` | gap between proposer selection and the block proposal phase |
|
||||
| `WHISK_MAX_SHUFFLE_PROOF_SIZE` | `uint64(2**15)` | max size of a shuffle proof |
|
||||
| `WHISK_MAX_OPENING_PROOF_SIZE` | `uint64(2**10)` | max size of a opening proof |
|
||||
### Domain types
|
||||
|
||||
| Name | Value |
|
||||
| ---------------------------------- | -------------------------- |
|
||||
@ -51,6 +45,19 @@ This document details the beacon chain additions and changes of to support the W
|
||||
| `DOMAIN_WHISK_SHUFFLE` | `DomainType('0x07100000')` |
|
||||
| `DOMAIN_WHISK_PROPOSER_SELECTION` | `DomainType('0x07200000')` |
|
||||
|
||||
## Preset
|
||||
|
||||
| Name | Value | Description |
|
||||
| ---------------------------------- | -------------------------- | ----------------------------------------------------------- |
|
||||
| `CURDLEPROOFS_N_BLINDERS` | `uint64(4)` | number of blinders for curdleproofs |
|
||||
| `WHISK_CANDIDATE_TRACKERS_COUNT` | `uint64(2**14)` (= 16,384) | number of candidate trackers |
|
||||
| `WHISK_PROPOSER_TRACKERS_COUNT` | `uint64(2**13)` (= 8,192) | number of proposer trackers |
|
||||
| `WHISK_EPOCHS_PER_SHUFFLING_PHASE` | `Epoch(2**8)` (= 256) | epochs per shuffling phase |
|
||||
| `WHISK_VALIDATORS_PER_SHUFFLE` | `uint64(2**7 - 4)` (= 124) | number of validators shuffled per shuffle step |
|
||||
| `WHISK_PROPOSER_SELECTION_GAP` | `Epoch(2)` | gap between proposer selection and the block proposal phase |
|
||||
| `WHISK_MAX_SHUFFLE_PROOF_SIZE` | `uint64(2**15)` | max size of a shuffle proof |
|
||||
| `WHISK_MAX_OPENING_PROOF_SIZE` | `uint64(2**10)` | max size of a opening proof |
|
||||
|
||||
## Cryptography
|
||||
|
||||
### BLS
|
||||
|
Loading…
x
Reference in New Issue
Block a user