moonriver_runtime/weights/pallet_migrations.rs
1// Copyright 2025 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
18//! Autogenerated weights for `pallet_migrations`
19//!
20//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 49.0.0
21//! DATE: 2025-12-09, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
22//! WORST CASE MAP SIZE: `1000000`
23//! HOSTNAME: `ip-10-0-0-36`, CPU: `Intel(R) Xeon(R) Platinum 8375C CPU @ 2.90GHz`
24//! WASM-EXECUTION: Compiled, CHAIN: None, DB CACHE: 1024
25
26// Executed Command:
27// ./frame-omni-bencher
28// v1
29// benchmark
30// pallet
31// --runtime=./target/production/wbuild/moonriver-runtime/moonriver_runtime.wasm
32// --genesis-builder=runtime
33// --genesis-builder-preset=development
34// --steps=50
35// --repeat=20
36// --pallet=pallet_migrations
37// --extrinsic=*
38// --wasm-execution=compiled
39// --header=./file_header.txt
40// --template=./benchmarking/frame-weight-template.hbs
41// --output=./runtime/moonriver/src/weights
42
43#![cfg_attr(rustfmt, rustfmt_skip)]
44#![allow(unused_parens)]
45#![allow(unused_imports)]
46
47use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
48use sp_std::marker::PhantomData;
49
50/// Weights for `pallet_migrations`.
51pub struct WeightInfo<T>(PhantomData<T>);
52impl<T: frame_system::Config> pallet_migrations::WeightInfo for WeightInfo<T> {
53 /// Storage: `MultiBlockMigrations::Cursor` (r:1 w:1)
54 /// Proof: `MultiBlockMigrations::Cursor` (`max_values`: Some(1), `max_size`: Some(65550), added: 66045, mode: `MaxEncodedLen`)
55 /// Storage: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
56 /// Proof: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
57 fn onboard_new_mbms() -> Weight {
58 // Proof Size summary in bytes:
59 // Measured: `100`
60 // Estimated: `67035`
61 // Minimum execution time: 7_655_000 picoseconds.
62 Weight::from_parts(7_859_000, 67035)
63 .saturating_add(T::DbWeight::get().reads(2_u64))
64 .saturating_add(T::DbWeight::get().writes(1_u64))
65 }
66 /// Storage: `MultiBlockMigrations::Cursor` (r:1 w:0)
67 /// Proof: `MultiBlockMigrations::Cursor` (`max_values`: Some(1), `max_size`: Some(65550), added: 66045, mode: `MaxEncodedLen`)
68 fn progress_mbms_none() -> Weight {
69 // Proof Size summary in bytes:
70 // Measured: `4`
71 // Estimated: `67035`
72 // Minimum execution time: 1_771_000 picoseconds.
73 Weight::from_parts(1_911_000, 67035)
74 .saturating_add(T::DbWeight::get().reads(1_u64))
75 }
76 /// Storage: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
77 /// Proof: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
78 /// Storage: `MultiBlockMigrations::Cursor` (r:0 w:1)
79 /// Proof: `MultiBlockMigrations::Cursor` (`max_values`: Some(1), `max_size`: Some(65550), added: 66045, mode: `MaxEncodedLen`)
80 fn exec_migration_completed() -> Weight {
81 // Proof Size summary in bytes:
82 // Measured: `96`
83 // Estimated: `3561`
84 // Minimum execution time: 5_976_000 picoseconds.
85 Weight::from_parts(6_165_000, 3561)
86 .saturating_add(T::DbWeight::get().reads(1_u64))
87 .saturating_add(T::DbWeight::get().writes(1_u64))
88 }
89 /// Storage: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
90 /// Proof: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
91 /// Storage: `MultiBlockMigrations::Historic` (r:1 w:0)
92 /// Proof: `MultiBlockMigrations::Historic` (`max_values`: None, `max_size`: Some(266), added: 2741, mode: `MaxEncodedLen`)
93 fn exec_migration_skipped_historic() -> Weight {
94 // Proof Size summary in bytes:
95 // Measured: `154`
96 // Estimated: `3731`
97 // Minimum execution time: 10_559_000 picoseconds.
98 Weight::from_parts(10_962_000, 3731)
99 .saturating_add(T::DbWeight::get().reads(2_u64))
100 }
101 /// Storage: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
102 /// Proof: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
103 /// Storage: `MultiBlockMigrations::Historic` (r:1 w:0)
104 /// Proof: `MultiBlockMigrations::Historic` (`max_values`: None, `max_size`: Some(266), added: 2741, mode: `MaxEncodedLen`)
105 fn exec_migration_advance() -> Weight {
106 // Proof Size summary in bytes:
107 // Measured: `100`
108 // Estimated: `3731`
109 // Minimum execution time: 10_254_000 picoseconds.
110 Weight::from_parts(10_679_000, 3731)
111 .saturating_add(T::DbWeight::get().reads(2_u64))
112 }
113 /// Storage: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
114 /// Proof: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
115 /// Storage: `MultiBlockMigrations::Historic` (r:1 w:1)
116 /// Proof: `MultiBlockMigrations::Historic` (`max_values`: None, `max_size`: Some(266), added: 2741, mode: `MaxEncodedLen`)
117 fn exec_migration_complete() -> Weight {
118 // Proof Size summary in bytes:
119 // Measured: `100`
120 // Estimated: `3731`
121 // Minimum execution time: 11_863_000 picoseconds.
122 Weight::from_parts(12_336_000, 3731)
123 .saturating_add(T::DbWeight::get().reads(2_u64))
124 .saturating_add(T::DbWeight::get().writes(1_u64))
125 }
126 /// Storage: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
127 /// Proof: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
128 /// Storage: `MultiBlockMigrations::Historic` (r:1 w:0)
129 /// Proof: `MultiBlockMigrations::Historic` (`max_values`: None, `max_size`: Some(266), added: 2741, mode: `MaxEncodedLen`)
130 /// Storage: `XcmpQueue::QueueSuspended` (r:1 w:1)
131 /// Proof: `XcmpQueue::QueueSuspended` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`)
132 /// Storage: `MultiBlockMigrations::Cursor` (r:0 w:1)
133 /// Proof: `MultiBlockMigrations::Cursor` (`max_values`: Some(1), `max_size`: Some(65550), added: 66045, mode: `MaxEncodedLen`)
134 /// Storage: `MaintenanceMode::MaintenanceMode` (r:0 w:1)
135 /// Proof: `MaintenanceMode::MaintenanceMode` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
136 fn exec_migration_fail() -> Weight {
137 // Proof Size summary in bytes:
138 // Measured: `242`
139 // Estimated: `3731`
140 // Minimum execution time: 25_964_000 picoseconds.
141 Weight::from_parts(27_329_000, 3731)
142 .saturating_add(T::DbWeight::get().reads(3_u64))
143 .saturating_add(T::DbWeight::get().writes(3_u64))
144 }
145 fn on_init_loop() -> Weight {
146 // Proof Size summary in bytes:
147 // Measured: `0`
148 // Estimated: `0`
149 // Minimum execution time: 153_000 picoseconds.
150 Weight::from_parts(192_000, 0)
151 }
152 /// Storage: `MultiBlockMigrations::Cursor` (r:0 w:1)
153 /// Proof: `MultiBlockMigrations::Cursor` (`max_values`: Some(1), `max_size`: Some(65550), added: 66045, mode: `MaxEncodedLen`)
154 fn force_set_cursor() -> Weight {
155 // Proof Size summary in bytes:
156 // Measured: `0`
157 // Estimated: `0`
158 // Minimum execution time: 2_732_000 picoseconds.
159 Weight::from_parts(2_914_000, 0)
160 .saturating_add(T::DbWeight::get().writes(1_u64))
161 }
162 /// Storage: `MultiBlockMigrations::Cursor` (r:0 w:1)
163 /// Proof: `MultiBlockMigrations::Cursor` (`max_values`: Some(1), `max_size`: Some(65550), added: 66045, mode: `MaxEncodedLen`)
164 fn force_set_active_cursor() -> Weight {
165 // Proof Size summary in bytes:
166 // Measured: `0`
167 // Estimated: `0`
168 // Minimum execution time: 3_175_000 picoseconds.
169 Weight::from_parts(3_403_000, 0)
170 .saturating_add(T::DbWeight::get().writes(1_u64))
171 }
172 /// Storage: `MultiBlockMigrations::Cursor` (r:1 w:0)
173 /// Proof: `MultiBlockMigrations::Cursor` (`max_values`: Some(1), `max_size`: Some(65550), added: 66045, mode: `MaxEncodedLen`)
174 /// Storage: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
175 /// Proof: UNKNOWN KEY `0x583359fe0e84d953a9dd84e8addb08a5` (r:1 w:0)
176 fn force_onboard_mbms() -> Weight {
177 // Proof Size summary in bytes:
178 // Measured: `76`
179 // Estimated: `67035`
180 // Minimum execution time: 5_404_000 picoseconds.
181 Weight::from_parts(5_650_000, 67035)
182 .saturating_add(T::DbWeight::get().reads(2_u64))
183 }
184 /// Storage: `MultiBlockMigrations::Historic` (r:256 w:256)
185 /// Proof: `MultiBlockMigrations::Historic` (`max_values`: None, `max_size`: Some(266), added: 2741, mode: `MaxEncodedLen`)
186 /// The range of component `n` is `[0, 256]`.
187 fn clear_historic(n: u32, ) -> Weight {
188 // Proof Size summary in bytes:
189 // Measured: `984 + n * (271 ±0)`
190 // Estimated: `3834 + n * (2740 ±0)`
191 // Minimum execution time: 15_323_000 picoseconds.
192 Weight::from_parts(15_819_766, 3834)
193 // Standard Error: 3_350
194 .saturating_add(Weight::from_parts(1_314_481, 0).saturating_mul(n.into()))
195 .saturating_add(T::DbWeight::get().reads(1_u64))
196 .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(n.into())))
197 .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(n.into())))
198 .saturating_add(Weight::from_parts(0, 2740).saturating_mul(n.into()))
199 }
200 /// Storage: `Skipped::Metadata` (r:0 w:0)
201 /// Proof: `Skipped::Metadata` (`max_values`: None, `max_size`: None, mode: `Measured`)
202 /// The range of component `n` is `[0, 2048]`.
203 fn reset_pallet_migration(n: u32, ) -> Weight {
204 // Proof Size summary in bytes:
205 // Measured: `1642 + n * (38 ±0)`
206 // Estimated: `720 + n * (39 ±0)`
207 // Minimum execution time: 2_030_000 picoseconds.
208 Weight::from_parts(14_674_055, 720)
209 // Standard Error: 1_564
210 .saturating_add(Weight::from_parts(764_450, 0).saturating_mul(n.into()))
211 .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(n.into())))
212 .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(n.into())))
213 .saturating_add(Weight::from_parts(0, 39).saturating_mul(n.into()))
214 }
215}