git.delta.rocks / unique-network / refs/commits / ddfc60f7e94f

difftreelog

source

pallets/app-promotion/src/weights.rs4.8 KiBsourcehistory
1// Template adopted from https://github.com/paritytech/substrate/blob/master/.maintain/frame-weight-template.hbs23//! Autogenerated weights for pallet_app_promotion4//!5//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev6//! DATE: 2022-08-09, STEPS: `50`, REPEAT: 80, LOW RANGE: `[]`, HIGH RANGE: `[]`7//! EXECUTION: None, WASM-EXECUTION: Compiled, CHAIN: None, DB CACHE: 102489// Executed Command:10// target/release/unique-collator11// benchmark12// pallet13// --pallet14// pallet-app-promotion15// --wasm-execution16// compiled17// --extrinsic18// *19// --template20// .maintain/frame-weight-template.hbs21// --steps=5022// --repeat=8023// --heap-pages=409624// --output=./pallets/app-promotion/src/weights.rs2526#![cfg_attr(rustfmt, rustfmt_skip)]27#![allow(unused_parens)]28#![allow(unused_imports)]29#![allow(clippy::unnecessary_cast)]3031use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};32use sp_std::marker::PhantomData;3334/// Weight functions needed for pallet_app_promotion.35pub trait WeightInfo {36	fn on_initialize() -> Weight;37	fn start_app_promotion() -> Weight;38	fn set_admin_address() -> Weight;39	fn stake() -> Weight;40	fn unstake() -> Weight;41	fn recalculate_stake() -> Weight;42}4344/// Weights for pallet_app_promotion using the Substrate node and recommended hardware.45pub struct SubstrateWeight<T>(PhantomData<T>);46impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {47	// Storage: Promotion PendingUnstake (r:1 w:0)48	// Storage: Promotion NextInterestBlock (r:1 w:0)49	fn on_initialize() -> Weight {50		(2_705_000 as Weight)51			.saturating_add(T::DbWeight::get().reads(2 as Weight))52	}53	// Storage: Promotion StartBlock (r:1 w:1)54	// Storage: Promotion NextInterestBlock (r:0 w:1)55	fn start_app_promotion() -> Weight {56		(1_436_000 as Weight)57			.saturating_add(T::DbWeight::get().reads(1 as Weight))58			.saturating_add(T::DbWeight::get().writes(2 as Weight))59	}60	// Storage: Promotion Admin (r:0 w:1)61	fn set_admin_address() -> Weight {62		(516_000 as Weight)63			.saturating_add(T::DbWeight::get().writes(1 as Weight))64	}65	// Storage: System Account (r:1 w:1)66	// Storage: Balances Locks (r:1 w:1)67	// Storage: ParachainSystem ValidationData (r:1 w:0)68	// Storage: Promotion Staked (r:1 w:1)69	// Storage: Promotion TotalStaked (r:1 w:1)70	fn stake() -> Weight {71		(10_019_000 as Weight)72			.saturating_add(T::DbWeight::get().reads(5 as Weight))73			.saturating_add(T::DbWeight::get().writes(4 as Weight))74	}75	// Storage: System Account (r:1 w:1)76	// Storage: Balances Locks (r:1 w:1)77	// Storage: ParachainSystem ValidationData (r:1 w:0)78	// Storage: Promotion Staked (r:1 w:1)79	// Storage: Promotion TotalStaked (r:1 w:1)80	fn unstake() -> Weight {81		(10_619_000 as Weight)82			.saturating_add(T::DbWeight::get().reads(5 as Weight))83			.saturating_add(T::DbWeight::get().writes(4 as Weight))84	}85	// Storage: System Account (r:2 w:0)86	// Storage: Promotion Staked (r:0 w:1)87	fn recalculate_stake() -> Weight {88		(4_932_000 as Weight)89			.saturating_add(T::DbWeight::get().reads(2 as Weight))90			.saturating_add(T::DbWeight::get().writes(1 as Weight))91	}92}9394// For backwards compatibility and tests95impl WeightInfo for () {96	// Storage: Promotion PendingUnstake (r:1 w:0)97	// Storage: Promotion NextInterestBlock (r:1 w:0)98	fn on_initialize() -> Weight {99		(2_705_000 as Weight)100			.saturating_add(RocksDbWeight::get().reads(2 as Weight))101	}102	// Storage: Promotion StartBlock (r:1 w:1)103	// Storage: Promotion NextInterestBlock (r:0 w:1)104	fn start_app_promotion() -> Weight {105		(1_436_000 as Weight)106			.saturating_add(RocksDbWeight::get().reads(1 as Weight))107			.saturating_add(RocksDbWeight::get().writes(2 as Weight))108	}109	// Storage: Promotion Admin (r:0 w:1)110	fn set_admin_address() -> Weight {111		(516_000 as Weight)112			.saturating_add(RocksDbWeight::get().writes(1 as Weight))113	}114	// Storage: System Account (r:1 w:1)115	// Storage: Balances Locks (r:1 w:1)116	// Storage: ParachainSystem ValidationData (r:1 w:0)117	// Storage: Promotion Staked (r:1 w:1)118	// Storage: Promotion TotalStaked (r:1 w:1)119	fn stake() -> Weight {120		(10_019_000 as Weight)121			.saturating_add(RocksDbWeight::get().reads(5 as Weight))122			.saturating_add(RocksDbWeight::get().writes(4 as Weight))123	}124	// Storage: System Account (r:1 w:1)125	// Storage: Balances Locks (r:1 w:1)126	// Storage: ParachainSystem ValidationData (r:1 w:0)127	// Storage: Promotion Staked (r:1 w:1)128	// Storage: Promotion TotalStaked (r:1 w:1)129	fn unstake() -> Weight {130		(10_619_000 as Weight)131			.saturating_add(RocksDbWeight::get().reads(5 as Weight))132			.saturating_add(RocksDbWeight::get().writes(4 as Weight))133	}134	// Storage: System Account (r:2 w:0)135	// Storage: Promotion Staked (r:0 w:1)136	fn recalculate_stake() -> Weight {137		(4_932_000 as Weight)138			.saturating_add(RocksDbWeight::get().reads(2 as Weight))139			.saturating_add(RocksDbWeight::get().writes(1 as Weight))140	}141}