Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

contracts: Reduce size of deletion queue depth #11696

Merged
merged 4 commits into from
Jun 22, 2022

Conversation

athei
Copy link
Member

@athei athei commented Jun 17, 2022

The DeletionQueue storage item housed by pallet_contracts was bounded to have 157977 items of 128 byte each. The size was chosen before storage needed to be bounded to be as large as possible. There is no reason for it to be that large. We just set it to 128 which allows us to have 128 contracts queued for deletion at any time in point. Please note that we assume that the deletion of a contract is a rare occasion anyways.

This reduces the max encoded length of the item from 19MiB to 16KiB.

@github-actions github-actions bot added the A0-please_review Pull request needs code review. label Jun 17, 2022
@athei athei added B7-runtimenoteworthy C1-low PR touches the given topic and has a low impact on builders. D2-notlive 💤 PR contains changes in a runtime directory that is not deployed to a chain that requires an audit. labels Jun 17, 2022
@athei
Copy link
Member Author

athei commented Jun 17, 2022

/benchmark runtime pallet pallet_contracts

@parity-benchapp
Copy link

parity-benchapp bot commented Jun 17, 2022

Benchmark Runtime Pallet for branch "at/delqueue" with command cargo run --quiet --profile=production --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs

Toolchain: stable-x86_64-unknown-linux-gnu (default)
rustc 1.61.0 (fe5b13d68 2022-05-18)

Results
error: failed to write /tmp/rustcpPYQjX/lib.rmeta: No space left on device (os error 28)

error: could not compile `regex-syntax` due to previous error
error: failed to write /tmp/rustcd9giHF/lib.rmeta: No space left on device (os error 28)

error: could not compile `regex-syntax` due to previous error

ERROR: Unable to commit file ./frame/contracts/src/weights.rs

@radupopa2010
Copy link
Contributor

/benchmark runtime pallet pallet_contracts

@parity-benchapp
Copy link

parity-benchapp bot commented Jun 17, 2022

Benchmark Runtime Pallet for branch "at/delqueue" with command cargo run --quiet --profile=production --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs

Toolchain: stable-x86_64-unknown-linux-gnu (default)
rustc 1.61.0 (fe5b13d68 2022-05-18)

Results
Pallet: "pallet_contracts", Extrinsic: "on_process_deletion_queue_batch", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts DeletionQueue (r:1 w:0)

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

Model:
Time ~=    1.711
              µs

Reads = 1
Writes = 0

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

Model:
Time ~=    1.711
              µs

Reads = 1
Writes = 0

Pallet: "pallet_contracts", Extrinsic: "on_initialize_per_trie_key", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Skipped Metadata (r:0 w:0)

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

Model:
Time ~=    8.691
    + k     0.87
              µs

Reads = 1 + (0 * k)
Writes = 1 + (1 * k)

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

Data points distribution:
    k   mean µs  sigma µs       %
    0     8.857     0.066    0.7%
   20     29.61     0.094    0.3%
   40     46.59     0.161    0.3%
   60     62.63     0.348    0.5%
   80     78.05     0.433    0.5%
  100     93.26     0.234    0.2%
  120     109.8     1.638    1.4%
  140     126.4     0.256    0.2%
  160     144.3     0.527    0.3%
  180     164.4     1.586    0.9%
  200     183.7     4.469    2.4%
  220       198     0.684    0.3%
  240     215.9     0.596    0.2%
  260     234.2     1.324    0.5%
  280     251.1     1.553    0.6%
  300     266.8     1.337    0.5%
  320     286.6     2.638    0.9%
  340     304.9     2.079    0.6%
  360     318.8     1.024    0.3%
  380     340.1     0.588    0.1%
  400     356.8     1.394    0.3%
  420     373.3     1.147    0.3%
  440     395.9     3.603    0.9%
  460     408.7     2.767    0.6%
  480     430.2     3.712    0.8%
  500     446.3     2.738    0.6%
  520     464.6     1.798    0.3%
  540     484.6     4.725    0.9%
  560     496.7     2.441    0.4%
  580     518.4     5.295    1.0%
  600     532.2     1.176    0.2%
  620     549.3     1.517    0.2%
  640     567.5     4.005    0.7%
  660     587.3     4.817    0.8%
  680     602.3     2.112    0.3%
  700     623.1     7.593    1.2%
  720     640.2     4.776    0.7%
  740     657.8     13.88    2.1%
  760     675.8     10.92    1.6%
  780     691.5     9.772    1.4%
  800     708.8     6.459    0.9%
  820     725.2     7.849    1.0%
  840     739.5     3.081    0.4%
  860     767.7     10.52    1.3%
  880     770.1     1.391    0.1%
  900     798.4     9.453    1.1%
  920     808.1     7.595    0.9%
  940     825.3     7.567    0.9%
  960     855.4     10.84    1.2%
  980     859.3     7.692    0.8%
 1000     879.4     8.149    0.9%
 1020     900.4     13.19    1.4%

Quality and confidence:
param     error
k             0

Model:
Time ~=    7.624
    + k    0.875
              µs

Reads = 1 + (0 * k)
Writes = 1 + (1 * k)

Pallet: "pallet_contracts", Extrinsic: "on_initialize_per_queue_item", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts DeletionQueue (r:1 w:0)

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

Model:
Time ~=    8.225
    + q    1.988
              µs

Reads = 1 + (0 * q)
Writes = 1 + (0 * q)

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

Data points distribution:
    q   mean µs  sigma µs       %
    0     1.646     0.012    0.7%
    2     11.62     0.058    0.4%
    4     16.01      0.05    0.3%
    6     19.23     0.107    0.5%
    8     24.35     0.181    0.7%
   10      28.4     0.288    1.0%
   12     32.74     0.214    0.6%
   14     36.33     0.232    0.6%
   16     41.55     0.248    0.5%
   18     45.53     0.216    0.4%
   20     48.57     0.244    0.5%
   22     53.77     0.291    0.5%
   24     55.37     0.225    0.4%
   26     59.43     0.331    0.5%
   28     63.47      0.36    0.5%
   30     68.33     0.334    0.4%
   32      73.7     0.745    1.0%
   34     76.74     0.331    0.4%
   36     80.21     0.302    0.3%
   38     83.65     0.423    0.5%
   40     86.74     0.551    0.6%
   42     92.23     0.652    0.7%
   44     96.71     0.699    0.7%
   46     98.82     0.598    0.6%
   48     102.5     0.538    0.5%
   50     102.8       0.4    0.3%
   52     108.5     0.296    0.2%
   54     112.9     0.787    0.6%
   56       117     0.334    0.2%
   58     124.8     0.823    0.6%
   60     130.6     0.366    0.2%
   62     131.4     0.647    0.4%
   64     135.8     0.832    0.6%
   66     137.9     0.838    0.6%
   68     143.5     0.716    0.4%
   70     146.5     0.898    0.6%
   72     149.6     1.018    0.6%
   74     155.3     0.966    0.6%
   76     159.2      2.41    1.5%
   78     164.4     1.227    0.7%
   80     169.4     0.788    0.4%
   82     171.6     0.897    0.5%
   84     172.2     0.469    0.2%
   86     178.7     1.616    0.9%
   88     179.1     1.201    0.6%
   90     186.3     0.493    0.2%
   92     191.6     1.631    0.8%
   94     197.9     2.399    1.2%
   96       195     1.215    0.6%
   98     193.8     2.202    1.1%
  100     207.7     2.536    1.2%
  102     210.5     0.945    0.4%
  104     209.4     1.664    0.7%
  106     213.7     1.748    0.8%
  108     216.6      1.54    0.7%
  110     227.2     1.872    0.8%
  112     224.2     1.889    0.8%
  114     238.2     2.032    0.8%
  116     246.7     2.663    1.0%
  118     246.8     2.181    0.8%
  120     256.7     1.185    0.4%
  122     253.3     2.763    1.0%
  124       252     1.597    0.6%
  126     267.9     2.403    0.8%
  128     269.4     3.589    1.3%

Quality and confidence:
param     error
q         0.003

Model:
Time ~=    7.289
    + q    2.001
              µs

Reads = 1 + (0 * q)
Writes = 1 + (0 * q)

Pallet: "pallet_contracts", Extrinsic: "reinstrument", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts PristineCode (r:1 w:0)
Storage: Contracts CodeStorage (r:0 w:1)

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

Model:
Time ~=    29.14
    + c    0.047
              µs

Reads = 1 + (0 * c)
Writes = 1 + (0 * c)

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

Data points distribution:
    c   mean µs  sigma µs       %
    0     25.99     0.155    0.5%
 1284     91.46     0.216    0.2%
 2568     150.3     0.581    0.3%
 3852       214     1.796    0.8%
 5136     270.7     0.609    0.2%
 6420     341.3     8.261    2.4%
 7704     399.7     8.076    2.0%
 8988     456.2     8.115    1.7%
10272       522      11.9    2.2%
11556       572     9.524    1.6%
12840     648.4     8.998    1.3%
14124     721.1     14.97    2.0%
15408     768.3     11.48    1.4%
16692     821.8      4.67    0.5%
17976     893.3     13.92    1.5%
19260     952.7      16.5    1.7%
20544      1001     11.95    1.1%
21828      1069      20.1    1.8%
23112      1123     11.98    1.0%
24396      1182     15.65    1.3%
25680      1275     13.15    1.0%
26964      1331     15.91    1.1%
28248      1400     23.36    1.6%
29532      1445     16.64    1.1%
30816      1519     10.89    0.7%
32100      1562     13.75    0.8%
33384      1639     14.07    0.8%
34668      1686     12.37    0.7%
35952      1750     15.38    0.8%
37236      1804     12.96    0.7%
38520      1884     11.53    0.6%
39804      1927     19.97    1.0%
41088      1974     13.17    0.6%
42372      2039     14.04    0.6%
43656      2091     15.44    0.7%
44940      2177     11.23    0.5%
46224      2203     15.37    0.6%
47508      2286     12.38    0.5%
48792      2329     12.87    0.5%
50076      2441     14.45    0.5%
51360      2523     11.55    0.4%
52644      2575     12.15    0.4%
53928      2652      15.4    0.5%
55212      2684     16.07    0.5%
56496      2753     21.26    0.7%
57780      2815     16.04    0.5%
59064      2883     15.35    0.5%
60348      2927     13.62    0.4%
61632      2995     13.18    0.4%
62916      3053     20.59    0.6%
64200      3103     26.02    0.8%

Quality and confidence:
param     error
c             0

Model:
Time ~=    25.11
    + c    0.048
              µs

Reads = 1 + (0 * c)
Writes = 1 + (0 * c)

Pallet: "pallet_contracts", Extrinsic: "call_with_code_per_byte", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)
Storage: System Account (r:1 w:1)

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

Model:
Time ~=    311.5
    + c    0.051
              µs

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

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

Data points distribution:
    c   mean µs  sigma µs       %
    0     318.8     0.162    0.0%
 2621     457.7     10.36    2.2%
 5242     587.7     9.125    1.5%
 7863     732.3     14.68    2.0%
10484     856.2     12.03    1.4%
13105       996     1.442    0.1%
15726      1141      19.3    1.6%
18347      1269      15.1    1.1%
20968      1388     11.62    0.8%
23589      1511     13.78    0.9%
26210      1710     16.41    0.9%
28831      1823     7.446    0.4%
31452      1953     16.45    0.8%
34073      2067     13.35    0.6%
36694      2212     16.67    0.7%
39315      2324     12.97    0.5%
41936      2443     11.91    0.4%
44557      2579     8.662    0.3%
47178      2708     11.56    0.4%
49799      2921     18.24    0.6%
52420      3054     20.66    0.6%
55041      3210     12.35    0.3%
57662      3306      19.6    0.5%
60283      3461     12.01    0.3%
62904      3564      25.2    0.7%
65525      3702     16.31    0.4%
68146      3844     23.56    0.6%
70767      3973     27.35    0.6%
73388      4088     30.95    0.7%
76009      4220     20.14    0.4%
78630      4332      18.9    0.4%
81251      4468     7.225    0.1%
83872      4609     21.12    0.4%
86493      4838     28.49    0.5%
89114      4859     30.63    0.6%
91735      4970     21.52    0.4%
94356      5116     33.11    0.6%
96977      5245     19.92    0.3%
99598      5565     18.04    0.3%
102219      5704     28.77    0.5%
104840      5816     16.23    0.2%
107461      5939     40.81    0.6%
110082      6127     33.69    0.5%
112703      6212     26.44    0.4%
115324      6360     27.35    0.4%
117945      6493     15.97    0.2%
120566      6586     23.01    0.3%
123187      6683     23.14    0.3%
125808      6868     21.44    0.3%
128429      6983      31.6    0.4%
131050      7106      27.6    0.3%

Quality and confidence:
param     error
c             0

Model:
Time ~=    301.8
    + c    0.052
              µs

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

Pallet: "pallet_contracts", Extrinsic: "instantiate_with_code", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts CodeStorage (r:1 w:1)
Storage: Contracts Nonce (r:1 w:1)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Timestamp Now (r:1 w:0)
Storage: System Account (r:1 w:1)
Storage: Contracts PristineCode (r:0 w:1)
Storage: Contracts OwnerInfoOf (r:0 w:1)

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

Model:
Time ~=    384.3
    + c    0.126
    + s    0.001
              µs

Reads = 5 + (0 * c) + (0 * s)
Writes = 6 + (0 * c) + (0 * s)

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

