1// Template adopted from https://github.com/paritytech/substrate/blob/master/.maintain/frame-weight-template.hbs23//! Autogenerated weights for pallet_unique4//!5//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev6//! DATE: 2023-04-20, STEPS: `50`, REPEAT: `80`, LOW RANGE: `[]`, HIGH RANGE: `[]`7//! WORST CASE MAP SIZE: `1000000`8//! HOSTNAME: `bench-host`, CPU: `Intel(R) Core(TM) i7-8700 CPU @ 3.20GHz`9//! EXECUTION: None, WASM-EXECUTION: Compiled, CHAIN: None, DB CACHE: 10241011// Executed Command:12// target/release/unique-collator13// benchmark14// pallet15// --pallet16// pallet-unique17// --wasm-execution18// compiled19// --extrinsic20// *21// --template=.maintain/frame-weight-template.hbs22// --steps=5023// --repeat=8024// --heap-pages=409625// --output=./pallets/unique/src/weights.rs2627#![cfg_attr(rustfmt, rustfmt_skip)]28#![allow(unused_parens)]29#![allow(unused_imports)]3031use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};32use sp_std::marker::PhantomData;3334/// Weight functions needed for pallet_unique.35pub trait WeightInfo {36 fn create_collection() -> Weight;37 fn destroy_collection() -> Weight;38 fn add_to_allow_list() -> Weight;39 fn remove_from_allow_list() -> Weight;40 fn change_collection_owner() -> Weight;41 fn add_collection_admin() -> Weight;42 fn remove_collection_admin() -> Weight;43 fn set_collection_sponsor() -> Weight;44 fn confirm_sponsorship() -> Weight;45 fn remove_collection_sponsor() -> Weight;46 fn set_transfers_enabled_flag() -> Weight;47 fn set_collection_limits() -> Weight;48 fn force_repair_collection() -> Weight;49}5051/// Weights for pallet_unique using the Substrate node and recommended hardware.52pub struct SubstrateWeight<T>(PhantomData<T>);53impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {54 /// Storage: Common CreatedCollectionCount (r:1 w:1)55 /// Proof: Common CreatedCollectionCount (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)56 /// Storage: Common DestroyedCollectionCount (r:1 w:0)57 /// Proof: Common DestroyedCollectionCount (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)58 /// Storage: System Account (r:2 w:2)59 /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen)60 /// Storage: Common CollectionPropertyPermissions (r:0 w:1)61 /// Proof: Common CollectionPropertyPermissions (max_values: None, max_size: Some(16726), added: 19201, mode: MaxEncodedLen)62 /// Storage: Common CollectionProperties (r:0 w:1)63 /// Proof: Common CollectionProperties (max_values: None, max_size: Some(40992), added: 43467, mode: MaxEncodedLen)64 /// Storage: Common CollectionById (r:0 w:1)65 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)66 fn create_collection() -> Weight {67 // Proof Size summary in bytes:68 // Measured: `245`69 // Estimated: `9174`70 // Minimum execution time: 31_198_000 picoseconds.71 Weight::from_parts(32_046_000, 9174)72 .saturating_add(T::DbWeight::get().reads(4_u64))73 .saturating_add(T::DbWeight::get().writes(6_u64))74 }75 /// Storage: Common CollectionById (r:1 w:1)76 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)77 /// Storage: Nonfungible TokenData (r:1 w:0)78 /// Proof: Nonfungible TokenData (max_values: None, max_size: Some(57), added: 2532, mode: MaxEncodedLen)79 /// Storage: Common DestroyedCollectionCount (r:1 w:1)80 /// Proof: Common DestroyedCollectionCount (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)81 /// Storage: Nonfungible TokensMinted (r:0 w:1)82 /// Proof: Nonfungible TokensMinted (max_values: None, max_size: Some(16), added: 2491, mode: MaxEncodedLen)83 /// Storage: Nonfungible TokensBurnt (r:0 w:1)84 /// Proof: Nonfungible TokensBurnt (max_values: None, max_size: Some(16), added: 2491, mode: MaxEncodedLen)85 /// Storage: Common AdminAmount (r:0 w:1)86 /// Proof: Common AdminAmount (max_values: None, max_size: Some(24), added: 2499, mode: MaxEncodedLen)87 /// Storage: Common CollectionProperties (r:0 w:1)88 /// Proof: Common CollectionProperties (max_values: None, max_size: Some(40992), added: 43467, mode: MaxEncodedLen)89 fn destroy_collection() -> Weight {90 // Proof Size summary in bytes:91 // Measured: `1086`92 // Estimated: `9336`93 // Minimum execution time: 48_208_000 picoseconds.94 Weight::from_parts(49_031_000, 9336)95 .saturating_add(T::DbWeight::get().reads(3_u64))96 .saturating_add(T::DbWeight::get().writes(6_u64))97 }98 /// Storage: Common CollectionById (r:1 w:0)99 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)100 /// Storage: Common Allowlist (r:0 w:1)101 /// Proof: Common Allowlist (max_values: None, max_size: Some(70), added: 2545, mode: MaxEncodedLen)102 fn add_to_allow_list() -> Weight {103 // Proof Size summary in bytes:104 // Measured: `967`105 // Estimated: `4325`106 // Minimum execution time: 14_852_000 picoseconds.107 Weight::from_parts(15_268_000, 4325)108 .saturating_add(T::DbWeight::get().reads(1_u64))109 .saturating_add(T::DbWeight::get().writes(1_u64))110 }111 /// Storage: Common CollectionById (r:1 w:0)112 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)113 /// Storage: Common Allowlist (r:0 w:1)114 /// Proof: Common Allowlist (max_values: None, max_size: Some(70), added: 2545, mode: MaxEncodedLen)115 fn remove_from_allow_list() -> Weight {116 // Proof Size summary in bytes:117 // Measured: `1000`118 // Estimated: `4325`119 // Minimum execution time: 14_595_000 picoseconds.120 Weight::from_parts(14_933_000, 4325)121 .saturating_add(T::DbWeight::get().reads(1_u64))122 .saturating_add(T::DbWeight::get().writes(1_u64))123 }124 /// Storage: Common CollectionById (r:1 w:1)125 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)126 fn change_collection_owner() -> Weight {127 // Proof Size summary in bytes:128 // Measured: `967`129 // Estimated: `4325`130 // Minimum execution time: 14_132_000 picoseconds.131 Weight::from_parts(14_501_000, 4325)132 .saturating_add(T::DbWeight::get().reads(1_u64))133 .saturating_add(T::DbWeight::get().writes(1_u64))134 }135 /// Storage: Common CollectionById (r:1 w:0)136 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)137 /// Storage: Common IsAdmin (r:1 w:1)138 /// Proof: Common IsAdmin (max_values: None, max_size: Some(70), added: 2545, mode: MaxEncodedLen)139 /// Storage: Common AdminAmount (r:1 w:1)140 /// Proof: Common AdminAmount (max_values: None, max_size: Some(24), added: 2499, mode: MaxEncodedLen)141 fn add_collection_admin() -> Weight {142 // Proof Size summary in bytes:143 // Measured: `967`144 // Estimated: `11349`145 // Minimum execution time: 17_229_000 picoseconds.146 Weight::from_parts(17_657_000, 11349)147 .saturating_add(T::DbWeight::get().reads(3_u64))148 .saturating_add(T::DbWeight::get().writes(2_u64))149 }150 /// Storage: Common CollectionById (r:1 w:0)151 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)152 /// Storage: Common IsAdmin (r:1 w:1)153 /// Proof: Common IsAdmin (max_values: None, max_size: Some(70), added: 2545, mode: MaxEncodedLen)154 /// Storage: Common AdminAmount (r:1 w:1)155 /// Proof: Common AdminAmount (max_values: None, max_size: Some(24), added: 2499, mode: MaxEncodedLen)156 fn remove_collection_admin() -> Weight {157 // Proof Size summary in bytes:158 // Measured: `1107`159 // Estimated: `11349`160 // Minimum execution time: 19_827_000 picoseconds.161 Weight::from_parts(20_479_000, 11349)162 .saturating_add(T::DbWeight::get().reads(3_u64))163 .saturating_add(T::DbWeight::get().writes(2_u64))164 }165 /// Storage: Common CollectionById (r:1 w:1)166 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)167 fn set_collection_sponsor() -> Weight {168 // Proof Size summary in bytes:169 // Measured: `967`170 // Estimated: `4325`171 // Minimum execution time: 14_049_000 picoseconds.172 Weight::from_parts(14_420_000, 4325)173 .saturating_add(T::DbWeight::get().reads(1_u64))174 .saturating_add(T::DbWeight::get().writes(1_u64))175 }176 /// Storage: Common CollectionById (r:1 w:1)177 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)178 fn confirm_sponsorship() -> Weight {179 // Proof Size summary in bytes:180 // Measured: `999`181 // Estimated: `4325`182 // Minimum execution time: 13_689_000 picoseconds.183 Weight::from_parts(14_044_000, 4325)184 .saturating_add(T::DbWeight::get().reads(1_u64))185 .saturating_add(T::DbWeight::get().writes(1_u64))186 }187 /// Storage: Common CollectionById (r:1 w:1)188 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)189 fn remove_collection_sponsor() -> Weight {190 // Proof Size summary in bytes:191 // Measured: `999`192 // Estimated: `4325`193 // Minimum execution time: 13_275_000 picoseconds.194 Weight::from_parts(13_598_000, 4325)195 .saturating_add(T::DbWeight::get().reads(1_u64))196 .saturating_add(T::DbWeight::get().writes(1_u64))197 }198 /// Storage: Common CollectionById (r:1 w:1)199 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)200 fn set_transfers_enabled_flag() -> Weight {201 // Proof Size summary in bytes:202 // Measured: `967`203 // Estimated: `4325`204 // Minimum execution time: 9_411_000 picoseconds.205 Weight::from_parts(9_706_000, 4325)206 .saturating_add(T::DbWeight::get().reads(1_u64))207 .saturating_add(T::DbWeight::get().writes(1_u64))208 }209 /// Storage: Common CollectionById (r:1 w:1)210 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)211 fn set_collection_limits() -> Weight {212 // Proof Size summary in bytes:213 // Measured: `967`214 // Estimated: `4325`215 // Minimum execution time: 13_864_000 picoseconds.216 Weight::from_parts(14_368_000, 4325)217 .saturating_add(T::DbWeight::get().reads(1_u64))218 .saturating_add(T::DbWeight::get().writes(1_u64))219 }220 /// Storage: Common CollectionProperties (r:1 w:1)221 /// Proof: Common CollectionProperties (max_values: None, max_size: Some(40992), added: 43467, mode: MaxEncodedLen)222 fn force_repair_collection() -> Weight {223 // Proof Size summary in bytes:224 // Measured: `265`225 // Estimated: `44457`226 // Minimum execution time: 7_104_000 picoseconds.227 Weight::from_parts(7_293_000, 44457)228 .saturating_add(T::DbWeight::get().reads(1_u64))229 .saturating_add(T::DbWeight::get().writes(1_u64))230 }231}232233// For backwards compatibility and tests234impl WeightInfo for () {235 /// Storage: Common CreatedCollectionCount (r:1 w:1)236 /// Proof: Common CreatedCollectionCount (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)237 /// Storage: Common DestroyedCollectionCount (r:1 w:0)238 /// Proof: Common DestroyedCollectionCount (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)239 /// Storage: System Account (r:2 w:2)240 /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen)241 /// Storage: Common CollectionPropertyPermissions (r:0 w:1)242 /// Proof: Common CollectionPropertyPermissions (max_values: None, max_size: Some(16726), added: 19201, mode: MaxEncodedLen)243 /// Storage: Common CollectionProperties (r:0 w:1)244 /// Proof: Common CollectionProperties (max_values: None, max_size: Some(40992), added: 43467, mode: MaxEncodedLen)245 /// Storage: Common CollectionById (r:0 w:1)246 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)247 fn create_collection() -> Weight {248 // Proof Size summary in bytes:249 // Measured: `245`250 // Estimated: `9174`251 // Minimum execution time: 31_198_000 picoseconds.252 Weight::from_parts(32_046_000, 9174)253 .saturating_add(RocksDbWeight::get().reads(4_u64))254 .saturating_add(RocksDbWeight::get().writes(6_u64))255 }256 /// Storage: Common CollectionById (r:1 w:1)257 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)258 /// Storage: Nonfungible TokenData (r:1 w:0)259 /// Proof: Nonfungible TokenData (max_values: None, max_size: Some(57), added: 2532, mode: MaxEncodedLen)260 /// Storage: Common DestroyedCollectionCount (r:1 w:1)261 /// Proof: Common DestroyedCollectionCount (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)262 /// Storage: Nonfungible TokensMinted (r:0 w:1)263 /// Proof: Nonfungible TokensMinted (max_values: None, max_size: Some(16), added: 2491, mode: MaxEncodedLen)264 /// Storage: Nonfungible TokensBurnt (r:0 w:1)265 /// Proof: Nonfungible TokensBurnt (max_values: None, max_size: Some(16), added: 2491, mode: MaxEncodedLen)266 /// Storage: Common AdminAmount (r:0 w:1)267 /// Proof: Common AdminAmount (max_values: None, max_size: Some(24), added: 2499, mode: MaxEncodedLen)268 /// Storage: Common CollectionProperties (r:0 w:1)269 /// Proof: Common CollectionProperties (max_values: None, max_size: Some(40992), added: 43467, mode: MaxEncodedLen)270 fn destroy_collection() -> Weight {271 // Proof Size summary in bytes:272 // Measured: `1086`273 // Estimated: `9336`274 // Minimum execution time: 48_208_000 picoseconds.275 Weight::from_parts(49_031_000, 9336)276 .saturating_add(RocksDbWeight::get().reads(3_u64))277 .saturating_add(RocksDbWeight::get().writes(6_u64))278 }279 /// Storage: Common CollectionById (r:1 w:0)280 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)281 /// Storage: Common Allowlist (r:0 w:1)282 /// Proof: Common Allowlist (max_values: None, max_size: Some(70), added: 2545, mode: MaxEncodedLen)283 fn add_to_allow_list() -> Weight {284 // Proof Size summary in bytes:285 // Measured: `967`286 // Estimated: `4325`287 // Minimum execution time: 14_852_000 picoseconds.288 Weight::from_parts(15_268_000, 4325)289 .saturating_add(RocksDbWeight::get().reads(1_u64))290 .saturating_add(RocksDbWeight::get().writes(1_u64))291 }292 /// Storage: Common CollectionById (r:1 w:0)293 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)294 /// Storage: Common Allowlist (r:0 w:1)295 /// Proof: Common Allowlist (max_values: None, max_size: Some(70), added: 2545, mode: MaxEncodedLen)296 fn remove_from_allow_list() -> Weight {297 // Proof Size summary in bytes:298 // Measured: `1000`299 // Estimated: `4325`300 // Minimum execution time: 14_595_000 picoseconds.301 Weight::from_parts(14_933_000, 4325)302 .saturating_add(RocksDbWeight::get().reads(1_u64))303 .saturating_add(RocksDbWeight::get().writes(1_u64))304 }305 /// Storage: Common CollectionById (r:1 w:1)306 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)307 fn change_collection_owner() -> Weight {308 // Proof Size summary in bytes:309 // Measured: `967`310 // Estimated: `4325`311 // Minimum execution time: 14_132_000 picoseconds.312 Weight::from_parts(14_501_000, 4325)313 .saturating_add(RocksDbWeight::get().reads(1_u64))314 .saturating_add(RocksDbWeight::get().writes(1_u64))315 }316 /// Storage: Common CollectionById (r:1 w:0)317 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)318 /// Storage: Common IsAdmin (r:1 w:1)319 /// Proof: Common IsAdmin (max_values: None, max_size: Some(70), added: 2545, mode: MaxEncodedLen)320 /// Storage: Common AdminAmount (r:1 w:1)321 /// Proof: Common AdminAmount (max_values: None, max_size: Some(24), added: 2499, mode: MaxEncodedLen)322 fn add_collection_admin() -> Weight {323 // Proof Size summary in bytes:324 // Measured: `967`325 // Estimated: `11349`326 // Minimum execution time: 17_229_000 picoseconds.327 Weight::from_parts(17_657_000, 11349)328 .saturating_add(RocksDbWeight::get().reads(3_u64))329 .saturating_add(RocksDbWeight::get().writes(2_u64))330 }331 /// Storage: Common CollectionById (r:1 w:0)332 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)333 /// Storage: Common IsAdmin (r:1 w:1)334 /// Proof: Common IsAdmin (max_values: None, max_size: Some(70), added: 2545, mode: MaxEncodedLen)335 /// Storage: Common AdminAmount (r:1 w:1)336 /// Proof: Common AdminAmount (max_values: None, max_size: Some(24), added: 2499, mode: MaxEncodedLen)337 fn remove_collection_admin() -> Weight {338 // Proof Size summary in bytes:339 // Measured: `1107`340 // Estimated: `11349`341 // Minimum execution time: 19_827_000 picoseconds.342 Weight::from_parts(20_479_000, 11349)343 .saturating_add(RocksDbWeight::get().reads(3_u64))344 .saturating_add(RocksDbWeight::get().writes(2_u64))345 }346 /// Storage: Common CollectionById (r:1 w:1)347 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)348 fn set_collection_sponsor() -> Weight {349 // Proof Size summary in bytes:350 // Measured: `967`351 // Estimated: `4325`352 // Minimum execution time: 14_049_000 picoseconds.353 Weight::from_parts(14_420_000, 4325)354 .saturating_add(RocksDbWeight::get().reads(1_u64))355 .saturating_add(RocksDbWeight::get().writes(1_u64))356 }357 /// Storage: Common CollectionById (r:1 w:1)358 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)359 fn confirm_sponsorship() -> Weight {360 // Proof Size summary in bytes:361 // Measured: `999`362 // Estimated: `4325`363 // Minimum execution time: 13_689_000 picoseconds.364 Weight::from_parts(14_044_000, 4325)365 .saturating_add(RocksDbWeight::get().reads(1_u64))366 .saturating_add(RocksDbWeight::get().writes(1_u64))367 }368 /// Storage: Common CollectionById (r:1 w:1)369 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)370 fn remove_collection_sponsor() -> Weight {371 // Proof Size summary in bytes:372 // Measured: `999`373 // Estimated: `4325`374 // Minimum execution time: 13_275_000 picoseconds.375 Weight::from_parts(13_598_000, 4325)376 .saturating_add(RocksDbWeight::get().reads(1_u64))377 .saturating_add(RocksDbWeight::get().writes(1_u64))378 }379 /// Storage: Common CollectionById (r:1 w:1)380 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)381 fn set_transfers_enabled_flag() -> Weight {382 // Proof Size summary in bytes:383 // Measured: `967`384 // Estimated: `4325`385 // Minimum execution time: 9_411_000 picoseconds.386 Weight::from_parts(9_706_000, 4325)387 .saturating_add(RocksDbWeight::get().reads(1_u64))388 .saturating_add(RocksDbWeight::get().writes(1_u64))389 }390 /// Storage: Common CollectionById (r:1 w:1)391 /// Proof: Common CollectionById (max_values: None, max_size: Some(860), added: 3335, mode: MaxEncodedLen)392 fn set_collection_limits() -> Weight {393 // Proof Size summary in bytes:394 // Measured: `967`395 // Estimated: `4325`396 // Minimum execution time: 13_864_000 picoseconds.397 Weight::from_parts(14_368_000, 4325)398 .saturating_add(RocksDbWeight::get().reads(1_u64))399 .saturating_add(RocksDbWeight::get().writes(1_u64))400 }401 /// Storage: Common CollectionProperties (r:1 w:1)402 /// Proof: Common CollectionProperties (max_values: None, max_size: Some(40992), added: 43467, mode: MaxEncodedLen)403 fn force_repair_collection() -> Weight {404 // Proof Size summary in bytes:405 // Measured: `265`406 // Estimated: `44457`407 // Minimum execution time: 7_104_000 picoseconds.408 Weight::from_parts(7_293_000, 44457)409 .saturating_add(RocksDbWeight::get().reads(1_u64))410 .saturating_add(RocksDbWeight::get().writes(1_u64))411 }412}413difftreelog
source
pallets/unique/src/weights.rs19.2 KiBsourcehistory