1
// Copyright 2024 Moonbeam foundation
2
// This file is part of Moonbeam.
3

            
4
// Moonbeam 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
// Moonbeam 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 Moonbeam.  If not, see <http://www.gnu.org/licenses/>.
16

            
17
//! Autogenerated weights for `pallet_scheduler`
18
//!
19
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 42.0.0
20
//! DATE: 2024-10-10, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
21
//! WORST CASE MAP SIZE: `1000000`
22
//! HOSTNAME: `ip-10-0-0-176`, CPU: `Intel(R) Xeon(R) Platinum 8375C CPU @ 2.90GHz`
23
//! WASM-EXECUTION: Compiled, CHAIN: Some("moonbase-dev"), DB CACHE: 1024
24

            
25
// Executed Command:
26
// ./target/production/moonbeam
27
// benchmark
28
// pallet
29
// --chain=moonbase-dev
30
// --steps=50
31
// --repeat=20
32
// --pallet=pallet_scheduler
33
// --extrinsic=*
34
// --wasm-execution=compiled
35
// --header=./file_header.txt
36
// --template=./benchmarking/frame-weight-template.hbs
37
// --output=./runtime/common/src/weights/
38

            
39
#![cfg_attr(rustfmt, rustfmt_skip)]
40
#![allow(unused_parens)]
41
#![allow(unused_imports)]
42

            
43
use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
44
use sp_std::marker::PhantomData;
45

            
46
/// Weights for `pallet_scheduler`.
47
pub struct WeightInfo<T>(PhantomData<T>);
48
impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> {
49
	/// Storage: `Scheduler::IncompleteSince` (r:1 w:1)
50
	/// Proof: `Scheduler::IncompleteSince` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
51
66
	fn service_agendas_base() -> Weight {
52
66
		// Proof Size summary in bytes:
53
66
		//  Measured:  `31`
54
66
		//  Estimated: `1489`
55
66
		// Minimum execution time: 2_621_000 picoseconds.
56
66
		Weight::from_parts(2_753_000, 1489)
57
66
			.saturating_add(T::DbWeight::get().reads(1_u64))
58
66
			.saturating_add(T::DbWeight::get().writes(1_u64))
59
66
	}
60
	/// Storage: `Scheduler::Agenda` (r:1 w:1)
61
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
62
	/// The range of component `s` is `[0, 50]`.
63
132
	fn service_agenda_base(s: u32, ) -> Weight {
64
132
		// Proof Size summary in bytes:
65
132
		//  Measured:  `78 + s * (177 ±0)`
66
132
		//  Estimated: `42428`
67
132
		// Minimum execution time: 3_170_000 picoseconds.
68
132
		Weight::from_parts(5_927_881, 42428)
69
132
			// Standard Error: 1_403
70
132
			.saturating_add(Weight::from_parts(354_748, 0).saturating_mul(s.into()))
71
132
			.saturating_add(T::DbWeight::get().reads(1_u64))
72
132
			.saturating_add(T::DbWeight::get().writes(1_u64))
73
132
	}
74
	fn service_task_base() -> Weight {
75
		// Proof Size summary in bytes:
76
		//  Measured:  `0`
77
		//  Estimated: `0`
78
		// Minimum execution time: 3_067_000 picoseconds.
79
		Weight::from_parts(3_281_000, 0)
80
	}
81
	/// Storage: `Preimage::PreimageFor` (r:1 w:1)
82
	/// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `Measured`)
83
	/// Storage: `Preimage::StatusFor` (r:1 w:0)
84
	/// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(79), added: 2554, mode: `MaxEncodedLen`)
85
	/// Storage: `Preimage::RequestStatusFor` (r:1 w:1)
86
	/// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(79), added: 2554, mode: `MaxEncodedLen`)
87
	/// The range of component `s` is `[128, 4194304]`.
88
	fn service_task_fetched(s: u32, ) -> Weight {
89
		// Proof Size summary in bytes:
90
		//  Measured:  `179 + s * (1 ±0)`
91
		//  Estimated: `3644 + s * (1 ±0)`
92
		// Minimum execution time: 17_142_000 picoseconds.
93
		Weight::from_parts(17_417_000, 3644)
94
			// Standard Error: 3
95
			.saturating_add(Weight::from_parts(1_184, 0).saturating_mul(s.into()))
96
			.saturating_add(T::DbWeight::get().reads(3_u64))
97
			.saturating_add(T::DbWeight::get().writes(2_u64))
98
			.saturating_add(Weight::from_parts(0, 1).saturating_mul(s.into()))
99
	}
100
	/// Storage: `Scheduler::Lookup` (r:0 w:1)
101
	/// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`)
102
	fn service_task_named() -> Weight {
103
		// Proof Size summary in bytes:
104
		//  Measured:  `0`
105
		//  Estimated: `0`
106
		// Minimum execution time: 4_529_000 picoseconds.
107
		Weight::from_parts(4_744_000, 0)
108
			.saturating_add(T::DbWeight::get().writes(1_u64))
109
	}
110
	fn service_task_periodic() -> Weight {
111
		// Proof Size summary in bytes:
112
		//  Measured:  `0`
113
		//  Estimated: `0`
114
		// Minimum execution time: 3_109_000 picoseconds.
115
		Weight::from_parts(3_244_000, 0)
116
	}
117
	/// Storage: `MaintenanceMode::MaintenanceMode` (r:1 w:0)
118
	/// Proof: `MaintenanceMode::MaintenanceMode` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
119
	fn execute_dispatch_signed() -> Weight {
120
		// Proof Size summary in bytes:
121
		//  Measured:  `42`
122
		//  Estimated: `1527`
123
		// Minimum execution time: 4_093_000 picoseconds.
124
		Weight::from_parts(4_217_000, 1527)
125
			.saturating_add(T::DbWeight::get().reads(1_u64))
126
	}
127
	fn execute_dispatch_unsigned() -> Weight {
128
		// Proof Size summary in bytes:
129
		//  Measured:  `0`
130
		//  Estimated: `0`
131
		// Minimum execution time: 2_105_000 picoseconds.
132
		Weight::from_parts(2_247_000, 0)
133
	}
134
	/// Storage: `Scheduler::Agenda` (r:1 w:1)
135
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
136
	/// The range of component `s` is `[0, 49]`.
137
	fn schedule(s: u32, ) -> Weight {
138
		// Proof Size summary in bytes:
139
		//  Measured:  `78 + s * (177 ±0)`
140
		//  Estimated: `42428`
141
		// Minimum execution time: 9_393_000 picoseconds.
142
		Weight::from_parts(12_167_556, 42428)
143
			// Standard Error: 1_377
144
			.saturating_add(Weight::from_parts(390_748, 0).saturating_mul(s.into()))
145
			.saturating_add(T::DbWeight::get().reads(1_u64))
146
			.saturating_add(T::DbWeight::get().writes(1_u64))
147
	}
148
	/// Storage: `Scheduler::Agenda` (r:1 w:1)
149
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
150
	/// Storage: `Scheduler::Retries` (r:0 w:1)
151
	/// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`)
152
	/// Storage: `Scheduler::Lookup` (r:0 w:1)
153
	/// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`)
154
	/// The range of component `s` is `[1, 50]`.
155
	fn cancel(s: u32, ) -> Weight {
156
		// Proof Size summary in bytes:
157
		//  Measured:  `78 + s * (177 ±0)`
158
		//  Estimated: `42428`
159
		// Minimum execution time: 14_596_000 picoseconds.
160
		Weight::from_parts(14_240_015, 42428)
161
			// Standard Error: 893
162
			.saturating_add(Weight::from_parts(580_656, 0).saturating_mul(s.into()))
163
			.saturating_add(T::DbWeight::get().reads(1_u64))
164
			.saturating_add(T::DbWeight::get().writes(3_u64))
165
	}
166
	/// Storage: `Scheduler::Lookup` (r:1 w:1)
167
	/// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`)
168
	/// Storage: `Scheduler::Agenda` (r:1 w:1)
169
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
170
	/// The range of component `s` is `[0, 49]`.
171
	fn schedule_named(s: u32, ) -> Weight {
172
		// Proof Size summary in bytes:
173
		//  Measured:  `255 + s * (185 ±0)`
174
		//  Estimated: `42428`
175
		// Minimum execution time: 12_639_000 picoseconds.
176
		Weight::from_parts(16_075_313, 42428)
177
			// Standard Error: 2_003
178
			.saturating_add(Weight::from_parts(422_175, 0).saturating_mul(s.into()))
179
			.saturating_add(T::DbWeight::get().reads(2_u64))
180
			.saturating_add(T::DbWeight::get().writes(2_u64))
181
	}
182
	/// Storage: `Scheduler::Lookup` (r:1 w:1)
183
	/// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`)
184
	/// Storage: `Scheduler::Agenda` (r:1 w:1)
185
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
186
	/// Storage: `Scheduler::Retries` (r:0 w:1)
187
	/// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`)
188
	/// The range of component `s` is `[1, 50]`.
189
	fn cancel_named(s: u32, ) -> Weight {
190
		// Proof Size summary in bytes:
191
		//  Measured:  `281 + s * (185 ±0)`
192
		//  Estimated: `42428`
193
		// Minimum execution time: 16_711_000 picoseconds.
194
		Weight::from_parts(17_065_110, 42428)
195
			// Standard Error: 1_372
196
			.saturating_add(Weight::from_parts(606_803, 0).saturating_mul(s.into()))
197
			.saturating_add(T::DbWeight::get().reads(2_u64))
198
			.saturating_add(T::DbWeight::get().writes(3_u64))
199
	}
200
	/// Storage: `Scheduler::Agenda` (r:1 w:1)
201
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
202
	/// Storage: `Scheduler::Retries` (r:0 w:1)
203
	/// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`)
204
	/// The range of component `s` is `[1, 50]`.
205
	fn schedule_retry(s: u32, ) -> Weight {
206
		// Proof Size summary in bytes:
207
		//  Measured:  `118`
208
		//  Estimated: `42428`
209
		// Minimum execution time: 8_467_000 picoseconds.
210
		Weight::from_parts(8_856_278, 42428)
211
			// Standard Error: 385
212
			.saturating_add(Weight::from_parts(24_461, 0).saturating_mul(s.into()))
213
			.saturating_add(T::DbWeight::get().reads(1_u64))
214
			.saturating_add(T::DbWeight::get().writes(2_u64))
215
	}
216
	/// Storage: `Scheduler::Agenda` (r:1 w:0)
217
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
218
	/// Storage: `Scheduler::Retries` (r:0 w:1)
219
	/// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`)
220
	fn set_retry() -> Weight {
221
		// Proof Size summary in bytes:
222
		//  Measured:  `8928`
223
		//  Estimated: `42428`
224
		// Minimum execution time: 23_472_000 picoseconds.
225
		Weight::from_parts(24_473_000, 42428)
226
			.saturating_add(T::DbWeight::get().reads(1_u64))
227
			.saturating_add(T::DbWeight::get().writes(1_u64))
228
	}
229
	/// Storage: `Scheduler::Lookup` (r:1 w:0)
230
	/// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`)
231
	/// Storage: `Scheduler::Agenda` (r:1 w:0)
232
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
233
	/// Storage: `Scheduler::Retries` (r:0 w:1)
234
	/// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`)
235
	fn set_retry_named() -> Weight {
236
		// Proof Size summary in bytes:
237
		//  Measured:  `9606`
238
		//  Estimated: `42428`
239
		// Minimum execution time: 29_093_000 picoseconds.
240
		Weight::from_parts(29_665_000, 42428)
241
			.saturating_add(T::DbWeight::get().reads(2_u64))
242
			.saturating_add(T::DbWeight::get().writes(1_u64))
243
	}
244
	/// Storage: `Scheduler::Agenda` (r:1 w:0)
245
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
246
	/// Storage: `Scheduler::Retries` (r:0 w:1)
247
	/// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`)
248
	fn cancel_retry() -> Weight {
249
		// Proof Size summary in bytes:
250
		//  Measured:  `8940`
251
		//  Estimated: `42428`
252
		// Minimum execution time: 22_793_000 picoseconds.
253
		Weight::from_parts(23_519_000, 42428)
254
			.saturating_add(T::DbWeight::get().reads(1_u64))
255
			.saturating_add(T::DbWeight::get().writes(1_u64))
256
	}
257
	/// Storage: `Scheduler::Lookup` (r:1 w:0)
258
	/// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`)
259
	/// Storage: `Scheduler::Agenda` (r:1 w:0)
260
	/// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(38963), added: 41438, mode: `MaxEncodedLen`)
261
	/// Storage: `Scheduler::Retries` (r:0 w:1)
262
	/// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`)
263
	fn cancel_retry_named() -> Weight {
264
		// Proof Size summary in bytes:
265
		//  Measured:  `9618`
266
		//  Estimated: `42428`
267
		// Minimum execution time: 27_488_000 picoseconds.
268
		Weight::from_parts(28_332_000, 42428)
269
			.saturating_add(T::DbWeight::get().reads(2_u64))
270
			.saturating_add(T::DbWeight::get().writes(1_u64))
271
	}
272
}