Data points distribution:
    c     s   mean µs  sigma µs       %
    0 1048576      2221     17.95    0.8%
 1284 1048576      2190     17.19    0.7%
 2568 1048576      2359     22.53    0.9%
 3852 1048576      2536     20.97    0.8%
 5136 1048576      2679      10.3    0.3%
 6420 1048576      2894     22.92    0.7%
 7704 1048576      2994     19.43    0.6%
 8988 1048576      3175     21.73    0.6%
10272 1048576      3337     11.32    0.3%
11556 1048576      3511     15.01    0.4%
12840 1048576      3679     16.12    0.4%
14124 1048576      3831      19.8    0.5%
15408 1048576      4011     24.22    0.6%
16692 1048576      4204     19.23    0.4%
17976 1048576      4342     16.65    0.3%
19260 1048576      4495     18.38    0.4%
20544 1048576      4651     19.35    0.4%
21828 1048576      4814     21.61    0.4%
23112 1048576      4945     15.08    0.3%
24396 1048576      5108     41.87    0.8%
25680 1048576      5320     18.73    0.3%
26964 1048576      5471     41.53    0.7%
28248 1048576      5625     21.54    0.3%
29532 1048576      5758     17.26    0.2%
30816 1048576      5918     38.12    0.6%
32100 1048576      6093     23.12    0.3%
33384 1048576      6401     29.83    0.4%
34668 1048576      6470     24.61    0.3%
35952 1048576      6654     29.69    0.4%
37236 1048576      6781      28.1    0.4%
38520 1048576      6952     32.09    0.4%
39804 1048576      7115     31.32    0.4%
41088 1048576      7228     31.23    0.4%
42372 1048576      7442     35.08    0.4%
43656 1048576      7520      30.8    0.4%
44940 1048576      7732     31.11    0.4%
46224 1048576      7879     38.99    0.4%
47508 1048576      8047     33.94    0.4%
48792 1048576      8227     35.45    0.4%
50076 1048576      8471     33.82    0.3%
51360 1048576      8647     45.34    0.5%
52644 1048576      8777     46.81    0.5%
53928 1048576      8912     43.03    0.4%
55212 1048576      9057     26.21    0.2%
56496 1048576      9245      33.2    0.3%
57780 1048576      9377     31.87    0.3%
59064 1048576      9538     29.43    0.3%
60348 1048576      9678     23.91    0.2%
61632 1048576      9833     47.48    0.4%
62916 1048576     10000     35.06    0.3%
64200 1048576     10140     28.95    0.2%
64226     0      8450     41.67    0.4%
64226 20971      8498     28.59    0.3%
64226 41942      8532     37.71    0.4%
64226 62913      8593     23.16    0.2%
64226 83884      8580     32.93    0.3%
64226 104855      8615     45.01    0.5%
64226 125826      8597     33.22    0.3%
64226 146797      8708     33.34    0.3%
64226 167768      8734     24.41    0.2%
64226 188739      8775     21.91    0.2%
64226 209710      8826      36.4    0.4%
64226 230681      8811     32.79    0.3%
64226 251652      8887     41.78    0.4%
64226 272623      8876     42.07    0.4%
64226 293594      8922     41.56    0.4%
64226 314565      8939     29.32    0.3%
64226 335536      8984     26.93    0.2%
64226 356507      9004     16.25    0.1%
64226 377478      9079      47.3    0.5%
64226 398449      9132     39.58    0.4%
64226 419420      9114     32.42    0.3%
64226 440391      9207     29.14    0.3%
64226 461362      9168     30.47    0.3%
64226 482333      9258     39.85    0.4%
64226 503304      9256     31.95    0.3%
64226 524275      9306      41.8    0.4%
64226 545246      9303     21.69    0.2%
64226 566217      9396     20.86    0.2%
64226 587188      9393     46.37    0.4%
64226 608159      9425     29.72    0.3%
64226 629130      9452     30.11    0.3%
64226 650101      9502     23.39    0.2%
64226 671072      9532      46.1    0.4%
64226 692043      9564     32.29    0.3%
64226 713014      9599     37.33    0.3%
64226 733985      9651     30.43    0.3%
64226 754956      9640      35.7    0.3%
64226 775927      9728     35.57    0.3%
64226 796898      9716     32.99    0.3%
64226 817869      9789     27.83    0.2%
64226 838840      9773     36.27    0.3%
64226 859811      9876     43.01    0.4%
64226 880782      9843     30.21    0.3%
64226 901753      9929     37.08    0.3%
64226 922724      9915     13.89    0.1%
64226 943695      9969     35.21    0.3%
64226 964666      9991     53.75    0.5%
64226 985637     10000     47.56    0.4%
64226 1006608     10040     40.48    0.4%
64226 1027579     10060     24.02    0.2%
64226 1048550     10170     26.44    0.2%

Quality and confidence:
param     error
c             0
s             0

Model:
Time ~=    356.7
    + c    0.126
    + s    0.002
              µs

Reads = 5 + (0 * c) + (0 * s)
Writes = 6 + (0 * c) + (0 * s)

Pallet: "pallet_contracts", Extrinsic: "instantiate", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts CodeStorage (r:1 w:1)
Storage: Contracts Nonce (r:1 w:1)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Timestamp Now (r:1 w:0)
Storage: System Account (r:1 w:1)
Storage: Contracts OwnerInfoOf (r:1 w:1)

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

Model:
Time ~=    233.1
    + s    0.001
              µs

Reads = 6 + (0 * s)
Writes = 5 + (0 * s)

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

Data points distribution:
    s   mean µs  sigma µs       %
    0     230.3     0.319    0.1%
20971     267.1     0.271    0.1%
41942     303.3     0.695    0.2%
62913       339     0.296    0.0%
83884     380.3     9.253    2.4%
104855     411.3     0.659    0.1%
125826     446.7     0.425    0.0%
146797     483.8     5.082    1.0%
167768     526.8     13.48    2.5%
188739       553     1.502    0.2%
209710     597.3     10.51    1.7%
230681     626.6     7.933    1.2%
251652     667.5     12.79    1.9%
272623     710.9     15.39    2.1%
293594     733.1      5.23    0.7%
314565     769.6     8.435    1.0%
335536     808.7     11.32    1.4%
356507     848.6     14.14    1.6%
377478     893.4     13.09    1.4%
398449     916.3     11.24    1.2%
419420     953.5     11.45    1.2%
440391     989.4     15.37    1.5%
461362      1018     9.067    0.8%
482333      1064     13.08    1.2%
503304      1099     14.79    1.3%
524275      1149     9.632    0.8%
545246      1172     14.98    1.2%
566217      1200     11.27    0.9%
587188      1241     15.03    1.2%
608159      1274     13.27    1.0%
629130      1312     14.98    1.1%
650101      1341     13.74    1.0%
671072      1376      12.5    0.9%
692043      1429     12.41    0.8%
713014      1448     9.301    0.6%
733985      1489     15.75    1.0%
754956      1549     9.465    0.6%
775927      1581     16.49    1.0%
796898      1603     16.84    1.0%
817869      1633     17.79    1.0%
838840      1674     13.16    0.7%
859811      1707     16.83    0.9%
880782      1759     24.99    1.4%
901753      1783     15.57    0.8%
922724      1822     11.96    0.6%
943695      1860     20.41    1.0%
964666      1878     13.02    0.6%
985637      1932     10.47    0.5%
1006608      1981     16.24    0.8%
1027579      1979     11.94    0.6%
1048550      2026     13.88    0.6%

Quality and confidence:
param     error
s             0

Model:
Time ~=    232.9
    + s    0.002
              µs

Reads = 6 + (0 * s)
Writes = 5 + (0 * s)

Pallet: "pallet_contracts", Extrinsic: "call", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)
Storage: System Account (r:1 w:1)

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

Model:
Time ~=    197.7
              µs

Reads = 4
Writes = 2

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

Model:
Time ~=    197.7
              µs

Reads = 4
Writes = 2

Pallet: "pallet_contracts", Extrinsic: "upload_code", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts CodeStorage (r:1 w:1)
Storage: Contracts PristineCode (r:0 w:1)
Storage: Contracts OwnerInfoOf (r:0 w:1)

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

Model:
Time ~=     58.6
    + c    0.048
              µs

Reads = 1 + (0 * c)
Writes = 3 + (0 * c)

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

Data points distribution:
    c   mean µs  sigma µs       %
    0     53.73     0.127    0.2%
 1284     120.4     0.454    0.3%
 2568     183.5     1.458    0.7%
 3852     244.2     0.844    0.3%
 5136     308.9      8.36    2.7%
 6420     376.3      5.56    1.4%
 7704     430.1     3.901    0.9%
 8988     500.6     3.623    0.7%
10272     548.4     4.361    0.7%
11556     612.7     7.609    1.2%
12840     688.4     8.706    1.2%
14124     754.4     11.61    1.5%
15408     805.2     8.741    1.0%
16692     874.1     14.74    1.6%
17976     929.1     12.89    1.3%
19260     987.2     14.18    1.4%
20544      1045     11.94    1.1%
21828      1106     15.31    1.3%
23112      1171     13.82    1.1%
24396      1226     13.38    1.0%
25680      1315     16.58    1.2%
26964      1382     15.34    1.1%
28248      1446     15.47    1.0%
29532      1508     16.17    1.0%
30816      1578     12.06    0.7%
32100      1611      15.5    0.9%
33384      1693     11.57    0.6%
34668      1734     12.04    0.6%
35952      1808     11.84    0.6%
37236      1861     19.82    1.0%
38520      1921     15.49    0.8%
39804      1970     16.02    0.8%
41088      2051     16.44    0.8%
42372      2095     10.58    0.5%
43656      2163     7.463    0.3%
44940      2233     17.29    0.7%
46224      2291     12.52    0.5%
47508      2350     15.98    0.6%
48792      2409     10.53    0.4%
50076      2541     25.24    0.9%
51360      2576     10.81    0.4%
52644      2633     26.18    0.9%
53928      2714     8.179    0.3%
55212      2750     7.167    0.2%
56496      2797     21.28    0.7%
57780      2901     16.59    0.5%
59064      2931      21.2    0.7%
60348      3004     20.62    0.6%
61632      3071     16.76    0.5%
62916      3114     22.18    0.7%
64200      3176     14.94    0.4%

Quality and confidence:
param     error
c             0

Model:
Time ~=    54.57
    + c    0.049
              µs

Reads = 1 + (0 * c)
Writes = 3 + (0 * c)

Pallet: "pallet_contracts", Extrinsic: "remove_code", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts OwnerInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:0 w:1)
Storage: Contracts PristineCode (r:0 w:1)

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

Model:
Time ~=    29.54
              µs

Reads = 1
Writes = 3

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

Model:
Time ~=    29.54
              µs

Reads = 1
Writes = 3

Pallet: "pallet_contracts", Extrinsic: "set_code", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts OwnerInfoOf (r:2 w:2)

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

Model:
Time ~=     27.7
              µs

Reads = 3
Writes = 3

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

Model:
Time ~=     27.7
              µs

Reads = 3
Writes = 3

Pallet: "pallet_contracts", Extrinsic: "seal_caller", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    306.9
    + r    41.12
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     304.2     0.235    0.0%
    1     347.5     0.258    0.0%
    2     389.1     0.194    0.0%
    3     430.4     0.365    0.0%
    4     476.5     7.879    1.6%
    5     522.1     9.525    1.8%
    6     554.2     1.838    0.3%
    7     601.2     9.208    1.5%
    8     642.7     9.374    1.4%
    9     683.8     8.803    1.2%
   10       726     11.63    1.6%
   11     776.8     14.48    1.8%
   12     804.7      7.08    0.8%
   13     845.3      10.7    1.2%
   14     884.7     11.27    1.2%
   15     943.4     15.06    1.5%
   16     967.6     11.12    1.1%
   17      1015     15.13    1.4%
   18      1047     1.421    0.1%
   19      1101     15.34    1.3%
   20      1139     14.74    1.2%

Quality and confidence:
param     error
r         0.127

Model:
Time ~=    308.2
    + r    41.57
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_is_contract", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    215.4
    + r    303.8
              µs

