polkadot icon indicating copy to clipboard operation
polkadot copied to clipboard

Add nomination pools to Polkadot runtime

Open kianenigma opened this issue 2 years ago • 21 comments

  • targeting release 0.9.23

  • Also sets the initial configs of the pools:

  • 5 DOT to join a pool.

  • 100 DOT to create a pool.

  • 64 initial pools: only for initial safety: can be set to infinity when needed.

  • 4096 members per pool: only for initial safety: can be set to infinity when needed.

  • 128k total pool members: only for initial safety: can be set to infinity when needed.

Should only be merged once the following is merged on substrate:

  • [x] https://github.com/paritytech/substrate/pull/11426
  • [x] https://github.com/paritytech/substrate/pull/11669

UPDATE:

The above numbers are still my suggestion, but I this PR as it is has all the max counters set to 0, meaning that we can deploy this but no pool can be created. This will be helpful in making the process of enabling pools independent of a runtime upgrade.

kianenigma avatar May 22 '22 13:05 kianenigma

/bench runtime polkadot pallet_nomination_pools

kianenigma avatar May 22 '22 13:05 kianenigma

Benchmark Runtime Polkadot Pallet for branch "kiz-pools-polkadot" with command cargo run --quiet --profile=production --features=runtime-benchmarks -- benchmark pallet --chain=polkadot-dev --steps=50 --repeat=20 --pallet=pallet_nomination_pools --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/polkadot/src/weights/

Toolchain: stable-x86_64-unknown-linux-gnu (default) rustc 1.60.0 (7737e0b5c 2022-04-04)

Results
Wrote dot graph to /home/benchbot/bench-bot/git/polkadot/target/production/build/orchestra-proc-macro-65cc68db4b7d857b/out/overseer-subsystem-messaging.dot

ERROR: Unable to commit file ./runtime/polkadot/src/weights/

parity-benchapp[bot] avatar May 22 '22 13:05 parity-benchapp[bot]

/bench runtime polkadot pallet_nomination_pools

kianenigma avatar May 23 '22 07:05 kianenigma

Benchmark Runtime Polkadot Pallet for branch "kiz-pools-polkadot" with command cargo run --quiet --profile=production --features=runtime-benchmarks -- benchmark pallet --chain=polkadot-dev --steps=50 --repeat=20 --pallet=pallet_nomination_pools --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/polkadot/src/weights/

Toolchain: stable-x86_64-unknown-linux-gnu (default) rustc 1.60.0 (7737e0b5c 2022-04-04)

