referrerpolicy=no-referrer-when-downgrade

rococo_runtime/weights/
pallet_ranked_collective.rs

1// Copyright (C) Parity Technologies (UK) Ltd.
2// This file is part of Polkadot.
3
4// Polkadot is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8
9// Polkadot is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12// GNU General Public License for more details.
13
14// You should have received a copy of the GNU General Public License
15// along with Polkadot.  If not, see <http://www.gnu.org/licenses/>.
16
17//! Autogenerated weights for `pallet_ranked_collective`
18//!
19//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0
20//! DATE: 2025-02-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
21//! WORST CASE MAP SIZE: `1000000`
22//! HOSTNAME: `d3a9aad6f7a3`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz`
23//! WASM-EXECUTION: `Compiled`, CHAIN: `None`, DB CACHE: 1024
24
25// Executed Command:
26// frame-omni-bencher
27// v1
28// benchmark
29// pallet
30// --extrinsic=*
31// --runtime=target/production/wbuild/rococo-runtime/rococo_runtime.wasm
32// --pallet=pallet_ranked_collective
33// --header=/__w/polkadot-sdk/polkadot-sdk/polkadot/file_header.txt
34// --output=./polkadot/runtime/rococo/src/weights
35// --wasm-execution=compiled
36// --steps=50
37// --repeat=20
38// --heap-pages=4096
39// --no-storage-info
40// --no-min-squares
41// --no-median-slopes
42
43#![cfg_attr(rustfmt, rustfmt_skip)]
44#![allow(unused_parens)]
45#![allow(unused_imports)]
46#![allow(missing_docs)]
47
48use frame_support::{traits::Get, weights::Weight};
49use core::marker::PhantomData;
50
51/// Weight functions for `pallet_ranked_collective`.
52pub struct WeightInfo<T>(PhantomData<T>);
53impl<T: frame_system::Config> pallet_ranked_collective::WeightInfo for WeightInfo<T> {
54	/// Storage: `FellowshipCollective::Members` (r:1 w:1)
55	/// Proof: `FellowshipCollective::Members` (`max_values`: None, `max_size`: Some(42), added: 2517, mode: `MaxEncodedLen`)
56	/// Storage: `FellowshipCollective::MemberCount` (r:1 w:1)
57	/// Proof: `FellowshipCollective::MemberCount` (`max_values`: None, `max_size`: Some(14), added: 2489, mode: `MaxEncodedLen`)
58	/// Storage: `FellowshipCollective::IndexToId` (r:0 w:1)
59	/// Proof: `FellowshipCollective::IndexToId` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
60	/// Storage: `FellowshipCollective::IdToIndex` (r:0 w:1)
61	/// Proof: `FellowshipCollective::IdToIndex` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
62	fn add_member() -> Weight {
63		// Proof Size summary in bytes:
64		//  Measured:  `42`
65		//  Estimated: `3507`
66		// Minimum execution time: 16_430_000 picoseconds.
67		Weight::from_parts(17_080_000, 0)
68			.saturating_add(Weight::from_parts(0, 3507))
69			.saturating_add(T::DbWeight::get().reads(2))
70			.saturating_add(T::DbWeight::get().writes(4))
71	}
72	/// Storage: `FellowshipCollective::Members` (r:1 w:1)
73	/// Proof: `FellowshipCollective::Members` (`max_values`: None, `max_size`: Some(42), added: 2517, mode: `MaxEncodedLen`)
74	/// Storage: `FellowshipCollective::MemberCount` (r:11 w:11)
75	/// Proof: `FellowshipCollective::MemberCount` (`max_values`: None, `max_size`: Some(14), added: 2489, mode: `MaxEncodedLen`)
76	/// Storage: `FellowshipCollective::IdToIndex` (r:11 w:22)
77	/// Proof: `FellowshipCollective::IdToIndex` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
78	/// Storage: `FellowshipCollective::IndexToId` (r:11 w:22)
79	/// Proof: `FellowshipCollective::IndexToId` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
80	/// The range of component `r` is `[0, 10]`.
81	fn remove_member(r: u32, ) -> Weight {
82		// Proof Size summary in bytes:
83		//  Measured:  `415 + r * (213 ±0)`
84		//  Estimated: `3519 + r * (2529 ±0)`
85		// Minimum execution time: 32_717_000 picoseconds.
86		Weight::from_parts(35_037_255, 0)
87			.saturating_add(Weight::from_parts(0, 3519))
88			// Standard Error: 35_592
89			.saturating_add(Weight::from_parts(18_397_384, 0).saturating_mul(r.into()))
90			.saturating_add(T::DbWeight::get().reads(4))
91			.saturating_add(T::DbWeight::get().reads((3_u64).saturating_mul(r.into())))
92			.saturating_add(T::DbWeight::get().writes(6))
93			.saturating_add(T::DbWeight::get().writes((5_u64).saturating_mul(r.into())))
94			.saturating_add(Weight::from_parts(0, 2529).saturating_mul(r.into()))
95	}
96	/// Storage: `FellowshipCollective::Members` (r:1 w:1)
97	/// Proof: `FellowshipCollective::Members` (`max_values`: None, `max_size`: Some(42), added: 2517, mode: `MaxEncodedLen`)
98	/// Storage: `FellowshipCollective::MemberCount` (r:1 w:1)
99	/// Proof: `FellowshipCollective::MemberCount` (`max_values`: None, `max_size`: Some(14), added: 2489, mode: `MaxEncodedLen`)
100	/// Storage: `FellowshipCollective::IndexToId` (r:0 w:1)
101	/// Proof: `FellowshipCollective::IndexToId` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
102	/// Storage: `FellowshipCollective::IdToIndex` (r:0 w:1)
103	/// Proof: `FellowshipCollective::IdToIndex` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
104	/// The range of component `r` is `[0, 10]`.
105	fn promote_member(r: u32, ) -> Weight {
106		// Proof Size summary in bytes:
107		//  Measured:  `214 + r * (17 ±0)`
108		//  Estimated: `3507`
109		// Minimum execution time: 20_549_000 picoseconds.
110		Weight::from_parts(21_481_207, 0)
111			.saturating_add(Weight::from_parts(0, 3507))
112			// Standard Error: 7_127
113			.saturating_add(Weight::from_parts(538_780, 0).saturating_mul(r.into()))
114			.saturating_add(T::DbWeight::get().reads(2))
115			.saturating_add(T::DbWeight::get().writes(4))
116	}
117	/// Storage: `FellowshipCollective::Members` (r:1 w:1)
118	/// Proof: `FellowshipCollective::Members` (`max_values`: None, `max_size`: Some(42), added: 2517, mode: `MaxEncodedLen`)
119	/// Storage: `FellowshipCollective::MemberCount` (r:1 w:1)
120	/// Proof: `FellowshipCollective::MemberCount` (`max_values`: None, `max_size`: Some(14), added: 2489, mode: `MaxEncodedLen`)
121	/// Storage: `FellowshipCollective::IdToIndex` (r:1 w:2)
122	/// Proof: `FellowshipCollective::IdToIndex` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
123	/// Storage: `FellowshipCollective::IndexToId` (r:1 w:2)
124	/// Proof: `FellowshipCollective::IndexToId` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
125	/// The range of component `r` is `[0, 10]`.
126	fn demote_member(r: u32, ) -> Weight {
127		// Proof Size summary in bytes:
128		//  Measured:  `430 + r * (72 ±0)`
129		//  Estimated: `3519`
130		// Minimum execution time: 32_966_000 picoseconds.
131		Weight::from_parts(36_366_266, 0)
132			.saturating_add(Weight::from_parts(0, 3519))
133			// Standard Error: 24_910
134			.saturating_add(Weight::from_parts(969_525, 0).saturating_mul(r.into()))
135			.saturating_add(T::DbWeight::get().reads(4))
136			.saturating_add(T::DbWeight::get().writes(6))
137	}
138	/// Storage: `FellowshipCollective::Members` (r:1 w:0)
139	/// Proof: `FellowshipCollective::Members` (`max_values`: None, `max_size`: Some(42), added: 2517, mode: `MaxEncodedLen`)
140	/// Storage: `FellowshipReferenda::ReferendumInfoFor` (r:1 w:1)
141	/// Proof: `FellowshipReferenda::ReferendumInfoFor` (`max_values`: None, `max_size`: Some(900), added: 3375, mode: `MaxEncodedLen`)
142	/// Storage: `FellowshipCollective::Voting` (r:1 w:1)
143	/// Proof: `FellowshipCollective::Voting` (`max_values`: None, `max_size`: Some(65), added: 2540, mode: `MaxEncodedLen`)
144	/// Storage: `Scheduler::Agenda` (r:2 w:2)
145	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
146	/// Storage: `Scheduler::Retries` (r:0 w:1)
147	/// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`)
148	fn vote() -> Weight {
149		// Proof Size summary in bytes:
150		//  Measured:  `556`
151		//  Estimated: `83866`
152		// Minimum execution time: 47_150_000 picoseconds.
153		Weight::from_parts(48_469_000, 0)
154			.saturating_add(Weight::from_parts(0, 83866))
155			.saturating_add(T::DbWeight::get().reads(5))
156			.saturating_add(T::DbWeight::get().writes(5))
157	}
158	/// Storage: `FellowshipReferenda::ReferendumInfoFor` (r:1 w:0)
159	/// Proof: `FellowshipReferenda::ReferendumInfoFor` (`max_values`: None, `max_size`: Some(900), added: 3375, mode: `MaxEncodedLen`)
160	/// Storage: `FellowshipCollective::VotingCleanup` (r:1 w:0)
161	/// Proof: `FellowshipCollective::VotingCleanup` (`max_values`: None, `max_size`: Some(114), added: 2589, mode: `MaxEncodedLen`)
162	/// Storage: `FellowshipCollective::Voting` (r:100 w:100)
163	/// Proof: `FellowshipCollective::Voting` (`max_values`: None, `max_size`: Some(65), added: 2540, mode: `MaxEncodedLen`)
164	/// The range of component `n` is `[0, 100]`.
165	fn cleanup_poll(n: u32, ) -> Weight {
166		// Proof Size summary in bytes:
167		//  Measured:  `401 + n * (50 ±0)`
168		//  Estimated: `4365 + n * (2540 ±0)`
169		// Minimum execution time: 15_928_000 picoseconds.
170		Weight::from_parts(19_664_942, 0)
171			.saturating_add(Weight::from_parts(0, 4365))
172			// Standard Error: 2_911
173			.saturating_add(Weight::from_parts(1_312_635, 0).saturating_mul(n.into()))
174			.saturating_add(T::DbWeight::get().reads(2))
175			.saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(n.into())))
176			.saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(n.into())))
177			.saturating_add(Weight::from_parts(0, 2540).saturating_mul(n.into()))
178	}
179	/// Storage: `FellowshipCollective::Members` (r:2 w:2)
180	/// Proof: `FellowshipCollective::Members` (`max_values`: None, `max_size`: Some(42), added: 2517, mode: `MaxEncodedLen`)
181	/// Storage: `FellowshipCollective::MemberCount` (r:2 w:2)
182	/// Proof: `FellowshipCollective::MemberCount` (`max_values`: None, `max_size`: Some(14), added: 2489, mode: `MaxEncodedLen`)
183	/// Storage: `FellowshipCollective::IdToIndex` (r:2 w:4)
184	/// Proof: `FellowshipCollective::IdToIndex` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
185	/// Storage: `FellowshipCollective::IndexToId` (r:0 w:2)
186	/// Proof: `FellowshipCollective::IndexToId` (`max_values`: None, `max_size`: Some(54), added: 2529, mode: `MaxEncodedLen`)
187	fn exchange_member() -> Weight {
188		// Proof Size summary in bytes:
189		//  Measured:  `337`
190		//  Estimated: `6048`
191		// Minimum execution time: 50_332_000 picoseconds.
192		Weight::from_parts(51_464_000, 0)
193			.saturating_add(Weight::from_parts(0, 6048))
194			.saturating_add(T::DbWeight::get().reads(6))
195			.saturating_add(T::DbWeight::get().writes(10))
196	}
197}