Reads = 4 + (80 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     306.3     6.018    1.9%
    1       575     6.401    1.1%
    2     853.1     12.85    1.5%
    3      1121     9.933    0.8%
    4      1407     15.09    1.0%
    5      1707     11.85    0.6%
    6      1998     18.95    0.9%
    7      2313     20.38    0.8%
    8      2605     19.28    0.7%
    9      2892     14.76    0.5%
   10      3234     17.12    0.5%
   11      3563     16.52    0.4%
   12      3870     21.74    0.5%
   13      4148     22.35    0.5%
   14      4427     20.37    0.4%
   15      4750     21.72    0.4%
   16      5075     27.62    0.5%
   17      5391     11.33    0.2%
   18      5733     25.53    0.4%
   19      6009     23.41    0.3%
   20      6424     29.95    0.4%

Quality and confidence:
param     error
r         0.563

Model:
Time ~=    209.8
    + r    304.7
              µs

Reads = 4 + (80 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_code_hash", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    223.1
    + r    363.2
              µs

Reads = 4 + (80 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     306.6     0.241    0.0%
    1     628.3     6.105    0.9%
    2     959.3     10.43    1.0%
    3      1319     11.41    0.8%
    4      1651     11.02    0.6%
    5      2035     17.14    0.8%
    6      2358     12.13    0.5%
    7      2724     15.55    0.5%
    8      3062     17.36    0.5%
    9      3474     21.39    0.6%
   10      3828     13.09    0.3%
   11      4220     19.33    0.4%
   12      4561     16.03    0.3%
   13      4925     19.44    0.3%
   14      5209     9.712    0.1%
   15      5639      27.5    0.4%
   16      6064     18.42    0.3%
   17      6428     37.21    0.5%
   18      6812     34.36    0.5%
   19      7161     28.91    0.4%
   20      7649     21.51    0.2%

Quality and confidence:
param     error
r         0.648

Model:
Time ~=    208.1
    + r      365
              µs

Reads = 4 + (80 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_own_code_hash", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    307.4
    + r    44.67
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     304.9      0.36    0.1%
    1     352.7     2.125    0.6%
    2     396.2     0.208    0.0%
    3     441.6     1.513    0.3%
    4     486.2     1.978    0.4%
    5     534.3     8.053    1.5%
    6     575.2     0.649    0.1%
    7     622.8     2.159    0.3%
    8     665.8     5.994    0.9%
    9     716.5     11.22    1.5%
   10     759.5     7.823    1.0%
   11     807.3     12.06    1.4%
   12     852.6     11.73    1.3%
   13     895.7      10.7    1.1%
   14     932.6     6.333    0.6%
   15     984.7     12.97    1.3%
   16      1021      8.71    0.8%
   17      1072     11.97    1.1%
   18      1119     11.48    1.0%
   19      1168     15.18    1.2%
   20      1208     12.62    1.0%

Quality and confidence:
param     error
r         0.107

Model:
Time ~=    306.7
    + r    45.13
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_caller_is_origin", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    302.2
    + r    16.86
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     299.6     0.203    0.0%
    1     318.6      0.32    0.1%
    2     335.5     0.237    0.0%
    3       352     0.358    0.1%
    4     371.3      2.31    0.6%
    5     386.7      0.34    0.0%
    6     414.9     4.305    1.0%
    7     420.9     0.225    0.0%
    8       443     8.489    1.9%
    9     460.5     6.926    1.5%
   10     472.6     5.858    1.2%
   11     487.4      3.55    0.7%
   12     502.9     2.959    0.5%
   13     529.4      5.86    1.1%
   14     554.4     16.62    2.9%
   15     564.5     10.37    1.8%
   16     573.2     4.864    0.8%
   17     591.7     5.979    1.0%
   18     603.6     2.004    0.3%
   19     620.3     2.492    0.4%
   20       651     15.53    2.3%

Quality and confidence:
param     error
r         0.095

Model:
Time ~=    302.8
    + r    17.12
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_address", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    307.8
    + r    40.75
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     305.2     2.101    0.6%
    1     347.7     0.327    0.0%
    2     398.7     2.803    0.7%
    3     431.5     2.294    0.5%
    4     474.4     5.024    1.0%
    5     514.4     7.075    1.3%
    6     552.6     2.504    0.4%
    7     595.2     8.105    1.3%
    8     631.6     0.589    0.0%
    9     679.7     11.13    1.6%
   10     720.6     10.76    1.4%
   11     755.2     2.918    0.3%
   12       805     11.82    1.4%
   13     848.4     11.64    1.3%
   14     881.3     10.17    1.1%
   15     920.8     10.11    1.0%
   16     968.7     13.56    1.4%
   17      1012      11.6    1.1%
   18      1059     14.58    1.3%
   19      1099     13.54    1.2%
   20      1131     14.54    1.2%

Quality and confidence:
param     error
r         0.117

Model:
Time ~=    306.7
    + r    41.39
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_gas_left", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    306.8
    + r    40.43
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     304.6     0.118    0.0%
    1     346.9     0.173    0.0%
    2     387.8     0.177    0.0%
    3     428.5     0.346    0.0%
    4     468.3      0.48    0.1%
    5     510.9     2.577    0.5%
    6     548.3     0.374    0.0%
    7     593.1      6.05    1.0%
    8     634.5     8.446    1.3%
    9     682.3     6.613    0.9%
   10     718.3     10.64    1.4%
   11     762.5     12.76    1.6%
   12     795.1       8.2    1.0%
   13     832.3     7.969    0.9%
   14     876.2     12.51    1.4%
   15     916.9     11.57    1.2%
   16     953.2     10.17    1.0%
   17      1000     14.52    1.4%
   18      1048     15.21    1.4%
   19      1090     15.74    1.4%
   20      1140     10.64    0.9%

Quality and confidence:
param     error
r         0.119

Model:
Time ~=    304.4
    + r    41.17
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_balance", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    314.1
    + r    117.4
              µs

Reads = 5 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     303.6      0.08    0.0%
    1     429.7     4.396    1.0%
    2     542.9     0.701    0.1%
    3     673.6      13.5    2.0%
    4       780     6.036    0.7%
    5       902     12.15    1.3%
    6      1022     10.04    0.9%
    7      1141     12.33    1.0%
    8      1246     9.701    0.7%
    9      1380     15.33    1.1%
   10      1497      12.9    0.8%
   11      1613     16.23    1.0%
   12      1725     14.04    0.8%
   13      1849     5.168    0.2%
   14      1960     14.79    0.7%
   15      2075     14.03    0.6%
   16      2180     7.166    0.3%
   17      2321     8.431    0.3%
   18      2439     7.971    0.3%
   19      2558     8.607    0.3%
   20      2656     19.04    0.7%

Quality and confidence:
param     error
r         0.151

Model:
Time ~=    312.2
    + r    117.8
              µs

Reads = 5 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_value_transferred", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    307.3
    + r    40.55
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     304.3     0.108    0.0%
    1     346.8     0.239    0.0%
    2     388.7     0.343    0.0%
    3     429.3     0.209    0.0%
    4     468.8     0.433    0.0%
    5     517.8     5.554    1.0%
    6     559.3     13.46    2.4%
    7     598.8     12.23    2.0%
    8     634.5     10.64    1.6%
    9     679.3     10.38    1.5%
   10     720.1     11.76    1.6%
   11     761.5     11.95    1.5%
   12     801.8     10.96    1.3%
   13     841.1     12.23    1.4%
   14     872.6     3.742    0.4%
   15     912.1     2.746    0.3%
   16     965.7     10.47    1.0%
   17      1000     11.31    1.1%
   18      1056     12.94    1.2%
   19      1090     14.31    1.3%
   20      1133     13.13    1.1%

Quality and confidence:
param     error
r         0.123

Model:
Time ~=    306.9
    + r    41.13
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_minimum_balance", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    307.7
    + r    40.39
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     304.8     1.031    0.3%
    1     348.3     4.413    1.2%
    2     389.7     3.824    0.9%
    3       437     6.918    1.5%
    4     470.2     3.656    0.7%
    5     514.4     5.775    1.1%
    6     556.9     10.56    1.8%
    7     597.5     12.21    2.0%
    8     631.5     7.734    1.2%
    9     676.6     7.839    1.1%
   10     717.2     10.73    1.4%
   11     756.4     9.023    1.1%
   12     795.9     8.853    1.1%
   13     836.3     10.28    1.2%
   14     870.2     1.577    0.1%
   15       909     0.842    0.0%
   16       965     13.05    1.3%
   17     997.1     13.07    1.3%
   18      1055     14.18    1.3%
   19      1084     12.11    1.1%
   20      1128     13.74    1.2%

Quality and confidence:
param     error
r          0.12

Model:
Time ~=    308.1
    + r    40.81
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_block_number", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    307.2
    + r    40.24
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     304.2     0.244    0.0%
    1     346.8       0.3    0.0%
    2     396.4     4.585    1.1%
    3     428.6     2.126    0.4%
    4     470.3      7.92    1.6%
    5     509.3     1.778    0.3%
    6     549.8     2.394    0.4%
    7     588.8     2.551    0.4%
    8     628.8     4.537    0.7%
    9     674.7     9.953    1.4%
   10     716.6     8.958    1.2%
   11     755.2     8.765    1.1%
   12     798.5     11.46    1.4%
   13     837.2     11.91    1.4%
   14     871.8     8.202    0.9%
   15     908.1     1.145    0.1%
   16     954.8     11.83    1.2%
   17     998.7     15.38    1.5%
   18      1041     11.25    1.0%
   19      1078     10.33    0.9%
   20      1127        14    1.2%

Quality and confidence:
param     error
r         0.106

Model:
Time ~=    306.8
    + r    40.67
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_now", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    308.1
    + r    40.25
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     309.6     2.714    0.8%
    1     346.9     0.255    0.0%
    2     391.2     4.675    1.1%
    3     429.3     2.065    0.4%
    4     471.4     7.678    1.6%
    5     509.8     0.653    0.1%
    6       550     2.313    0.4%
    7     604.4     10.41    1.7%
    8     627.3     0.875    0.1%
    9       677     10.52    1.5%
   10     710.5     1.711    0.2%
   11     760.1     12.15    1.5%
   12     800.5     12.61    1.5%
   13     832.4     7.856    0.9%
   14     875.5     10.48    1.1%
   15     916.4     8.736    0.9%
   16     955.3     9.051    0.9%
   17     988.3     3.494    0.3%
   18      1046      13.7    1.3%
   19      1094     16.59    1.5%
   20      1125     12.48    1.1%

Quality and confidence:
param     error
r         0.118

Model:
Time ~=    307.7
    + r    40.76
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_weight_to_fee", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)
Storage: TransactionPayment NextFeeMultiplier (r:1 w:0)

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

Model:
Time ~=    312.4
    + r    99.63
              µs

Reads = 5 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     309.2     2.849    0.9%
    1       410     1.524    0.3%
    2       520     6.206    1.1%
    3     612.3     8.377    1.3%
    4     714.9     10.91    1.5%
    5     825.4     10.56    1.2%
    6     909.1     9.576    1.0%
    7      1025      11.3    1.1%
    8      1103     2.932    0.2%
    9      1208     11.08    0.9%
   10      1312     15.76    1.2%
   11      1423     10.19    0.7%
   12      1514     16.59    1.0%
   13      1626     18.14    1.1%
   14      1715     14.98    0.8%
   15      1830     11.92    0.6%
   16      1918      11.3    0.5%
   17      2009     13.63    0.6%
   18      2116     22.39    1.0%
   19      2209     11.95    0.5%
   20      2307     15.07    0.6%

Quality and confidence:
param     error
r         0.163

Model:
Time ~=    314.8
    + r      100
              µs

Reads = 5 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_gas", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    183.8
    + r    19.62
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     181.2     0.111    0.0%
    1       203     0.262    0.1%
    2     222.8     0.114    0.0%
    3     242.9     0.374    0.1%
    4       263     0.168    0.0%
    5     281.5     0.085    0.0%
    6     300.9     0.251    0.0%
    7     322.3     0.359    0.1%
    8     341.3     0.282    0.0%
    9     362.1     2.448    0.6%
   10     386.7     10.95    2.8%
   11     398.7     1.702    0.4%
   12     421.6     4.593    1.0%
   13     440.9     2.081    0.4%
   14     459.9     0.648    0.1%
   15     477.8     0.403    0.0%
   16     497.5     0.301    0.0%
   17     517.2     0.594    0.1%
   18     536.1     0.363    0.0%
   19     559.9     8.573    1.5%
   20     574.6     1.545    0.2%

Quality and confidence:
param     error
r         0.043

Model:
Time ~=    183.8
    + r    19.67
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_input", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    307.4
    + r    39.57
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     304.2     0.213    0.0%
    1     346.6     0.178    0.0%
    2     386.7     0.277    0.0%
    3     428.3     4.304    1.0%
    4     466.1     2.063    0.4%
    5     506.9     2.717    0.5%
    6     557.8     11.37    2.0%
    7     589.2     5.408    0.9%
    8     627.5     8.055    1.2%
    9     669.1     8.302    1.2%
   10     705.2     3.317    0.4%
   11     755.5      14.1    1.8%
   12     786.1     11.88    1.5%
   13     821.3     3.716    0.4%
   14     858.3      0.71    0.0%
   15     896.9     0.927    0.1%
   16     939.8     1.906    0.2%
   17     988.8     13.36    1.3%
   18      1031     12.09    1.1%
   19      1067     11.57    1.0%
   20      1106     10.97    0.9%

Quality and confidence:
param     error
r         0.104

Model:
Time ~=    308.2
    + r    39.84
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_input_per_kb", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    369.9
    + n    9.664
              µs

Reads = 4 + (0 * n)
Writes = 1 + (0 * n)

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

Data points distribution:
    n   mean µs  sigma µs       %
    0     346.7     0.266    0.0%
   20     546.4     8.547    1.5%
   40       755     13.46    1.7%
   60     944.5     17.02    1.8%
   80      1147     18.51    1.6%
  100      1336     18.78    1.4%
  120      1526     15.11    0.9%
  140      1717        12    0.6%
  160      1931      6.82    0.3%
  180      2113     24.19    1.1%
  200      2304     14.86    0.6%
  220      2495     14.59    0.5%
  240      2699      10.7    0.3%
  260      2895     14.47    0.4%
  280      3082     11.87    0.3%
  300      3294     16.63    0.5%
  320      3473     19.96    0.5%
  340      3655     15.01    0.4%
  360      3849     13.71    0.3%
  380      4027     19.53    0.4%
  400      4234     12.03    0.2%
  420      4436     30.03    0.6%
  440      4617     18.06    0.3%
  460      4822     26.87    0.5%
  480      4992     17.36    0.3%
  500      5215     30.62    0.5%
  520      5395     25.62    0.4%
  540      5595     18.89    0.3%
  560      5774     16.03    0.2%
  580      5979     19.17    0.3%
  600      6143     18.95    0.3%
  620      6358     24.84    0.3%
  640      6574     17.45    0.2%
  660      6728     24.67    0.3%
  680      6936     17.33    0.2%
  700      7164        24    0.3%
  720      7313      22.2    0.3%
  740      7509     24.42    0.3%
  760      7802     28.33    0.3%
  780      7894     20.95    0.2%
  800      8074     21.88    0.2%
  820      8243     11.52    0.1%
  840      8524     29.73    0.3%
  860      8718     33.55    0.3%
  880      8896     18.31    0.2%
  900      9068     28.69    0.3%
  920      9215     25.52    0.2%
  940      9441     40.52    0.4%
  960      9620     27.16    0.2%
  980      9850     37.76    0.3%
 1000     10080     35.99    0.3%
 1020     10240     40.25    0.3%

Quality and confidence:
param     error
n         0.004

Model:
Time ~=      368
    + n    9.671
              µs

Reads = 4 + (0 * n)
Writes = 1 + (0 * n)

Pallet: "pallet_contracts", Extrinsic: "seal_return", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    300.5
    + r    1.392
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     305.3     6.142    2.0%
    1     301.8     0.229    0.0%

Quality and confidence:
param     error
r         2.049

Model:
Time ~=    305.3
    + r        0
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_return_per_kb", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    301.9
    + n    0.228
              µs

Reads = 4 + (0 * n)
Writes = 1 + (0 * n)

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

Data points distribution:
    n   mean µs  sigma µs       %
    0     301.9      0.18    0.0%
   20     306.5     0.241    0.0%
   40     311.2     0.224    0.0%
   60     319.9     6.551    2.0%
   80     322.6      6.82    2.1%
  100     326.1     3.876    1.1%
  120       332     5.705    1.7%
  140     333.8     0.262    0.0%
  160     343.2     6.392    1.8%
  180     342.8     0.168    0.0%
  200       348     0.162    0.0%
  220     351.8     0.221    0.0%
  240     356.7     0.179    0.0%
  260     371.3     11.23    3.0%
  280       366     0.353    0.0%
  300     385.3     16.52    4.2%
  320     375.1     0.258    0.0%
  340     379.4     0.188    0.0%
  360     384.1      0.27    0.0%
  380     388.3     0.165    0.0%
  400     397.5     8.863    2.2%
  420     401.1     7.283    1.8%
  440     410.4     4.575    1.1%
  460     406.9     0.485    0.1%
  480     411.5      0.23    0.0%
  500     419.3     8.091    1.9%
  520     420.8     0.457    0.1%
  540     429.4     8.952    2.0%
  560     430.8     4.325    1.0%
  580       446     14.26    3.1%
  600     438.7     0.341    0.0%
  620     448.2     9.981    2.2%
  640     458.9     13.22    2.8%
  660     458.4     10.67    2.3%
  680       457     0.118    0.0%
  700     476.3     9.065    1.9%
  720       466     0.148    0.0%
  740     488.9     10.49    2.1%
  760     478.3     8.312    1.7%
  780     485.4     11.18    2.3%
  800     484.5     0.276    0.0%
  820     495.4     7.982    1.6%
  840     495.3     3.753    0.7%
  860     500.3     5.002    0.9%
  880     505.9     8.724    1.7%
  900     517.5     16.48    3.1%
  920     513.4     4.183    0.8%
  940     518.5     5.412    1.0%
  960     521.3     0.397    0.0%
  980     538.8     7.525    1.3%
 1000     529.9     0.138    0.0%
 1020     545.7     14.33    2.6%

Quality and confidence:
param     error
n         0.001

Model:
Time ~=    303.3
    + n    0.233
              µs

Reads = 4 + (0 * n)
Writes = 1 + (0 * n)

Pallet: "pallet_contracts", Extrinsic: "seal_terminate", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)
Storage: Contracts DeletionQueue (r:1 w:1)
Storage: Contracts OwnerInfoOf (r:1 w:1)

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

Model:
Time ~=    304.1
    + r    55.33
              µs

Reads = 4 + (4 * r)
Writes = 1 + (5 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     308.6     9.459    3.0%
    1     359.4     0.211    0.0%

Quality and confidence:
param     error
r         3.154

Model:
Time ~=    308.6
    + r    50.88
              µs

Reads = 4 + (4 * r)
Writes = 1 + (5 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_random", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)
Storage: RandomnessCollectiveFlip RandomMaterial (r:1 w:0)

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

Model:
Time ~=    318.2
    + r    133.8
              µs

Reads = 5 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     305.7     4.358    1.4%
    1     441.4     0.172    0.0%
    2     576.5     4.888    0.8%
    3     715.2     7.754    1.0%
    4     849.8     8.783    1.0%
    5     999.3     14.67    1.4%
    6      1137     12.93    1.1%
    7      1271     14.17    1.1%
    8      1395      9.97    0.7%
    9      1532      14.9    0.9%
   10      1680     13.55    0.8%
   11      1797     22.39    1.2%
   12      1928     13.65    0.7%
   13      2070     13.98    0.6%
   14      2203     6.952    0.3%
   15      2335     10.53    0.4%
   16      2450     14.92    0.6%
   17      2608     22.96    0.8%
   18      2720     21.04    0.7%
   19      2852     16.17    0.5%
   20      2979      17.6    0.5%

Quality and confidence:
param     error
r         0.205

Model:
Time ~=    320.5
    + r    133.9
              µs

Reads = 5 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_deposit_event", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=    319.8
    + r    238.5
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     299.5     0.302    0.1%
    1     553.9     4.989    0.9%
    2     790.3     4.586    0.5%
    3      1041     13.24    1.2%
    4      1297     12.44    0.9%
    5      1516     15.23    1.0%
    6      1753     13.91    0.7%
    7      1989     6.789    0.3%
    8      2239     16.06    0.7%
    9      2470     10.71    0.4%
   10      2710     15.94    0.5%
   11      2980     13.32    0.4%
   12      3188     24.67    0.7%
   13      3413     6.021    0.1%
   14      3646     13.13    0.3%
   15      3946     26.56    0.6%
   16      4168     13.48    0.3%
   17      4352     10.53    0.2%
   18      4588     11.61    0.2%
   19      4873     13.44    0.2%
   20      5072     16.09    0.3%

Quality and confidence:
param     error
r         0.272

Model:
Time ~=    322.3
    + r    238.6
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_deposit_event_per_topic_and_kb", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)
Storage: System EventTopics (r:80 w:80)

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

Model:
Time ~=    571.3
    + t    266.3
    + n    70.24
              µs

Reads = 4 + (80 * t) + (0 * n)
Writes = 1 + (80 * t) + (0 * n)

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

Data points distribution:
    t     n   mean µs  sigma µs       %
    0    16      1673      14.7    0.8%
    1    16      1985     6.451    0.3%
    2    16      2226     7.069    0.3%
    3    16      2493     15.46    0.6%
    4     0      1604     19.74    1.2%
    4     1      1669     12.06    0.7%
    4     2      1734     16.81    0.9%
    4     3      1834     13.69    0.7%
    4     4      1870     17.32    0.9%
    4     5      1929     17.32    0.8%
    4     6      2015     14.35    0.7%
    4     7      2053     20.59    1.0%
    4     8      2137     13.54    0.6%
    4     9      2221     13.55    0.6%
    4    10      2282     15.57    0.6%
    4    11      2370     15.08    0.6%
    4    12      2414     13.65    0.5%
    4    13      2507     19.09    0.7%
    4    14      2561      10.5    0.4%
    4    15      2635      21.7    0.8%
    4    16      2757     18.24    0.6%

Quality and confidence:
param     error
t         1.858
n         0.366

Model:
Time ~=    566.8
    + t    255.2
    + n    71.09
              µs

Reads = 4 + (80 * t) + (0 * n)
Writes = 1 + (80 * t) + (0 * n)

Pallet: "pallet_contracts", Extrinsic: "seal_debug_message", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: System Account (r:1 w:0)
Storage: Contracts ContractInfoOf (r:1 w:1)
Storage: Contracts CodeStorage (r:1 w:0)
Storage: Timestamp Now (r:1 w:0)

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

Model:
Time ~=      193
    + r    33.25
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     189.8     0.241    0.1%
    1     226.3     0.246    0.1%
    2     259.9     0.233    0.0%
    3     291.8     0.592    0.2%
    4     326.2     0.317    0.0%
    5     357.9     0.394    0.1%
    6     391.5     0.573    0.1%
    7     431.4     7.717    1.7%
    8       465     8.115    1.7%
    9       502     15.19    3.0%
   10     524.9     0.757    0.1%
   11       558     5.946    1.0%
   12     586.2     1.136    0.1%
   13     633.3     10.89    1.7%
   14     661.2     6.263    0.9%
   15     709.9     13.13    1.8%
   16     725.1     3.229    0.4%
   17       763     9.828    1.2%
   18       812     10.85    1.3%
   19     822.4     3.412    0.4%
   20     855.8     7.437    0.8%

Quality and confidence:
param     error
r         0.106

Model:
Time ~=    192.2
    + r     33.6
              µs

Reads = 4 + (0 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_set_storage", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Skipped Metadata (r:0 w:0)

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

Model:
Time ~=    184.8
    + r      348
              µs

Reads = 4 + (80 * r)
Writes = 1 + (80 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     305.2     1.216    0.3%
    1     598.4     1.834    0.3%
    2     918.6     13.12    1.4%
    3      1246     9.812    0.7%
    4      1552      16.5    1.0%
    5      1880        16    0.8%
    6      2237     17.44    0.7%
    7      2558     13.19    0.5%
    8      2877     17.69    0.6%
    9      3252     12.25    0.3%
   10      3563     30.49    0.8%
   11      3947     27.44    0.6%
   12      4352     32.29    0.7%
   13      4710     36.46    0.7%
   14      5095     33.35    0.6%
   15      5449     14.91    0.2%
   16      5777     28.45    0.4%
   17      6095     37.14    0.6%
   18      6472     46.34    0.7%
   19      6867     30.97    0.4%
   20      7233      31.3    0.4%

Quality and confidence:
param     error
r         0.729

Model:
Time ~=    175.3
    + r    349.1
              µs

Reads = 4 + (80 * r)
Writes = 1 + (80 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_set_storage_per_new_kb", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Skipped Metadata (r:0 w:0)

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

Model:
Time ~=    651.9
    + n    24.85
              µs

Reads = 85 + (0 * n)
Writes = 83 + (0 * n)

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

Data points distribution:
    n   mean µs  sigma µs       %
    0     604.7     8.097    1.3%
    1     678.7     8.461    1.2%
    2     707.7     7.805    1.1%
    3     730.7     5.559    0.7%
    4     756.9     8.921    1.1%
    5     784.4     9.101    1.1%
    6     813.6     15.51    1.9%
    7       836     11.01    1.3%
    8     852.9     5.654    0.6%
    9       877     8.684    0.9%
   10       901     8.001    0.8%
   11     920.2     9.703    1.0%
   12     948.7     12.74    1.3%
   13       992     12.13    1.2%
   14      1003     11.11    1.1%
   15      1026     10.02    0.9%
   16      1048     12.35    1.1%

Quality and confidence:
param     error
n         0.253

Model:
Time ~=    646.9
    + n    25.63
              µs

Reads = 85 + (0 * n)
Writes = 83 + (0 * n)

Pallet: "pallet_contracts", Extrinsic: "seal_set_storage_per_old_kb", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Skipped Metadata (r:0 w:0)

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

Model:
Time ~=    670.2
    + n    8.137
              µs

Reads = 85 + (0 * n)
Writes = 83 + (0 * n)

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

Data points distribution:
    n   mean µs  sigma µs       %
    0     608.8      11.2    1.8%
    1     677.8     13.03    1.9%
    2     700.6     12.57    1.7%
    3     706.5     12.76    1.8%
    4     707.4     3.727    0.5%
    5     711.9     2.303    0.3%
    6     719.9     1.729    0.2%
    7     734.8      12.4    1.6%
    8     745.4     11.88    1.5%
    9     740.9     8.636    1.1%
   10     744.5     5.791    0.7%
   11     760.3     11.28    1.4%
   12     768.8      11.3    1.4%
   13     769.2      4.53    0.5%
   14     791.2     13.17    1.6%
   15       797     9.938    1.2%
   16       801     6.481    0.8%

Quality and confidence:
param     error
n          0.29

Model:
Time ~=    662.4
    + n    9.009
              µs

Reads = 85 + (0 * n)
Writes = 83 + (0 * n)

Pallet: "pallet_contracts", Extrinsic: "seal_clear_storage", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Skipped Metadata (r:0 w:0)

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

Model:
Time ~=    214.4
    + r    329.7
              µs

Reads = 5 + (80 * r)
Writes = 3 + (80 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     304.6     0.181    0.0%
    1     608.8     7.292    1.1%
    2     918.4     12.52    1.3%
    3      1218     9.728    0.7%
    4      1494     5.307    0.3%
    5      1816     8.776    0.4%
    6      2157     8.436    0.3%
    7      2478     20.74    0.8%
    8      2778     14.99    0.5%
    9      3115     12.89    0.4%
   10      3450     21.36    0.6%
   11      3780      21.6    0.5%
   12      4192     32.17    0.7%
   13      4516     21.66    0.4%
   14      4848     28.66    0.5%
   15      5194     20.05    0.3%
   16      5542     24.24    0.4%
   17      5805      21.4    0.3%
   18      6164     17.56    0.2%
   19      6547     23.26    0.3%
   20      6835     31.07    0.4%

Quality and confidence:
param     error
r         0.596

Model:
Time ~=      209
    + r    330.3
              µs

Reads = 5 + (80 * r)
Writes = 3 + (80 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_clear_storage_per_kb", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Skipped Metadata (r:0 w:0)

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

Model:
Time ~=    656.5
    + n    7.417
              µs

Reads = 85 + (0 * n)
Writes = 83 + (0 * n)

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

Data points distribution:
    n   mean µs  sigma µs       %
    0     611.2     8.158    1.3%
    1     673.4     14.82    2.2%
    2     679.4     8.462    1.2%
    3     691.4     10.39    1.5%
    4     688.5     3.942    0.5%
    5     697.8     0.747    0.1%
    6       703       4.4    0.6%
    7     710.9      2.71    0.3%
    8     711.9     2.051    0.2%
    9     732.3      13.4    1.8%
   10     727.1     4.839    0.6%
   11     732.9     5.581    0.7%
   12       737     3.181    0.4%
   13     746.5     2.636    0.3%
   14     762.5     3.506    0.4%
   15     770.9     7.737    1.0%
   16     792.4     12.13    1.5%

Quality and confidence:
param     error
n         0.235

Model:
Time ~=    651.6
    + n    8.028
              µs

Reads = 85 + (0 * n)
Writes = 83 + (0 * n)

Pallet: "pallet_contracts", Extrinsic: "seal_get_storage", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Skipped Metadata (r:0 w:0)

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

Model:
Time ~=      245
    + r    265.8
              µs

Reads = 4 + (80 * r)
Writes = 1 + (0 * r)

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

Data points distribution:
    r   mean µs  sigma µs       %
    0     307.4     0.175    0.0%
    1       543     7.797    1.4%
    2     791.5     12.87    1.6%
    3      1040     13.25    1.2%
    4      1302     11.03    0.8%
    5      1539     18.14    1.1%
    6      1820     10.53    0.5%
    7      2077     18.33    0.8%
    8      2327     14.82    0.6%
    9      2596     27.55    1.0%
   10      2843      19.5    0.6%
   11      3143     26.77    0.8%
   12      3419     13.68    0.4%
   13      3710     25.12    0.6%
   14      3983     28.32    0.7%
   15      4235      24.7    0.5%
   16      4514     23.74    0.5%
   17      4767     13.77    0.2%
   18      5076     42.66    0.8%
   19      5353     45.48    0.8%
   20      5617     42.17    0.7%

Quality and confidence:
param     error
r         0.469

Model:
Time ~=    232.5
    + r    267.2
              µs

Reads = 4 + (80 * r)
Writes = 1 + (0 * r)

Pallet: "pallet_contracts", Extrinsic: "seal_get_storage_per_kb", Lowest values: [], Highest values: [], Steps: 50, Repeat: 20
Raw Storage Info
========
Storage: Skipped Metadata (r:0 w:0)

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

Model:
Time ~=    608.4
    + n    53.58
              µs

Reads = 84 + (0 * n)
Writes = 1 + (0 * n)

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

Data points distribution:
    n   mean µs  sigma µs       %
    0     543.1     3.678    0.6%
    1     655.5     8.592    1.3%
    2     747.9     17.36    2.3%
    3       773     2.571    0.3%
    4     832.5     10.17    1.2%
    5     888.6     13.36    1.5%
    6     941.3     9.565    1.0%
    7     985.7     11.69    1.1%
    8      1035      10.3    0.9%
    9      1078     8<truncated>...

Copy link
Contributor

@HCastano HCastano left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This reduces the max encoded length of the item from 19MiB to 16KiB.

Nice!

@athei
Copy link
Member Author

athei commented Jun 22, 2022

bot merge

@paritytech-processbot paritytech-processbot bot merged commit 0adc17e into master Jun 22, 2022
@paritytech-processbot paritytech-processbot bot deleted the at/delqueue branch June 22, 2022 15:54
DaviRain-Su pushed a commit to octopus-network/substrate that referenced this pull request Aug 23, 2022
* contracts: Reduce size of deletion queue depth

* Remove unused import
en added a commit to octopus-network/substrate that referenced this pull request Oct 5, 2022
* generate_storage_alias: Rewrite as proc macro attribute (#11387)

* generate_storage_alias: Rewrite as proc macro attribute

This rewrites the `generate_storage_alias!` declarative macro as proc-macro attribute. While doing
this the name is changed to `storage_alias`. The prefix can now also be the name of a pallet. This
makes storage aliases work in migrations for all kind of chains and not just for the ones that use
predefined prefixes.

* Fix compilation and FMT

* Moare fixes

* :facepalm:

* ......

* Rework the syntax and support instancing

* FMT

* Prefix variants with `Storage`

* Make it compile

* Fix where clause on rust stable

* Prune some duplicated dependencies in the dep graph (#11433)

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* contracts: Get rid of `#[pallet::without_storage_info]` (#11414)

* Implement `MaxEncodeLen` for pallet-contracts storage

* Remove redundant debug println

* Move code len check to PrefabWasmModule::from_code

* Return a successful response on repeated small block request (#11429)

* [ci] Adjust job order in pipeline test stage with Gitlab DAG (#11442)

* [Do Not Merge] Test gitlab DAG in pipeline

* add jobs for pipeline cancel

* add check-tracing to cancel-pipeline

* Allow to set the max supply for collection (#11441)

* Allow to set the max supply for collection

* Update error

* Add weights info

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_uniques --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/uniques/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* Update frame/uniques/src/lib.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

Co-authored-by: Parity Bot <admin@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* disable check-dependent-cumulus (#11450)

* trie: Optimize `keys` function (#11457)

* trie: Optimize `keys` function

Instead of iterating the entire state and collecting all keys that match the given prefix, we can
directly use the optimized prefix iterator.

* Add a test

* add GHA support to dependabot (#11448)

* add GHA support to dependabot

* fix formatting

* add labels

* add label

* contracts: Add `set_code` root dispatchable (#11451)

* Add `set_code` dispatchable

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs

Co-authored-by: Parity Bot <admin@parity.io>

* Switch to pooling copy-on-write instantiation strategy for WASM (#11232)

* Switch to pooling copy-on-write instantiation strategy for WASM

* Fix benchmark compilation

* Fix `cargo fmt`

* Fix compilation of another benchmark I've missed

* Cleanups according to review comments

* Move `max_memory_size` to `Semantics`

* Set `memory_guaranteed_dense_image_size` to `max_memory_size`

* Rename `wasm_instantiation_strategy` to `wasmtime_instantiation_strategy`

* Update the doc-comments regarding the instantiation strategy

* Extend the integration tests to test every instantiation strategy

* Don't drop the temporary directory until the runtime is dropped in benchmarks

* Don't drop the temporary directory until the runtime is dropped in tests

* Make fields of `EraRewardPoints` public (#11422)

* add missing events to elections fallback (#11436)

* add missing events to elections fallback

* Update frame/election-provider-multi-phase/src/lib.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Update frame/election-provider-multi-phase/src/lib.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* add test

* fix

* fmt

* Update frame/support/src/storage/types/nmap.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Fix renaming artifacts (#11455)

* Add Score to Bags List (#11357)

* Add Score to Bags List

* fix ordering

* make compile

* in progress migration

* make migration compile

* remove old check

* remove runtime specific migration

* fix warning

* Apply suggestions from code review

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* improve migration

* fix

* fix merge

* fmt

* Update migrations.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Stabilize ecdsa_ functions (#11486)

* Bump actions/checkout from 2 to 3 (#11463)

Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump gaurav-nelson/github-action-markdown-link-check from 1.0.9 to 1.0.14 (#11464)

* Bump gaurav-nelson/github-action-markdown-link-check

Bumps [gaurav-nelson/github-action-markdown-link-check](https://github.com/gaurav-nelson/github-action-markdown-link-check) from 1.0.9 to 1.0.14.
- [Release notes](https://github.com/gaurav-nelson/github-action-markdown-link-check/releases)
- [Commits](https://github.com/gaurav-nelson/github-action-markdown-link-check/compare/7481451f70251762f149d69596e3e276ebf2b236...58f84fd654812d0d8da4e4d4a559eda087daf8ce)

---
updated-dependencies:
- dependency-name: gaurav-nelson/github-action-markdown-link-check
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update .github/workflows/md-link-check.yml

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Denis Pisarev <denis.pisarev@parity.io>

* RPC: Mark storage methods as `blocking`  (#11459)

* client/api: Make `storage_keys` blocking

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* client/api: Ensure `state_*` RPC methods are blocking

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* client/rpc: Ensure `childstate_*` RPC methods are blocking

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* client/rpc: `ChainApi` make RPC methods sync

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Remove unused async-traits

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* client/rpc-api: Make chain RPC methods blocking

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Update client/rpc/src/state/state_full.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Add `blocking` to `state_getKeysPaged` RPC call

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Fix build and warning

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Remove `async_trait` tidyup

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* InMemoryBackend: Make it generic over the key hasher (#11488)

* InMemoryBackend: Make it generic over the key hasher

* Update primitives/state-machine/src/in_memory_backend.rs

Co-authored-by: cheme <emericchevalier.pro@gmail.com>

* Update primitives/state-machine/src/in_memory_backend.rs

Co-authored-by: cheme <emericchevalier.pro@gmail.com>

* FMT

Co-authored-by: cheme <emericchevalier.pro@gmail.com>

* Unify rpc api and implementation name (#11469)

* Unify rpc api and implementation name

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* MauanlSeal ==> ManualSealRpc

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Remove extra Rpc naming in the structs

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Update doc

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* fix merge

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>

* rpc servers CLI: add `--max--subscriptions--per--connection` + fix a few bugs (#11461)

* cli: fix RPC CLI nits

* remove needless lines

* cargo fmt

* Update client/service/src/lib.rs

Co-authored-by: James Wilson <james@jsdw.me>

Co-authored-by: James Wilson <james@jsdw.me>

* Make `--dev` listen by default on `/ip4/0.0.0.0/tcp/30333` (#11492)

If `--validator` is passed we also listen on this address and as `--dev` is a shortcut for multiple
CLI args, including `--validator`, we should make it consistent.

* Fix State Trie Migration Benchmarks (#11502)

* enable signed migrations in benchmarks

* T instead of Test

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove 'mut'

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Use API for pr-custom-review (#11487)

* use API for pr-custom-review

* bump action tag

* temporary: disable draft skip

* temporary: use staging

* try it with the prod instance

* revert draft skip

* Introduce #[pallet::call_index] attribute to dispatchables (#11381)

* Introduce #[pallet::call_index] attribute to dispatchables

* cargo fmt

* Add more docs and prevent duplicates of call indices

* Add UI test for conflicting call indices

* cargo fmt

Co-authored-by: parity-processbot <>

* Create Script to Run All Benchmarks (#11493)

* Create run_all_benchmarks.sh

* Update run_all_benchmarks.sh

* Update run_all_benchmarks.sh

* Review fixes

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update scripts/run_all_benchmarks.sh

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* typo

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* add default for $1

* Typo

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update run_all_benchmarks.sh

* new weights on benchmarking machine

* prefer `--chain=dev`

* fix compile

* fix command

* fmt

* dont use square brackets

* Extend doc

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove +nightly

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Add error file an run execute everything optimistically

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Adjust maximum memory pages hard limit for the pooling instantiation strategy (#11482)

* Run `sc-executor-wasmtime` unit tests for all instantiation strategies

* Adjust maximum memory pages hard limit for the pooling instantiation strategy

* Optimize offchain worker memory usage a bit.  (#11454)

* add missing events to elections fallback

* Merged

* add some logs and stuff

* undo a bunch of things

* undo lock file

* remove unused err

* fix build

* add rule to the ci job (#11511)

* Contracts pallet: removal on idle (#11202)

* on_initialize -> on_idle

* use remaining_weight info

* no weight_limit for on_idle

* call on_idle in tests

* attempt to fix tests

* run on_initiaize when queue full

* add on_idle to weight info

* add on_idle weight info to on_idle hook

* add basic test for on_initialize with full queue

* disbale check for all keys gone in full queue, full block test

* queue_deth as usize, add comment

* comment was removed by accident

* Update frame/contracts/src/lib.rs

Co-authored-by: Alexander Theißen <alex.theissen@me.com>

* cargo +nightly fmt

* update lazy_removal_does_no_run_on_full_queue_and_full_block

* remove changes in weights.rs

* weights on_idle -> on_process_deletion_queue_batch

* use block number for on_idle

* use BlockNumber for on_initialize

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* Update frame/contracts/src/lib.rs

Co-authored-by: Alexander Theißen <alex.theissen@me.com>

* remove outcommented code

* add check that queue still full for test

* cargo fmt

* cargo +nightly fmt

* Update frame/contracts/src/benchmarking/mod.rs

Co-authored-by: Alexander Gryaznov <hi@agryaznov.com>

* fix weights.rs

* add lazy_removal_does_no_run_on_low_remaining_weight test

* Apply suggestions from code review

Co-authored-by: Alexander Gryaznov <hi@agryaznov.com>

Co-authored-by: Alexander Theißen <alex.theissen@me.com>
Co-authored-by: Parity Bot <admin@parity.io>
Co-authored-by: Alexander Gryaznov <hi@agryaznov.com>

* Fix Babe revert when last finalized block is a leaf (#11500)

* Fix Babe revert when a leaf is the last finalized block

Without this fix the last finalized block weight data is wrongly removed
on revert scenario where the last finalized block is a leaf.

* Remove redundant check

* Added test to exercise the fix

* Rename test

* Give variables better names

* Document benchmarking CLI (#11246)

* Decrese default repeats

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Add benchmarking READMEs

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update docs

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update docs

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update README

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Review fixes

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>

Co-authored-by: parity-processbot <>
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>

* Introduce `WeightToFee` trait instead of `WeightToFeePolynomial` and make `WeightToFeePolynomial` implement it instead (#11415)

* Introduce `WeightToFee` trait instead of `WeightToFeePolynomial` and make `WeightToFeePolynomial` implement it instead

* Rename `WeightToFee::calc()` to `WeightToFee::wight_to_fee()`

* Fix typo

* Fix node lookup on fork-tree after a warp-sync (#11476)

* Fix node lookup on fork-tree after a warp-sync

After a warp-sync, the error condition was triggered by the absence
of the parent node of the first imported block.

The previous lookup implementation was traversing the tree using a
recursive **post-order** DFS, this technique doesn't trigger the issue.

In the last iterative implementation we were using a BFS instead.

* Added internal doc warning

* Small optimization

* Specify post-order DFS in the comment

* Test for the fork-tree post-order DFS traversal requirement (#11521)

* Test for the fork-tree post-order DFS traversal requirement

* Fixed typo

* Storage Layer for All FRAME Extrinsics (#11431)

* add new trait

* implement DispatchableWithStorageLayer

* at least one transactional

* all dispatch is at least transactional

* storage_layer api

* add test

* storage layer tests

* deprecate transactional tag

* i guess no reason to deprecate

* remove transactional from batch_all

* update tests

* extend trait

* cargo run --quiet --profile=production --features runtime-benchmarks --manifest-path bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* cargo run --quiet --profile=production --features runtime-benchmarks --manifest-path bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* cargo run --quiet --profile=production --features runtime-benchmarks --manifest-path bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* fix copy paste name

* cargo run --quiet --profile=production --features runtime-benchmarks --manifest-path bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_utility --extrinsic=* --execution=wasm --wasm-execution=compiled --output=./frame/utility/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* Create run_all_benchmarks.sh

* uncomment build

* update number of steps and repeats

* add skip build

* Update run_all_benchmarks.sh

* Update run_all_benchmarks.sh

* new benchmarks

* Update frame/support/src/traits/dispatch.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Update frame/support/src/traits/dispatch.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Update frame/support/test/tests/storage_layers.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Update frame/support/test/tests/storage_layers.rs

* weights

* Update dispatch.rs

* doc link

* decl_macro support

Co-authored-by: Parity Bot <admin@parity.io>
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* CI: github no longer checks whitelisted actions this way (#11507)

* CI: github no longer checks whitelisted actions this way

* CI: actually this one is needed and no one knows it's related to a Markdown Link Check

* Fork-Tree import requires post-order DFS traversal (#11531)

* Fork-tree insert requires post-order dfs traversal

* Add dedicated test for methods requireing post-order traversal

* Fixed pruning docs (#11519)

* fix broken links (#11536)

* Safe and sane multi-item storage removal (#11490)

* Fix overlay prefix removal result

* Second part of the overlay prefix removal fix.

* Report only items deleted from storage in clear_prefix

* Fix kill_prefix

* Formatting

* Remove unused code

* Fixes

* Fixes

* Introduce clear_prefix host function v3

* Formatting

* Use v2 for now

* Fixes

* Formatting

* Docs

* Child prefix removal should also hide v3 for now

* Fixes

* Fixes

* Formatting

* Fixes

* apply_to_keys_whle takes start_at

* apply_to_keys_whle takes start_at

* apply_to_keys_whle takes start_at

* Cursor API; force limits

* Use unsafe deprecated functions

* Formatting

* Fixes

* Grumbles

* Fixes

* Docs

* Some nitpicks :see_no_evil:

* Update primitives/externalities/src/lib.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Formatting

* Fixes

* cargo fmt

* Fixes

* Update primitives/io/src/lib.rs

Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>

* Formatting

* Fixes

Co-authored-by: Bastian Köcher <info@kchr.de>
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>

* Use `loops` rather than `backend` for compatibility. (#11542)

* Use `loops` rather than `backend` for compatibility.

* Move over other converters

* sp-core: impl serde for some offchain types (#11512)

* sp-core: impl serde for some offchain types

* Update primitives/core/src/offchain/mod.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* remove serde impls from OpaqueNetworkState/OpaqueMultiaddr

* derive default

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Several tweaks needed for Governance 2.0 (#11124)

* Add stepped curve for referenda

* Treasury SpendOrigin

* Add tests

* Better Origin Or-gating

* Reciprocal curve

* Tests for reciprical and rounding in PerThings

* Tweaks and new quad curve

* Const derivation of reciprocal curve parameters

* Remove some unneeded code

* Actually useful linear curve

* Fixes

* Provisional curves

* Rejig 'turnout' as 'support'

* Use TypedGet

* Fixes

* Enable curve's ceil to be configured

* Formatting

* Fixes

* Fixes

* Fixes

* Remove EnsureOneOf

* Fixes

* Fixes

* Fixes

* Formatting

* Fixes

* Update frame/support/src/traits/dispatch.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Grumbles

* Formatting

* Fixes

* APIs of VoteTally should include class

* Fixes

* Fix overlay prefix removal result

* Second part of the overlay prefix removal fix.

* Formatting

* Fixes

* Add some tests and make clear rounding algo

* Fixes

* Formatting

* Revert questionable fix

* Introduce test for kill_prefix

* Fixes

* Formatting

* Fixes

* Fix possible overflow

* Docs

* Add benchmark test

* Formatting

* Update frame/referenda/src/types.rs

Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>

* Docs

* Fixes

* Use latest API in tests

* Formatting

* Whitespace

* Use latest API in tests

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>

* change impl FnOnce() to generic type + trait bound (#11534)

* change impl FnOnce() to generic type + trait bound

with_transaction() function can not be used with explicit generic arguments because of this issue: https://github.com/rust-lang/rust/issues/83701

* make the same changes elsewhere

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>

* Introduce `rusty-cachier` (#11462)

* Introduce `rusty-cachier`

* Return LF at the end of file

* Use `entrypoint` to `unshare(1)` into a new mount namespace

* Use `rusty-cachier`-provided absolute path for `CARGO_TARGET_DIR` everywhere

* Debug single `build-rustdoc` job

* CI: debug

* CI: debug

* CI: debug

* `unshare(1)` is no longer needed

* CI: remove debug

* Revert "Debug single `build-rustdoc` job"

* Formatiing

* Update scripts/ci/gitlab/pipeline/build.yml

Co-authored-by: Denis Pisarev <denis.pisarev@parity.io>

* Clean up `#[transactional]` (#11546)

* Deprecate #[transactional] attribute

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove #[transactional] from nomination pools

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Review fix

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Fix NOOP test

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Suppress warnings

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Add `rusty-cachier notify` job (#11554)

* Add `rusty-cachier notify` job

* Add comments

* Fix CI after `rusty-cachier` introduction (#11556)

* Fix CI after `rusty-cachier` introduction

* Replace anchor with `extends`

* Introduce `EnsureOrigin::try_successul_origin` (#11558)

* Introduce `EnsureOrigin::try_successul_origin`

* Formatting

* Fixes

* Add Morph

* Fixes

* Formatting

* Sync: Improve major sync detection (#11547)

* Sync: Improve major sync detection

When we still have a full import queue, we should still report that we are in major sync mode,
otherwise validators may will already start producing blocks.

* Use median

* Review comments

* Fix clippy on master (#11559)

* Fix link in node-template README (#11529)

The lorri repository has moved from https://github.com/target/lorri to
https://github.com/nix-community/lorri.

* Fix minor typos (#11550)

* Fix minor typos

* FMT

Co-authored-by: Bastian Köcher <info@kchr.de>

* Short circuit Treasury::Spend benchmark for NeverEnsureOrigin (#11562)

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

Co-authored-by: parity-processbot <>

* Do not require Ord for pallet_offences::Config::IdentificationTuple (#11563)

* Ranked Collective pallet (#11548)

* Ranked Collective pallet

* Fixes

* benchmarks

* Weights

* Allow class voting in rank
Use bare ayes for calculating support.
Allow only promotion/demotion by one rank only.
Allow removal of member with rank zero only.
Use new Tally API

* Index by rank, still O(1).

* Custom vote weights

* Formatting

* Update frame/ranked-collective/src/lib.rs

* Broken :(

* origin guard; cleanup uses new API

* Formatting

* Promote/demote by rank

* Formatting

* Use new API

* Remove code in another PR

* Remove code in another PR

* Formatting

* Remove code in another PR

* Docs

* Docs

* Bump

* Fixes

* Formatting

* Fixes

* Introduce set function into storage maps (#11564)

* Introduce `SubmitOrigin` to Referenda pallet config (#11567)

* Don't limit `test-linux-stable-int` job output (#11560)

* Fix all warnings when building for wasm (#11569)

* Fix all warnings when building for wasm

Besides that it also enables warnings as errors for wasm builds in the CI.

* FMT

* Make clippy happy

* Helper macro for `Morph` impls (#11570)

* Helper macro for Morph impls

* No need to deprecate for now

* Improved macro

* Doc tests

* Grumbles

* `rusty-cachier` pipeline impovements and fixes (#11572)

* CI: fix `build-subkey-macos` build job (#11573)

* CI: fix `build-subkey-macos` build job

* CI: use full path for the `CARGO_TARGET_DIR` default value

* aura: export change_authorities and initialize_authorities (#11468)

* aura: export change_authorities and initialize_authorities

* add docs

* fix docs

* Reduce call size of Referenda pallet (#11578)

* Reduce call size of Referenda pallet

* Fixes

* Fixes

* Fixes

* Docs

* reactivate check-dependent-cumulus (#11506)

* re-enable check-dependent-cumulus

* temporary: use handle-extra-dependencies

* temporary: trim CI

* CI: include build stage

* CI: include test stage

* CI: include test stage

* Revert "temporary: trim CI"

This reverts commit dcf4ae8d842bc445a065c7ccdc3b6a603034faa4.

* CI: fix weird revert

* Revert "temporary: use handle-extra-dependencies"

This reverts commit bc0dc0f21f10284a23f66fdd8509ca6df89f2586.

* CI undebug

Co-authored-by: TriplEight <denis.pisarev@parity.io>

* wasm-builder: Rerun the build if the generated file changed (#11582)

* [ci] use cargo nextest instead cargo test in test-linux-stable (#11576)

* [DO NOT MERGE] Experimenting with nextest

* enable jobs

* enable stages

* add comment

* create test-frame-support job

* Expose ValidatedTransaction from transaction pool (#11588)

This is required to make a tx pool wrapper for some custom transaction validation, specificially
required to make a wrapper around the `LocalTransactionPool` implementation (https://github.com/subspace/subspace/blob/f54881a9b5/crates/subspace-service/src/pool.rs#L232-L269).

Related: https://github.com/paritytech/substrate/discussions/11520

* Tracable defensive errors (#11532)

* Tracable defensive errors

* small fixes

* fix

* refactored

* switched to defensive_ok_or

* Remove unnecessary type annotations and conversions

* cargo fmt

* Fixes

Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>

* Remove `#[pallet::without_storage_info]` for pallet-remark (#11590)

* Add host info to weight templates (#11583)

* Add host info to weight templates

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=frame_system --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/system/src/weights.rs --template=./.maintain/frame-weight-template.hbs

Co-authored-by: Parity Bot <admin@parity.io>

* Expose Benchmarking Component Ranges (#11545)

* Add component ranges to benchmarking

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Adding component ranges to templates

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix tests

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=frame_system --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/system/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* tweak script to reduce diff

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_identity --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/identity/src/weights.rs --template=./.maintain/frame-weight-template.hbs

Co-authored-by: Parity Bot <admin@parity.io>
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>

* make era public (#11575)

* MEL for Ranked Collective (#11602)

* Fix one-by-off in `BoundedSlice::try_from` (#11600)

* Remove a max supply record on collection's destruction (#11593)

* Remove a max supply record on collection's destruction

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_utility --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/utility/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_uniques --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/uniques/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_uniques --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/uniques/src/weights.rs --template=./.maintain/frame-weight-template.hbs

Co-authored-by: Parity Bot <admin@parity.io>

* Implement more IntoIter traits for bounded types (#11616)

* Remove `without_storage_info` for membership pallet (#11591)

* Improve docs on `--keep-blocks` CLI parameter and related data structures (#11611)

* Improve docs on `--keep-blocks` CLI parameter and related data structures

* Update client/db/src/lib.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Improve inspection and generation of node keys (#11525)

* Improve inspection and generation of node keys

* Lock stdout before write

* Fix typo

* Fix offset

* Remove useless code

* Set inspect-node-key 'network' option as obsolete

* Better transaction pool error (#11629)

* Better transaction pool error

* Do not use `Debug` when printing errors

* Use BoundedVec in aura pallet (#11617)

* Use BoundedVec in aura pallet

* cargo fmt

* pallet alliance (#11112)

* Add pallet-alliance

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Update multihash/cid and format

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Remove useless deps

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Add pallet-alliance into node runtime

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Fix has_identity

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Add TooMantBlacklist Error

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Add TooLongWebsiteUrlLength Error

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Add remove_announcement

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Derive pallet_identity::Config and Fix test/benchmarking

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Add part weight for call of pallet-alliance

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Remove pallet_identity Config trait

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Fix propose arguments

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Some nits

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* cargo fmt

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Fix benchmarking of add_blacklist/remove_blacklist

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Some nits

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Add benchmarking for init_members

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Add benchmarking for propose/vote/veto

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Fix benchmarking

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Remove some useless

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* fix some compile issue

* more fix

* all checks

* refactor

* refactor event

* refactor

* cleanup

* cleanup

* fix benchmarking

* fix warning

* fmt

* fix benchmarks

* with storage info

* fmt

* add new config

* fix benchmarks

* fix

* fmt

* Apply suggestions from code review

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* improvements

* fix

* update docs

* rename events, errors, and functions

* make kicking events clearer

* fix

* fix tests

* fix tests

* fix runtime

* fix build

* remove unneeded change

* remove Candidate role from Alliance

* fmt grumbles

* update lock

* update recursion limit

* benchmarks

* convert-try

* benchmark assertions

* fmt ,

* cargo lock

* Update frame/alliance/src/benchmarking.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* add docs to public interfaces

* Apply suggestions from code review

Co-authored-by: Squirrel <gilescope@gmail.com>

* fix build (node)

* review

* use EitherOfDiverse

* update cargo toml

* make all dispatch class Normal

* change blacklist to unscrupulous

* formatting

* fmt oops

* rename benchmarking unscrupulous account creator

Co-authored-by: koushiro <koushiro.cqx@gmail.com>
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
Co-authored-by: joepetrowski <joe@parity.io>
Co-authored-by: joe petrowski <25483142+joepetrowski@users.noreply.github.com>
Co-authored-by: Squirrel <gilescope@gmail.com>

* Add fixed u64 (#11555)

Co-authored-by: parity-processbot <>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove storage `MaxValues` limits (#11643)

* Remove limits

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove more

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Added an event for cancel_proposal (#11620)

* Added an event for cancel_proposal

* test

* pallet-grandpa: Improve/Clarify docs of `note_stalled` (#11623)

* Bump crossbeam-utils from 0.8.5 to 0.8.8 (#11605)

Bumps [crossbeam-utils](https://github.com/crossbeam-rs/crossbeam) from 0.8.5 to 0.8.8.
- [Release notes](https://github.com/crossbeam-rs/crossbeam/releases)
- [Changelog](https://github.com/crossbeam-rs/crossbeam/blob/master/CHANGELOG.md)
- [Commits](https://github.com/crossbeam-rs/crossbeam/compare/crossbeam-utils-0.8.5...crossbeam-utils-0.8.8)

---
updated-dependencies:
- dependency-name: crossbeam-utils
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* fix pallet_uniques docs link (#11651)

* MEL bound `state-trie-migration` (#11639)

* MEL bound state-trie-migration

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* wip

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Add tests

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Use sp_std

Co-authored-by: cheme <emericchevalier.pro@gmail.com>

* Add doc

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Set MaxKeyLen default to 512

Just to be sure that it will work. There is also no real penalty
from over-estimating it.

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Add more doc

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Clippy

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* fmt

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix assert_err_with_weight macro

Looks like I'm the only one using it anyway...

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix tests that use env macro

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix test

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

Co-authored-by: cheme <emericchevalier.pro@gmail.com>

* Move bounded type definitions to sp-runtime (#11645)

* Move bounded type definitions to sp-runtime

* cargo fmt

* Fix compile error

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Move TryCollect to sp-runtime

* Write some docs

* Import missing types

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Implement MaxEncodedLen on pallet-beefy (#11584)

* Implement MaxEncodedLen on pallet-beefy

* Return Result in intialize_authorities

* Update docs

* Log error when authorities list gets truncated

* Update frame/beefy/src/lib.rs

Co-authored-by: Adrian Catangiu <adrian@parity.io>

* cargo fmt

Co-authored-by: Adrian Catangiu <adrian@parity.io>

* Implement PartialOrd and Ord on BoundedSlice and WeakBoundedVec (#11655)

* Implement PartialOrd and Ord on BoundedSlice and WeakBoundedVec

* More implementations of PartialEq and PartialOrd

* cargo fmt

* Fixes

* Allow nomination pools to chill + fix dismantle scenario (#11426)

* make pool roles optional

* undo lock file changes?

* add migration

* add the ability for pools to chill themselves

* boilerplate of tests

* somewhat stable, but I think I found another bug as well

* Fix it all

* Add more more sophisticated test + capture one more bug.

* Update frame/staking/src/lib.rs

* reduce the diff a little bit

* add some test for the slashing bug

* cleanup

* fix lock file?

* Fix

* fmt

* Update frame/nomination-pools/src/lib.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update frame/nomination-pools/src/lib.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update frame/nomination-pools/src/lib.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update frame/nomination-pools/src/mock.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix build

* fix some fishy tests..

* add one last integrity check for MinCreateBond

* remove bad assertion -- needs to be dealt with later

* nits

* fix tests and add benchmarks for chill

* remove stuff

* fix benchmarks

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_nomination_pools --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/nomination-pools/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* remove defensive

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
Co-authored-by: Parity Bot <admin@parity.io>

* Properly implement Debug on bounded types (#11659)

* remove flaky rpc subscription tests (#11653)

* Add `TypeInfo` (#11599)

* wasm-builder: Fix constant re-running of `build.rs` scripts. (#11624)

Recently we added the wasm binaries to the `rerun-if-changed` list. The problem with that is that
they have a later mtime than the `invoked.timestamp` file and this file's mtime is used to determine
if the `build.rs` script needs to be re-run. The solution to this is that we copy the mtime of this
`invoked.timestamp` file and add it to the wasm binaries. Then cargo/rustc doesn't constantly wants
to rerun the `build.rs` script.

* Increment subkey version to 2.0.2 (#11656)

* Increment subkey version to 2.0.2

* Update Cargo.lock

Co-authored-by: Davide Galassi <davxy@datawok.net>

* Implement `Deref` for `BoundedSlice` (#11660)

* Impl Deref for BoundedSlice

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update primitives/runtime/src/bounded/bounded_vec.rs

Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>

* grandpa: fix creation of justification with equivocating precommits in commit (#11302)

* grandpa: fix creation of justification ancestry

we would reject commits that have precommits targeting blocks lower than the
commit target. when there is an equivocation (or if it the commit is not
minimal) it is possible to have such precommits and we should assume that they
are the round base.

* grandpa: bump to 0.16.0

* grandpa: add test for justification with equivocation

* grandpa: fix failing test

* Make it possible to disable RocksDB completely (#11537)

* Make it possible to disable RocksDB completely

* Make ParityDB non-optional

* Address review comments

* rpc servers: update jsonrpsee to fix host filtering + WS server-side pings  (#11661)

* bump jsonrpsee to fix #11480

In addition it adds WebSocket server-side pings which is configured to
send out pings periodically every 30 seconds.

* use released crates.io version

* Update Cargo.toml

* Include the chain specs instead of trying to open them by path (#11625)

This makes it possible to run the tests manually, without them expecting to be run in a special
folder etc.

* Remove `without_storage_info` from pallet `transaction-storage` (#11668)

* Introduce BoundedVec

* Fix typos

* Add comments to the bounds

* Remove migration

* Improve bound value access syntax

* combine iteratons and tolerance in sp-npos-elections API (#11498)

* Initial implementation of mms

* Some more attempts at `mms`

* Functioning `MMS` algorithm implementation.
Adding some tests too

* More tests and typos fixed.

* Adding fuzzer for `mms`
(but could not test it on Mac M1)

* Missing imports

* Fixing rustdoc

* More accurate implementation of `mms`

* Removing the fuzzer `mms` implementation

* Implementing `NposSolver` for `MMS`
had to add the `Clone` trait, maybe I could see if I can get rid of it.

* Fixing rust docs by adding () to resolve ambiguity

* Amending `unwrap` to `expect`
removing unneeded `Clone` trait

* Removing redundant `mms3.rs`

* Implementing `BalancingConfig` and rustdoc changes

* Implementing `weight` for `MMS`

* Implementing `weight` for `MMS`

* Fixing post merge

* Initial implementation of mms

* Some more attempts at `mms`

* Functioning `MMS` algorithm implementation.
Adding some tests too

* More tests and typos fixed.

* Adding fuzzer for `mms`
(but could not test it on Mac M1)

* Missing imports

* Fixing rustdoc

* More accurate implementation of `mms`

* Removing the fuzzer `mms` implementation

* Implementing `NposSolver` for `MMS`
had to add the `Clone` trait, maybe I could see if I can get rid of it.

* Amending `unwrap` to `expect`
removing unneeded `Clone` trait

* Fixing rust docs by adding () to resolve ambiguity

* Removing redundant `mms3.rs`

* Implementing `BalancingConfig` and rustdoc changes

* Implementing `weight` for `MMS`

* Implementing `weight` for `MMS`

* Fixing post merge

* Removing left over from rebase

* Fixing tests

* Removing unneeded import

* Removing unneeded functions

* Removing useless imports

Co-authored-by: kianenigma <kian@parity.io>

* Add Event to Pallet Transaction Payment (#11618)

* add Event to Pallet Transaction Payment

* Fix tests in Pallet Balance

* Fix tests in Pallet Balance/Executive/Asset-tx-payment.

* Fix

* fmt

* Fix

* Fix

* Update Cargo.lock

* Fix tests in executor

* Update frame/transaction-payment/src/lib.rs

Co-authored-by: joe petrowski <25483142+joepetrowski@users.noreply.github.com>

* update the name of the event and fmt.

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
Co-authored-by: joe petrowski <25483142+joepetrowski@users.noreply.github.com>

* Remove `without_storage_info` for the authorship pallet (#11610)

* Remove `without_storage_info` for the authorship pallet

* Tweak impl bounds style

* Use `defensive_proof` instead of `expect`

* MEL: Origin, Referenda, ConvictionVoting (#11631)

* Referenda & CV pallets ready

* Fix build

* Add mel_bound for Voting and Casting types

* Add mel_bound on Tally

* Add mel_bound on another Tally

* Add mel_bound for pallet_collective::RawOrigin

Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>

* Remove multiply_by_rational  (#11598)

* Removed multiply_by_rational
Replaced with multiply_by_rational_with_rounding

* fixes

* Test Fixes

* nightly fmt

* Test Fix

* Fixed fuzzer.

* Upgrade to libp2p 0.45.1 (#11682)

* Upgrade to libp2p 0.45.1

* Limit max_negotiating_inbound_streams to 512

* Upgrade prost-build to 0.10

* Set max_negotiating_inbound_streams to 2048

Co-authored-by: Pierre Krieger <pierre.krieger1708@gmail.com>

* Fix authority discovery protobuf

* Fix comments in authority-discovery schema

Co-authored-by: Pierre Krieger <pierre.krieger1708@gmail.com>

* Add a comment about transport initialization

Co-authored-by: Pierre Krieger <pierre.krieger1708@gmail.com>

* chore: reducing codec times (#11688)

* chore: reduce uxt encode times (#11698)

* chore: reduce uxt encode times

* fmt

* Simplified code using existing APIs (#11702)

Signed-off-by: Emison Lu <lzh1633856298@gmail.com>

* `storage-alias`: Check that prefix is not an underscore (#11704)

Besides that it also adds some UI tests.

* Bump twox-hash from 1.6.2 to 1.6.3 (#11423)

Bumps [twox-hash](https://github.com/shepmaster/twox-hash) from 1.6.2 to 1.6.3.
- [Release notes](https://github.com/shepmaster/twox-hash/releases)
- [Commits](https://github.com/shepmaster/twox-hash/compare/v1.6.2...v1.6.3)

---
updated-dependencies:
- dependency-name: twox-hash
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Update syn and fix compilation (#11707)

* Update syn and fix compilation

* Bump pin-project

* check-dependent-cumulus should only be executed for PRs (#11693)

the script executed by check-dependent-cumulus only works for PRs, as shown in https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/1630771#L87, which comes from https://github.com/paritytech/pipeline-scripts/blob/3ad10ddc0d985ef5326974a1143229c6429befab/check_dependent_project.sh#L443

* Pump the gossip engine while waiting for the BEEFY runtime pallet (memory leak fix) (#11694)

* Pump the gossip engine while waiting for the BEEFY runtime pallet

This fixes a memory leak when the BEEFY gadget is turned on, but
the runtime doesn't actually use BEEFY.

* Implement `FusedFuture` for `GossipEngine`

* Fuse futures outside of loops

* Implement Serialize/Deserialize on WeakBoundedVec (#11713)

* Implement Serialize/Deserialize on WeakBoundedVec

* cargo fmt

* Warn when there are too many elements while deserializing WeakBoundedVec

* More robust grandpa revert procedure (#11719)

* More robust revert procedure

Return an error if revert is called in a node that is not actively
running grandpa, i.e. grandpa genesis data has not been initialized.
Previous implementation was just firing an `unreachable!` code exception.

Furthermore we skip revert hassle if there is nothing to revert.

* Nit

* Fix typo in weights.rs (#11724)

overriden -> overridden

* WrapperOpaque: Use `decode_all` to decode from the `Vec<u8>` (#11726)

This ensures that there isn't any extra data attached that isn't used.

* Respect cargo offline env variable in wasm builder (#11735)

* Support offline env variable in wasm builder

* Clean up

* Improve checks

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Update crate docs

* Add docs to `lib.rs` and introduce helper method `offline_build`

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* contracts: Reduce size of deletion queue depth (#11696)

* contracts: Reduce size of deletion queue depth

* Remove unused import

* Put `rusty-cachier` before PR merge into `master` for `cargo-check-benches` job (#11737)

* epochs: don't use gap when there's at least one genesis epoch imported (#11725)

* epochs: don't use gap when there's at least one genesis epoch imported

* epochs: add test for genesis gap fix

* pallet-beefy-mmr: add API for BEEFY Authority Sets (#11406)

* pallet-beefy: add Config::OnNewValidatorSet type

Add a hook to pallet-beefy for doing specific work when
BEEFY validator set changes.

For example, this can be used by pallet-beefy-mmr to cache
a lightweight MMR root over validators and make it available
to light clients.

* pallet-beefy-mmr: implement OnNewValidatorSet

Implement pallet-beefy::OnNewValidatorSet to be notified of BEEFY
validator set changes. Use the notifications to compute and cache
a light weight 'BEEFY authority set' which is an MMR root over
BEEFY validator set plus some extra info.

Previously, pallet-beefy-mmr was interogating pallet-beefy about
validator set id on every block to find out when it needs to recompute
the authority set.
By using the event-driven approach in this commit, we also save one
extra state interogation per block.

* pallet-beefy-mmr: add new authority_set() API

Expose current and next BEEFY authority sets through runtime API.
These can be directly used by light clients to avoid having them
compute them themselves based on BEEFY validator sets.

Signed-off-by: acatangiu <adrian@parity.io>

* rename BeefyMmr exposed runtime api

* make pallet-tips & pallet-bounties instantiable (#11473)

* make pallet-tips & pallet-bounties instantiable

* update test

* add default instance

* update

* cargo fmt

* update

* update

* update

* update

* fix merge

* fix tests

* bounties benchmarking instantiable

* fix benchmarks

* make tips benchmarks instantible

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>

* [contracts] Implement transparent hashing for contract storage (#11501)

* save

* builds and old tests pass

save:  temporary value dropped while borrowed

save: finally builds

test updated but still fails

* type names enhanced

* VarSizedKey bounded to new Config param

* improved wasm runtime updated funcs

* unstable-interface tests fixed

* benchmarks fixed

* Apply suggestions from code review

Co-authored-by: Alexander Theißen <alex.theissen@me.com>

* fixes on feedback

* fixes on feedback applied + make it build

* benchmarks build but fail (old)

* "Original code too large"

* seal_clear_storage bench fixed (code size workaround hack removal tbd)

* bench_seal_clear_storage pass

* bench_seal_take_storage ... ok

* added new seal_set_storage + updated benchmarks

* added new seal_get_storage + updated benchmarks

* added new seal_contains_storage + updated benchmarks

* added tests for _transparent exec functions

* wasm test for clear_storage

* wasm test for take_storage

* wasm test for new set_storage

* wasm test for new get_storage

* wasm test for new contains_storage

* CI fix

* ci fix

* ci fix

* ci fix

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* fixes according to the review feedback

* tests & benchmarks fixed

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* refactoring

* fix to runtime api

* ci fix

* ctx.get_storage() factored out

* ctx.contains_storage() factored out

* number of batches reduced for transparent hashing storage benchmarks

* contracts RPC & pallet::get_storage to use transparent hashing

* node and rpc updated to use get_storage with VarSizedKey

* refactored (more concize)

* refactored contains_storage (DRYed)

* refactored contains_storage (DRYed)

* fix rpc

* fmt fix

* more fixes in rpc

* rollback `Pallet:get_storage` to Vec<u8> and rpc and node parts related to it

* added `KeyDecodingFailed` error

* Revert weird "fmt fix"

This reverts commit c582cfff4b5cb2c9929fd5e3b45519bb24aeb657.

* node-executor basic test update

* fix node-executor basic test

* benchmarks fix

* more benchmarks fix

* FixedSizedKey is hidden from pub, VarSizedKey is exported as StorageKey

* ci fix

* set_storage benchmark fix

* ci fix

* ci fix

* comments improved

* new error code to rpc: KEY_DECODING_FAILED

* Put `rusty-cachier` before PR merge into `master` for `cargo-check-benches` job

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* minor optimization

Co-authored-by: Alexander Theißen <alex.theissen@me.com>
Co-authored-by: Parity Bot <admin@parity.io>
Co-authored-by: Vladimir Istyufeev <vladimir@parity.io>
Co-authored-by: command-bot <>

* Explain why `rusty-cachier` is put first (#11740)

* Bump `wasmtime` to 0.38.0 and `zstd` to 0.11.2 (#11720)

* Bump `wasmtime` to 0.37.0 and `zstd` to 0.11.2

* Bump `wasmtime` to 0.38.0

* Avoid a duplicate block request when syncing from a fork (#11094)

* Separate queueing blocks for import from removal

* Add regression tests

* Remove unnecessary log

* Clear queued blocks when processed

* Move check out of match block

* Track queued block ranges

* Update client/network/sync/src/blocks.rs

* Update client/network/sync/src/blocks.rs

* Update client/network/sync/src/blocks.rs

* Update client/network/sync/src/blocks.rs

* FMT

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
Co-authored-by: Bastian Köcher <info@kchr.de>

* Democracy.fast_track not allowed with zero voting period (#11666)

* Democracy.fast_track not allowed with zero voting period

* revert static parameter alter line

* ensure voting period greater zero

* update doc for fast_track

* unit test: instant fast track to the next block referendum is backed

* fix typos in comments

* Prevent unsoundness in environments with broken `madvise(MADV_DONTNEED)` (#11722)

* Prevend unsoundness in environments with broken `madvise(MADV_DONTNEED)`

* Add the `std` feature to `rustix` dependency

Apparently not having this breaks compilation on non-nightly toolchains.

* Autodetect the page size when checking whether `madvise` works

* Only make sure that the madvice check doesn't return `Err`

* Refund weight in `system::fillBlock` (#11754)

* fix

* pushed

* node: fix fee multiplier test

Co-authored-by: André Silva <andrerfosilva@gmail.com>

* nomination-pools fix (#11748)

* Nomination pool fix

* fmt

* [ci] Remove polkadot-companion-labels GHA (#11774)

* [contracts] Fixed the bug with transfer value for delegate call (#11771)

* Fixed the bug with transfer value.

* Apply suggestions from code review

Co-authored-by: Alexander Theißen <alex.theissen@me.com>

* Moved check into `initial_transfer`

* Fmt

Co-authored-by: Alexander Theißen <alex.theissen@me.com>

* Fix clearing queued blocks in the sync module (#11763)

* pallet-mmr: handle forks without collisions in offchain storage (#11594)

* pallet-mmr: fix some typos

* pallet-mmr: make the MMR resilient to chain forks

* pallet-mmr: get hash for block that added node

* beefy-mmr: add debug logging

* add explanatory comment

* account for block offset of pallet activation

* add support for finding all nodes added by leaf

* minor improvements

* add helper to return all nodes added to mmr with a leaf append

* simplify leaf_node_index_to_leaf_index

summing the (shifted) differences in peak positions adds up to the (shifted) final position, so
don't need to fold over positions.

* dead fish: this also doesn't work

The idea was to keep a rolling window of `(parent_hash, pos)` leaf
entries in the offchain db, with the window matching the one
that provides `block_num -> block_hash` mappings in `frame_system`.

Once a leaf exits the window it would be "canonicalized" by switching
its offchain db key from `(parent_hash, pos)` to simple `pos`.

This doesn't work however because there's no way to get leaf contents
from offchain db while in runtime context.. so no way to get+clear+set
leaf to change its key in offchain db.

Ideas:
1. move the "canonicalization" logic to offchain worker
2. enhance IndexingApi with "offchain::move(old_key, new_key)"
   This is weird, but correct, deterministic and safe AFAICT, so
   it could be exposed to runtime.

* simplify rightmost_leaf_node_index_from_pos

* minor fix

* move leaf canonicalization to offchain worker

* move storage related code to storage.rs

* on offchain reads use canonic key for old leaves

* fix offchain worker write using canon key

* fix pallet-mmr tests

* add documentation and fix logging

* add offchain mmr canonicalization test

* test canon + generate + verify

* fix pallet-beefy-mmr tests

* implement review suggestions

* improve test

* pallet-mmr: add offchain pruning of forks

* pallet-mmr: improve offchain pruning

Instead of keeping pruning map as single blob in offchain db,
keep individual parent-hash lists with block-num identifier as part
of the offchain key.

Signed-off-by: acatangiu <adrian@parity.io>

* pallet-mmr: improve MMRStore<OffchainStorage>::get()

Do the math and retrieve node using correct (canon or non-canon)
offchain db key, instead of blindly looking in both canon and non-canon
offchain db locations for each node.

Still fallback on looking at both if for any reason it's not where
expected.

Signed-off-by: acatangiu <adrian@parity.io>

* pallet-mmr: storage: improve logs

* fix tests: correctly persist overlay

runtime indexing API works on overlay, whereas offchain context
bypasses overlay, so for loops > canon-window, canon would fail.

* pallet-mmr: fix numeric typo in test

* add comment around LeafData requirements

Signed-off-by: acatangiu <adrian@parity.io>

Co-authored-by: Robert Hambrock <roberthambrock@gmail.com>

* expose grandpa BeforeBestBlockBy voting rule (#11798)

* Un-deprecate Transactional Macro (#11807)

* un-deprecate transactional macro

* add transactional back to nomination pools

* sync: Fixed clearing subsequent ranges (#11815)

* sync: Fixed clearing subsequent ranges

* Warp sync fix

* Better documentation

* CLI flag to configure tx ban duration (#11786)

* add tx-ban-seconds

* fix

* trigger CI

* trigger CI

* remove test print

* Update client/cli/src/params/transaction_pool_params.rs

Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com>

Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com>

* Upgrade libp2p to 0.46.1 (#11787)

* Update libp2p to 0.46.0

* Update libp2p to 0.46.1

* Fix telemetry initialization

* Fix tests

* prep council election pallet for being dissolved (#11790)

* prep council election pallet for being dissolved + make it temporarily bounded

* fix tests

* fix

* Update frame/elections-phragmen/src/lib.rs

* fix bench?

* Network sync refactoring (part 4) (#11412)

* Remove direct dependency of `sc-network` on `sc-network-light`

* Move `WarpSyncProvider` trait and surrounding data structures into `sc-network-common`

* Move `WarpSyncProvider` trait and surrounding data structures into `sc-network-common`

* Create `sync` module in `sc-network-common`, create `ChainSync` trait there (not used yet), move a bunch of associated data structures from `sc-network-sync`

* Switch from concrete implementation to `ChainSync` trait from `sc-network-common`

* Introduce `OpaqueStateRequest`/`OpaqueStateResponse` to remove generics from `StateSync` trait

* Introduce `OpaqueBlockRequest`/`OpaqueBlockResponse`, make `scheme` module of `sc-network-sync` private

* Surface `sc-network-sync` into `sc-service` and make `sc-network` not depend on it anymore

* Remove now unnecessary dependency from `sc-network`

* Replace crate links with just text since dependencies are gone now

* Remove `warp_sync` re-export from `sc-network-common`

* Update copyright in network-related files

* Address review comments about documentation

* Apply review suggestion

* Rename `extra_requests` module to `metrics`

Co-authored-by: Bastian Köcher <info@kchr.de>

* Fix off by one error in proportional slashing (#11782)

* Fix proportional slashing logic

* Update frame/nomination-pools/test-staking/src/lib.rs

Co-authored-by: David <dvdplm@gmail.com>

* Update frame/staking/src/lib.rs

Co-authored-by: David <dvdplm@gmail.com>

* Update frame/staking/src/lib.rs

Co-authored-by: David <dvdplm@gmail.com>

* Update frame/staking/src/lib.rs

Co-authored-by: David <dvdplm@gmail.com>

* fmt

* Update frame/nomination-pools/test-staking/src/lib.rs

* clean

* fix

* last fixes

* doc

Co-authored-by: David <dvdplm@gmail.com>

* Buy&Sell methods for Uniques (#11398)

* Allow to set item's price

* Clean the state when we transfer/burn an item or destroy a collection

* Allow to buy an item

* Remove redundant checks

* Improve events

* Cover with tests

* Add comments

* Apply suggestions

* Fmt

* Improvements for price validation

* Improve validation

* Update to use the new terminology

* Remove multi-assets support

* Chore

* Weights + benchmarking

* Shield against human error

* Test when we pass the higher item's price

* fmt fix

* Chore

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_uniques --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/uniques/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* Remove is_frozen check when setting the price

* Try to fix benchmarking

* Fix benchmarking

* cargo run --quiet --profile=production  --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet…
ark0f pushed a commit to gear-tech/substrate that referenced this pull request Feb 27, 2023
* contracts: Reduce size of deletion queue depth

* Remove unused import
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A0-please_review Pull request needs code review. C1-low PR touches the given topic and has a low impact on builders. D2-notlive 💤 PR contains changes in a runtime directory that is not deployed to a chain that requires an audit.
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

4 participants