Results
2022-05-23 07:28:36 [0] 💸 generated 1 npos voters, 1 from validators and 0 nominators    
2022-05-23 07:28:36 Took active validators from set with wrong size    
2022-05-23 07:28:36 Took active validators from set with wrong size    
2022-05-23 07:28:36 Took active validators from set with wrong size.    
2022-05-23 07:28:36 Took active validators from set with wrong size    
Error: 
   0: [91mInvalid input: Did not find the benchmarking metadata. This could mean that you either did not build the node correctly with the `--features runtime-benchmarks` flag, or the chain spec that you are using was not created by a node that was compiled with the flag: cannot create module: memory index 0 has a minimum page size of 4119 which exceeds the limit of 4096[0m

Backtrace omitted. Run with RUST_BACKTRACE=1 environment variable to display it.
Run with RUST_BACKTRACE=full to include source snippets.
2022-05-23 07:28:37 Cannot create a runtime error=Other("cannot create module: memory index 0 has a minimum page size of 4119 which exceeds the limit of 4096")

ERROR: Unable to commit file ./runtime/polkadot/src/weights/

parity-benchapp[bot] avatar May 23 '22 07:05 parity-benchapp[bot]

I think you currently have to copy&paste the benchmark command without the --heap-pages flag to make it work like here: https://github.com/paritytech/substrate/pull/11431#issuecomment-1133018018. Should be fixed after: https://github.com/paritytech/substrate/pull/11482

ggwpez avatar May 23 '22 10:05 ggwpez

/benchmark runtime custom pallet --chain=polkadot-dev --steps=50 --repeat=20 --pallet=pallet_nomination_pools --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/polkadot/src/weights/

kianenigma avatar May 24 '22 08:05 kianenigma

Benchmark Runtime Custom for branch "kiz-pools-polkadot" with command cargo run --quiet --profile=production --features runtime-benchmarks -- benchmark pallet --chain=polkadot-dev --steps=50 --repeat=20 --pallet=pallet_nomination_pools --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/polkadot/src/weights/

Toolchain: stable-x86_64-unknown-linux-gnu (default) rustc 1.60.0 (7737e0b5c 2022-04-04)

Results
2022-05-24 09:30:03 [0] 💸 generated 1 npos voters, 1 from validators and 0 nominators    
2022-05-24 09:30:03 Took active validators from set with wrong size    
2022-05-24 09:30:03 Took active validators from set with wrong size    
2022-05-24 09:30:03 Took active validators from set with wrong size.    
2022-05-24 09:30:03 Took active validators from set with wrong size    
Error: 
   0: [91mInvalid input: Did not find the benchmarking metadata. This could mean that you either did not build the node correctly with the `--features runtime-benchmarks` flag, or the chain spec that you are using was not created by a node that was compiled with the flag: cannot create module: memory index 0 has a minimum page size of 4119 which exceeds the limit of 4096[0m

Backtrace omitted. Run with RUST_BACKTRACE=1 environment variable to display it.
Run with RUST_BACKTRACE=full to include source snippets.
2022-05-24 09:30:05 Cannot create a runtime error=Other("cannot create module: memory index 0 has a minimum page size of 4119 which exceeds the limit of 4096")

ERROR: Unable to commit file ./runtime/polkadot/src/weights/

parity-benchapp[bot] avatar May 24 '22 08:05 parity-benchapp[bot]

/benchmark runtime custom pallet --chain=polkadot-dev --steps=50 --repeat=20 --pallet=pallet_nomination_pools --extrinsic="*" --execution=wasm --wasm-execution=compiled --header=./file_header.txt --output=./runtime/polkadot/src/weights/

ggwpez avatar May 24 '22 11:05 ggwpez

Benchmark Runtime Custom for branch "kiz-pools-polkadot" with command cargo run --quiet --profile=production --features runtime-benchmarks -- benchmark pallet --chain=polkadot-dev --steps=50 --repeat=20 --pallet=pallet_nomination_pools --extrinsic="*" --execution=wasm --wasm-execution=compiled --header=./file_header.txt --output=./runtime/polkadot/src/weights/

Toolchain: stable-x86_64-unknown-linux-gnu (default) rustc 1.60.0 (7737e0b5c 2022-04-04)

Results
Wrote dot graph to /home/benchbot/bench-bot/git/polkadot/target/production/build/orchestra-proc-macro-dc1fc454fe539c9d/out/overseer-subsystem-messaging.dot
Pallet: "pallet_nomination_pools", Extrinsic: "join", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools MinJoinBond (r:1 w:0)
Storage: NominationPools PoolMembers (r:1 w:1)
Storage: NominationPools BondedPools (r:1 w:1)
Storage: Staking Ledger (r:1 w:1)
Storage: NominationPools RewardPools (r:1 w:0)
Storage: System Account (r:2 w:1)
Storage: NominationPools MaxPoolMembersPerPool (r:1 w:0)
Storage: NominationPools MaxPoolMembers (r:1 w:0)
Storage: NominationPools CounterForPoolMembers (r:1 w:1)
Storage: Staking Bonded (r:1 w:0)
Storage: Balances Locks (r:1 w:1)
Storage: VoterList ListNodes (r:3 w:3)
Storage: VoterList ListBags (r:2 w:2)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    113.1
              µs

Reads = 17
Writes = 11

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=    113.1
              µs

Reads = 17
Writes = 11

Pallet: "pallet_nomination_pools", Extrinsic: "bond_extra_transfer", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools PoolMembers (r:1 w:1)
Storage: NominationPools BondedPools (r:1 w:1)
Storage: NominationPools RewardPools (r:1 w:1)
Storage: System Account (r:2 w:2)
Storage: Staking Ledger (r:1 w:1)
Storage: Staking Bonded (r:1 w:0)
Storage: Balances Locks (r:1 w:1)
Storage: VoterList ListNodes (r:3 w:3)
Storage: VoterList ListBags (r:2 w:2)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    105.8
              µs

Reads = 13
Writes = 12

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=    105.8
              µs

Reads = 13
Writes = 12

Pallet: "pallet_nomination_pools", Extrinsic: "bond_extra_reward", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools PoolMembers (r:1 w:1)
Storage: NominationPools BondedPools (r:1 w:1)
Storage: NominationPools RewardPools (r:1 w:1)
Storage: System Account (r:3 w:3)
Storage: Staking Ledger (r:1 w:1)
Storage: Staking Bonded (r:1 w:0)
Storage: Balances Locks (r:1 w:1)
Storage: VoterList ListNodes (r:2 w:2)
Storage: VoterList ListBags (r:2 w:2)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=      116
              µs

Reads = 13
Writes = 12

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=      116
              µs

Reads = 13
Writes = 12

Pallet: "pallet_nomination_pools", Extrinsic: "claim_payout", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools PoolMembers (r:1 w:1)
Storage: NominationPools BondedPools (r:1 w:1)
Storage: NominationPools RewardPools (r:1 w:1)
Storage: System Account (r:1 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    45.35
              µs

Reads = 4
Writes = 4

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=    45.35
              µs

Reads = 4
Writes = 4

Pallet: "pallet_nomination_pools", Extrinsic: "unbond", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools PoolMembers (r:1 w:1)
Storage: NominationPools BondedPools (r:1 w:1)
Storage: NominationPools RewardPools (r:1 w:1)
Storage: System Account (r:2 w:1)
Storage: Staking CurrentEra (r:1 w:0)
Storage: Staking Ledger (r:1 w:1)
Storage: Staking Nominators (r:1 w:0)
Storage: Staking MinNominatorBond (r:1 w:0)
Storage: Balances Locks (r:1 w:1)
Storage: VoterList ListNodes (r:3 w:3)
Storage: Staking Bonded (r:1 w:0)
Storage: VoterList ListBags (r:2 w:2)
Storage: NominationPools SubPoolsStorage (r:1 w:1)
Storage: NominationPools CounterForSubPoolsStorage (r:1 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    110.9
              µs

Reads = 18
Writes = 13

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=    110.9
              µs

Reads = 18
Writes = 13

Pallet: "pallet_nomination_pools", Extrinsic: "pool_withdraw_unbonded", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools BondedPools (r:1 w:0)
Storage: Staking Ledger (r:1 w:1)
Storage: Staking CurrentEra (r:1 w:0)
Storage: Balances Locks (r:1 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    35.85
    + s    0.028
              µs

Reads = 4 + (0 * s)
Writes = 2 + (0 * s)

Min Squares Analysis
========
-- Extrinsic Time --

Data points distribution:
    s   mean µs  sigma µs       %
    0     35.77     0.234    0.6%
    2      34.9     0.147    0.4%
    4     35.22     0.118    0.3%
    6      35.4     0.157    0.4%
    8     36.52     0.202    0.5%
   10      35.2     0.152    0.4%
   12     36.28     0.233    0.6%
   14     35.82      0.31    0.8%
   16     36.83     0.266    0.7%
   18     36.74     0.165    0.4%
   20     36.07     0.173    0.4%
   22     36.32     0.154    0.4%
   24     37.87     0.102    0.2%
   26     36.49     0.182    0.4%
   28     37.04     0.172    0.4%
   30      36.7     0.219    0.5%
   32     37.68     0.172    0.4%
   34     37.45     0.125    0.3%
   36      36.8     0.135    0.3%
   38     37.04     0.138    0.3%
   40      37.2     0.187    0.5%
   42     37.25     0.155    0.4%
   44     36.97     0.108    0.2%
   46     37.07     0.217    0.5%
   48     37.55     0.173    0.4%
   50     37.23     0.206    0.5%
   52     37.09      0.14    0.3%
   54     38.72     0.143    0.3%
   56      37.4     0.198    0.5%
   58     37.43     0.136    0.3%
   60     37.63     0.156    0.4%
   62     37.59     0.061    0.1%
   64     38.13      0.31    0.8%
   66     38.16     0.242    0.6%
   68     38.47     0.098    0.2%
   70     38.13     0.238    0.6%
   72      37.8       0.1    0.2%
   74     38.32     0.202    0.5%
   76     37.58      0.09    0.2%
   78     37.36     0.185    0.4%
   80     38.05     0.106    0.2%
   82     37.87     0.128    0.3%
   84     37.95     0.208    0.5%
   86     38.81     0.178    0.4%
   88     37.97     0.177    0.4%
   90     38.05     0.141    0.3%
   92     38.52     0.125    0.3%
   94     38.78     0.184    0.4%
   96     38.46     0.252    0.6%
   98     38.32     0.164    0.4%
  100     38.82     0.226    0.5%

Quality and confidence:
param     error
s             0

Model:
Time ~=    35.85
    + s    0.029
              µs

Reads = 4 + (0 * s)
Writes = 2 + (0 * s)

Pallet: "pallet_nomination_pools", Extrinsic: "withdraw_unbonded_update", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools PoolMembers (r:1 w:1)
Storage: Staking CurrentEra (r:1 w:0)
Storage: NominationPools BondedPools (r:1 w:1)
Storage: NominationPools SubPoolsStorage (r:1 w:1)
Storage: Staking Ledger (r:1 w:1)
Storage: Balances Locks (r:1 w:1)
Storage: System Account (r:1 w:1)
Storage: NominationPools CounterForPoolMembers (r:1 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    72.48
    + s    0.035
              µs

Reads = 8 + (0 * s)
Writes = 7 + (0 * s)

Min Squares Analysis
========
-- Extrinsic Time --

Data points distribution:
    s   mean µs  sigma µs       %
    0     71.67     0.161    0.2%
    2     71.71     0.313    0.4%
    4     71.92     0.157    0.2%
    6     72.02     0.286    0.3%
    8     72.81     0.251    0.3%
   10     71.97     0.383    0.5%
   12     72.73     0.163    0.2%
   14     74.13     0.222    0.2%
   16      75.6     0.338    0.4%
   18     73.63     0.292    0.3%
   20     89.74     21.17   23.5%
   22     74.08      0.44    0.5%
   24     73.98      0.24    0.3%
   26     74.41     0.332    0.4%
   28     73.74     0.227    0.3%
   30     73.26     0.283    0.3%
   32     74.27     0.457    0.6%
   34     74.23     0.167    0.2%
   36     73.47     0.239    0.3%
   38     73.29     0.126    0.1%
   40     73.44     0.155    0.2%
   42     74.71     0.774    1.0%
   44     73.54      0.17    0.2%
   46     75.56     0.288    0.3%
   48     75.81     0.535    0.7%
   50     73.79     0.186    0.2%
   52     73.82      0.31    0.4%
   54     75.45     0.363    0.4%
   56     74.21     0.172    0.2%
   58      74.3     0.256    0.3%
   60     74.36     0.172    0.2%
   62     74.59     0.247    0.3%
   64     74.84     0.304    0.4%
   66      74.4     0.246    0.3%
   68     74.96     0.285    0.3%
   70     75.45     0.552    0.7%
   72     75.03     0.312    0.4%
   74     74.66     0.284    0.3%
   76     74.99      0.47    0.6%
   78     74.74     0.494    0.6%
   80     75.64     0.515    0.6%
   82     75.24     0.251    0.3%
   84     75.38     0.233    0.3%
   86     75.37     0.499    0.6%
   88     75.29     0.271    0.3%
   90     75.48     0.648    0.8%
   92     76.57     0.262    0.3%
   94     76.95     0.618    0.8%
   96     75.61     0.447    0.5%
   98      75.8     0.549    0.7%
  100     75.77     0.219    0.2%

Quality and confidence:
param     error
s         0.005

Model:
Time ~=    73.51
    + s    0.023
              µs

Reads = 8 + (0 * s)
Writes = 7 + (0 * s)

Pallet: "pallet_nomination_pools", Extrinsic: "withdraw_unbonded_kill", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools PoolMembers (r:1 w:1)
Storage: Staking CurrentEra (r:1 w:0)
Storage: NominationPools BondedPools (r:1 w:1)
Storage: NominationPools SubPoolsStorage (r:1 w:1)
Storage: Staking Ledger (r:1 w:1)
Storage: Staking Bonded (r:1 w:1)
Storage: Staking SlashingSpans (r:1 w:0)
Storage: Staking Validators (r:1 w:0)
Storage: Staking Nominators (r:1 w:0)
Storage: System Account (r:2 w:2)
Storage: Balances Locks (r:1 w:1)
Storage: NominationPools CounterForPoolMembers (r:1 w:1)
Storage: NominationPools ReversePoolIdLookup (r:1 w:1)
Storage: NominationPools CounterForReversePoolIdLookup (r:1 w:1)
Storage: NominationPools RewardPools (r:1 w:1)
Storage: NominationPools CounterForRewardPools (r:1 w:1)
Storage: NominationPools CounterForSubPoolsStorage (r:1 w:1)
Storage: NominationPools CounterForBondedPools (r:1 w:1)
Storage: Staking Payee (r:0 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    127.4
    + s    0.005
              µs

Reads = 19 + (0 * s)
Writes = 16 + (0 * s)

Min Squares Analysis
========
-- Extrinsic Time --

Data points distribution:
    s   mean µs  sigma µs       %
    0     127.5      0.61    0.4%
    2     127.7     1.178    0.9%
    4     130.3     0.365    0.2%
    6     127.4      0.71    0.5%
    8     127.5     1.108    0.8%
   10     127.1     0.791    0.6%
   12     127.7     0.625    0.4%
   14     127.9     1.212    0.9%
   16       127     0.352    0.2%
   18       127     0.349    0.2%
   20     127.3     1.069    0.8%
   22       127     0.496    0.3%
   24     127.3     0.611    0.4%
   26     127.5     1.044    0.8%
   28     129.6     0.399    0.3%
   30     128.5      1.34    1.0%
   32     127.1     0.376    0.2%
   34     126.9     0.402    0.3%
   36     127.6     1.005    0.7%
   38     127.4      0.59    0.4%
   40       127     0.897    0.7%
   42     126.8     0.675    0.5%
   44     127.8     1.157    0.9%
   46     126.5     0.362    0.2%
   48     126.9     0.337    0.2%
   50     127.3     0.766    0.6%
   52     127.7     0.839    0.6%
   54     127.3     0.574    0.4%
   56       128     0.701    0.5%
   58     127.3     0.631    0.4%
   60       130     0.375    0.2%
   62     127.4     0.427    0.3%
   64     127.6     0.292    0.2%
   66       127     0.343    0.2%
   68       130       0.5    0.3%
   70     127.3     0.659    0.5%
   72     127.1     0.547    0.4%
   74     130.2     0.859    0.6%
   76     129.8     0.571    0.4%
   78     127.6     0.347    0.2%
   80     128.2     1.496    1.1%
   82     129.7     0.467    0.3%
   84     128.2      1.19    0.9%
   86     126.9     0.434    0.3%
   88     126.7     0.505    0.3%
   90     126.7     0.623    0.4%
   92     127.2     0.683    0.5%
   94     127.5     0.766    0.6%
   96     127.2     0.383    0.3%
   98     129.8     0.518    0.3%
  100       130     0.584    0.4%

Quality and confidence:
param     error
s         0.001

Model:
Time ~=    127.5
    + s    0.007
              µs

Reads = 19 + (0 * s)
Writes = 16 + (0 * s)

Pallet: "pallet_nomination_pools", Extrinsic: "create", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Staking MinNominatorBond (r:1 w:0)
Storage: NominationPools MinCreateBond (r:1 w:0)
Storage: NominationPools MinJoinBond (r:1 w:0)
Storage: NominationPools MaxPools (r:1 w:0)
Storage: NominationPools CounterForBondedPools (r:1 w:1)
Storage: NominationPools PoolMembers (r:1 w:1)
Storage: NominationPools LastPoolId (r:1 w:1)
Storage: NominationPools MaxPoolMembersPerPool (r:1 w:0)
Storage: NominationPools MaxPoolMembers (r:1 w:0)
Storage: NominationPools CounterForPoolMembers (r:1 w:1)
Storage: System Account (r:2 w:2)
Storage: Staking Ledger (r:1 w:1)
Storage: Staking Bonded (r:1 w:1)
Storage: Staking CurrentEra (r:1 w:0)
Storage: Staking HistoryDepth (r:1 w:0)
Storage: Balances Locks (r:1 w:1)
Storage: NominationPools RewardPools (r:1 w:1)
Storage: NominationPools CounterForRewardPools (r:1 w:1)
Storage: NominationPools ReversePoolIdLookup (r:1 w:1)
Storage: NominationPools CounterForReversePoolIdLookup (r:1 w:1)
Storage: NominationPools BondedPools (r:1 w:1)
Storage: Staking Payee (r:0 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    122.7
              µs

Reads = 22
Writes = 15

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=    122.7
              µs

Reads = 22
Writes = 15

Pallet: "pallet_nomination_pools", Extrinsic: "nominate", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools BondedPools (r:1 w:0)
Storage: Staking Ledger (r:1 w:0)
Storage: Staking MinNominatorBond (r:1 w:0)
Storage: Staking Nominators (r:1 w:1)
Storage: Staking MaxNominatorsCount (r:1 w:0)
Storage: Staking Validators (r:2 w:0)
Storage: Staking CurrentEra (r:1 w:0)
Storage: Staking Bonded (r:1 w:0)
Storage: VoterList ListNodes (r:1 w:1)
Storage: VoterList ListBags (r:1 w:1)
Storage: VoterList CounterForListNodes (r:1 w:1)
Storage: Staking CounterForNominators (r:1 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    43.46
    + n    2.014
              µs

Reads = 12 + (1 * n)
Writes = 5 + (0 * n)

Min Squares Analysis
========
-- Extrinsic Time --

Data points distribution:
    n   mean µs  sigma µs       %
    1     43.62     0.182    0.4%
    2     47.95     0.401    0.8%
    3     49.76     0.275    0.5%
    4     51.85     0.297    0.5%
    5     53.94     0.234    0.4%
    6     55.59     0.367    0.6%
    7     57.73     0.145    0.2%
    8     59.54     0.164    0.2%
    9     60.24     0.183    0.3%
   10     63.04     0.459    0.7%
   11     65.04     0.683    1.0%
   12     68.46     0.474    0.6%
   13     68.85     0.707    1.0%
   14     71.01     0.473    0.6%
   15     72.59      0.31    0.4%
   16     77.21     0.417    0.5%

Quality and confidence:
param     error
n         0.015

Model:
Time ~=     43.2
    + n    2.024
              µs

Reads = 12 + (1 * n)
Writes = 5 + (0 * n)

Pallet: "pallet_nomination_pools", Extrinsic: "set_state", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools BondedPools (r:1 w:1)
Storage: Staking Ledger (r:1 w:0)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    20.65
              µs

Reads = 2
Writes = 1

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=    20.65
              µs

Reads = 2
Writes = 1

Pallet: "pallet_nomination_pools", Extrinsic: "set_metadata", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools BondedPools (r:1 w:0)
Storage: NominationPools Metadata (r:1 w:1)
Storage: NominationPools CounterForMetadata (r:1 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=     9.34
    + n    0.001
              µs

Reads = 3 + (0 * n)
Writes = 2 + (0 * n)

Min Squares Analysis
========
-- Extrinsic Time --

Data points distribution:
    n   mean µs  sigma µs       %
    1     9.337      0.07    0.7%
    6     9.108     0.066    0.7%
   11     9.297      0.06    0.6%
   16     9.267     0.075    0.8%
   21     9.392     0.046    0.4%
   26      9.36     0.072    0.7%
   31      9.35     0.109    1.1%
   36     9.451     0.041    0.4%
   41     9.408     0.054    0.5%
   46     9.276     0.078    0.8%
   51     9.339     0.046    0.4%
   56      9.38     0.086    0.9%
   61     9.439     0.119    1.2%
   66     9.482     0.042    0.4%
   71     9.517     0.062    0.6%
   76     9.451     0.092    0.9%
   81     9.461     0.034    0.3%
   86     9.448     0.064    0.6%
   91     9.559     0.071    0.7%
   96     9.494     0.053    0.5%
  101     9.579     0.084    0.8%
  106     9.546     0.062    0.6%
  111     9.495     0.049    0.5%
  116     9.592     0.063    0.6%
  121     9.519     0.066    0.6%
  126     9.504     0.058    0.6%
  131     9.382     0.056    0.5%
  136     9.549     0.087    0.9%
  141      9.59     0.049    0.5%
  146     9.319     0.075    0.8%
  151     9.582     0.055    0.5%
  156     9.481     0.068    0.7%
  161     9.394     0.095    1.0%
  166     9.458     0.077    0.8%
  171     9.447     0.102    1.0%
  176     9.608     0.068    0.7%
  181     9.639     0.096    0.9%
  186     9.477      0.07    0.7%
  191     9.595     0.086    0.8%
  196     9.569     0.052    0.5%
  201     9.668     0.079    0.8%
  206     9.593     0.067    0.6%
  211     9.654     0.085    0.8%
  216     9.634     0.085    0.8%
  221     9.538     0.091    0.9%
  226     9.746     0.101    1.0%
  231     9.639     0.123    1.2%
  236     9.647     0.077    0.7%
  241     9.672     0.061    0.6%
  246     9.582     0.058    0.6%
  251     9.593     0.092    0.9%
  256     9.453     0.073    0.7%

Quality and confidence:
param     error
n             0

Model:
Time ~=    9.331
    + n    0.001
              µs

Reads = 3 + (0 * n)
Writes = 2 + (0 * n)

Pallet: "pallet_nomination_pools", Extrinsic: "set_configs", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools MinJoinBond (r:0 w:1)
Storage: NominationPools MaxPoolMembers (r:0 w:1)
Storage: NominationPools MaxPoolMembersPerPool (r:0 w:1)
Storage: NominationPools MinCreateBond (r:0 w:1)
Storage: NominationPools MaxPools (r:0 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    2.386
              µs

Reads = 0
Writes = 5

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=    2.386
              µs

Reads = 0
Writes = 5

Pallet: "pallet_nomination_pools", Extrinsic: "update_roles", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: NominationPools BondedPools (r:1 w:1)

Median Slopes Analysis
========
-- Extrinsic Time --

Model:
Time ~=    16.06
              µs

Reads = 1
Writes = 1

Min Squares Analysis
========
-- Extrinsic Time --

Model:
Time ~=    16.06
              µs

Reads = 1
Writes = 1


parity-benchapp[bot] avatar May 24 '22 11:05 parity-benchapp[bot]

When does this plan to go out?

I feel we should probably let this bake on Kusama a bit longer, especially given the recent bug reports.

Sounds like a good plan to me.

bkchr avatar May 25 '22 06:05 bkchr

Given

The above numbers are still my suggestion, but I this PR as it is has all the max counters set to 0, meaning that we can deploy this but no pool can be created. This will be helpful in making the process of enabling pools independent of a runtime upgrade.

This is ready to be merged.

kianenigma avatar Aug 02 '22 09:08 kianenigma

/bench runtime polkadot pallet_nomination_pools

kianenigma avatar Aug 02 '22 09:08 kianenigma

/cmd queue -c bench-bot $ runtime polkadot-dev pallet_nomination_pools

The command changed. Its explained here https://github.com/paritytech/pipeline-scripts/issues/63

ggwpez avatar Aug 02 '22 09:08 ggwpez

@ggwpez https://gitlab.parity.io/parity/mirrors/polkadot/-/jobs/1715060 was started for your command "$PIPELINE_SCRIPTS_DIR/bench-bot.sh" runtime polkadot-dev pallet_nomination_pools. Check out https://gitlab.parity.io/parity/mirrors/polkadot/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.

Comment /cmd cancel 39-9b0e7b6d-ee91-467a-9a06-7863516c8598 to cancel this command or /cmd cancel to cancel all commands in this pull request.

command-bot[bot] avatar Aug 02 '22 09:08 command-bot[bot]

@ggwpez Command "$PIPELINE_SCRIPTS_DIR/bench-bot.sh" runtime polkadot-dev pallet_nomination_pools has finished. Result: https://gitlab.parity.io/parity/mirrors/polkadot/-/jobs/1715060 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/polkadot/-/jobs/1715060/artifacts/download.

command-bot[bot] avatar Aug 02 '22 10:08 command-bot[bot]

/cmd fmt

kianenigma avatar Aug 02 '22 18:08 kianenigma

/cmd queue -c fmt $ 1

kianenigma avatar Aug 02 '22 18:08 kianenigma

@kianenigma https://gitlab.parity.io/parity/mirrors/polkadot/-/jobs/1716730 was started for your command "$PIPELINE_SCRIPTS_DIR/fmt.sh" 1. Check out https://gitlab.parity.io/parity/mirrors/polkadot/-/pipelines?page=1&scope=all&username=group_605_bot to know what else is being executed currently.

Comment /cmd cancel 3-78dfa55a-03eb-4ffc-b393-f8082c2e46d8 to cancel this command or /cmd cancel to cancel all commands in this pull request.

command-bot[bot] avatar Aug 02 '22 18:08 command-bot[bot]

@kianenigma Command "$PIPELINE_SCRIPTS_DIR/fmt.sh" 1 has finished. Result: https://gitlab.parity.io/parity/mirrors/polkadot/-/jobs/1716730 has finished. If any artifacts were generated, you can download them from https://gitlab.parity.io/parity/mirrors/polkadot/-/jobs/1716730/artifacts/download.

command-bot[bot] avatar Aug 02 '22 18:08 command-bot[bot]

bot rebase

kianenigma avatar Aug 02 '22 19:08 kianenigma

Branch is already up-to-date

bot merge

kianenigma avatar Aug 14 '22 11:08 kianenigma

Waiting for commit status.

Merge cancelled due to error. Error: Statuses failed for 36e7766bcf9d8f1ca8cdb78d67811d1759b73171

bot merge

kianenigma avatar Aug 14 '22 17:08 kianenigma