Force base weights to be the minimum only when the intercept is negative (#12482)

* Force base weights to be the minimum only when the intercept is negative; emit minimum execution times

* Add an `assert` making sure the intercept is zero when it's supposed to be zero

* Fix template

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* ".git/.scripts/bench-bot.sh" pallet dev pallet_assets

* ".git/.scripts/bench-bot.sh" pallet dev pallet_uniques

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: command-bot <>
This commit is contained in:
Koute
2022-10-21 05:07:52 +09:00
committed by GitHub
parent 62d72f9258
commit 92d2977292
6 changed files with 314 additions and 166 deletions
+126 -73
View File
@@ -18,12 +18,12 @@
//! Autogenerated weights for pallet_uniques
//!
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
//! DATE: 2022-07-13, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]`
//! HOSTNAME: `test-bench-bot`, CPU: `Intel(R) Xeon(R) CPU @ 3.10GHz`
//! DATE: 2022-10-20, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]`
//! HOSTNAME: `bm3`, CPU: `Intel(R) Core(TM) i7-7700K CPU @ 4.20GHz`
//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024
// Executed Command:
// target/production/substrate
// /home/benchbot/cargo_target_dir/production/substrate
// benchmark
// pallet
// --steps=50
@@ -32,6 +32,7 @@
// --execution=wasm
// --wasm-execution=compiled
// --heap-pages=4096
// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/substrate/.git/.artifacts/bench.json
// --pallet=pallet_uniques
// --chain=dev
// --output=./frame/uniques/src/weights.rs
@@ -80,14 +81,16 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassAccount (r:0 w:1)
fn create() -> Weight {
Weight::from_ref_time(33_075_000 as u64)
// Minimum execution time: 32_901 nanoseconds.
Weight::from_ref_time(33_628_000 as u64)
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassAccount (r:0 w:1)
fn force_create() -> Weight {
Weight::from_ref_time(19_528_000 as u64)
// Minimum execution time: 21_633 nanoseconds.
Weight::from_ref_time(22_380_000 as u64)
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().writes(2 as u64))
}
@@ -103,13 +106,14 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
/// The range of component `m` is `[0, 1000]`.
/// The range of component `a` is `[0, 1000]`.
fn destroy(n: u32, m: u32, a: u32, ) -> Weight {
Weight::from_ref_time(0 as u64)
// Standard Error: 25_000
.saturating_add(Weight::from_ref_time(13_639_000 as u64).saturating_mul(n as u64))
// Standard Error: 25_000
.saturating_add(Weight::from_ref_time(2_393_000 as u64).saturating_mul(m as u64))
// Standard Error: 25_000
.saturating_add(Weight::from_ref_time(2_217_000 as u64).saturating_mul(a as u64))
// Minimum execution time: 2_429_508 nanoseconds.
Weight::from_ref_time(2_446_263_000 as u64)
// Standard Error: 28_236
.saturating_add(Weight::from_ref_time(8_477_090 as u64).saturating_mul(n as u64))
// Standard Error: 28_236
.saturating_add(Weight::from_ref_time(314_268 as u64).saturating_mul(m as u64))
// Standard Error: 28_236
.saturating_add(Weight::from_ref_time(249_624 as u64).saturating_mul(a as u64))
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().reads((1 as u64).saturating_mul(n as u64)))
.saturating_add(T::DbWeight::get().writes(4 as u64))
@@ -122,7 +126,8 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques CollectionMaxSupply (r:1 w:0)
// Storage: Uniques Account (r:0 w:1)
fn mint() -> Weight {
Weight::from_ref_time(42_146_000 as u64)
// Minimum execution time: 41_938 nanoseconds.
Weight::from_ref_time(42_814_000 as u64)
.saturating_add(T::DbWeight::get().reads(3 as u64))
.saturating_add(T::DbWeight::get().writes(3 as u64))
}
@@ -131,7 +136,8 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques Account (r:0 w:1)
// Storage: Uniques ItemPriceOf (r:0 w:1)
fn burn() -> Weight {
Weight::from_ref_time(42_960_000 as u64)
// Minimum execution time: 43_593 nanoseconds.
Weight::from_ref_time(44_420_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(4 as u64))
}
@@ -140,17 +146,19 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques Account (r:0 w:2)
// Storage: Uniques ItemPriceOf (r:0 w:1)
fn transfer() -> Weight {
Weight::from_ref_time(33_025_000 as u64)
// Minimum execution time: 34_037 nanoseconds.
Weight::from_ref_time(34_848_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(4 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques Asset (r:100 w:100)
// Storage: Uniques Asset (r:102 w:102)
/// The range of component `i` is `[0, 5000]`.
fn redeposit(i: u32, ) -> Weight {
Weight::from_ref_time(0 as u64)
// Standard Error: 24_000
.saturating_add(Weight::from_ref_time(15_540_000 as u64).saturating_mul(i as u64))
// Minimum execution time: 23_295 nanoseconds.
Weight::from_ref_time(23_482_000 as u64)
// Standard Error: 9_490
.saturating_add(Weight::from_ref_time(10_899_320 as u64).saturating_mul(i as u64))
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().reads((1 as u64).saturating_mul(i as u64)))
.saturating_add(T::DbWeight::get().writes(1 as u64))
@@ -159,26 +167,30 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques Asset (r:1 w:1)
// Storage: Uniques Class (r:1 w:0)
fn freeze() -> Weight {
Weight::from_ref_time(25_194_000 as u64)
// Minimum execution time: 27_005 nanoseconds.
Weight::from_ref_time(27_344_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques Asset (r:1 w:1)
// Storage: Uniques Class (r:1 w:0)
fn thaw() -> Weight {
Weight::from_ref_time(25_397_000 as u64)
// Minimum execution time: 26_815 nanoseconds.
Weight::from_ref_time(27_400_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:1)
fn freeze_collection() -> Weight {
Weight::from_ref_time(19_278_000 as u64)
// Minimum execution time: 21_988 nanoseconds.
Weight::from_ref_time(22_596_000 as u64)
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:1)
fn thaw_collection() -> Weight {
Weight::from_ref_time(19_304_000 as u64)
// Minimum execution time: 21_886 nanoseconds.
Weight::from_ref_time(22_617_000 as u64)
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
@@ -186,20 +198,23 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassAccount (r:0 w:2)
fn transfer_ownership() -> Weight {
Weight::from_ref_time(28_615_000 as u64)
// Minimum execution time: 30_241 nanoseconds.
Weight::from_ref_time(30_677_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(4 as u64))
}
// Storage: Uniques Class (r:1 w:1)
fn set_team() -> Weight {
Weight::from_ref_time(19_943_000 as u64)
// Minimum execution time: 23_011 nanoseconds.
Weight::from_ref_time(23_796_000 as u64)
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassAccount (r:0 w:1)
fn force_item_status() -> Weight {
Weight::from_ref_time(22_583_000 as u64)
// Minimum execution time: 25_739 nanoseconds.
Weight::from_ref_time(26_572_000 as u64)
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().writes(2 as u64))
}
@@ -207,7 +222,8 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques InstanceMetadataOf (r:1 w:0)
// Storage: Uniques Attribute (r:1 w:1)
fn set_attribute() -> Weight {
Weight::from_ref_time(47_520_000 as u64)
// Minimum execution time: 48_486 nanoseconds.
Weight::from_ref_time(49_029_000 as u64)
.saturating_add(T::DbWeight::get().reads(3 as u64))
.saturating_add(T::DbWeight::get().writes(2 as u64))
}
@@ -215,69 +231,79 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques InstanceMetadataOf (r:1 w:0)
// Storage: Uniques Attribute (r:1 w:1)
fn clear_attribute() -> Weight {
Weight::from_ref_time(45_316_000 as u64)
// Minimum execution time: 47_408 nanoseconds.
Weight::from_ref_time(48_753_000 as u64)
.saturating_add(T::DbWeight::get().reads(3 as u64))
.saturating_add(T::DbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques InstanceMetadataOf (r:1 w:1)
fn set_metadata() -> Weight {
Weight::from_ref_time(38_391_000 as u64)
// Minimum execution time: 40_085 nanoseconds.
Weight::from_ref_time(40_625_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques InstanceMetadataOf (r:1 w:1)
fn clear_metadata() -> Weight {
Weight::from_ref_time(38_023_000 as u64)
// Minimum execution time: 40_546 nanoseconds.
Weight::from_ref_time(41_113_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassMetadataOf (r:1 w:1)
fn set_collection_metadata() -> Weight {
Weight::from_ref_time(37_398_000 as u64)
// Minimum execution time: 39_902 nanoseconds.
Weight::from_ref_time(40_599_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:0)
// Storage: Uniques ClassMetadataOf (r:1 w:1)
fn clear_collection_metadata() -> Weight {
Weight::from_ref_time(35_621_000 as u64)
// Minimum execution time: 37_597 nanoseconds.
Weight::from_ref_time(37_964_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:0)
// Storage: Uniques Asset (r:1 w:1)
fn approve_transfer() -> Weight {
Weight::from_ref_time(25_856_000 as u64)
// Minimum execution time: 28_719 nanoseconds.
Weight::from_ref_time(29_213_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:0)
// Storage: Uniques Asset (r:1 w:1)
fn cancel_approval() -> Weight {
Weight::from_ref_time(26_098_000 as u64)
// Minimum execution time: 27_608 nanoseconds.
Weight::from_ref_time(28_096_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques OwnershipAcceptance (r:1 w:1)
fn set_accept_ownership() -> Weight {
Weight::from_ref_time(24_076_000 as u64)
// Minimum execution time: 25_568 nanoseconds.
Weight::from_ref_time(26_098_000 as u64)
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques CollectionMaxSupply (r:1 w:1)
// Storage: Uniques Class (r:1 w:0)
fn set_collection_max_supply() -> Weight {
Weight::from_ref_time(22_035_000 as u64)
// Minimum execution time: 24_521 nanoseconds.
Weight::from_ref_time(25_062_000 as u64)
.saturating_add(T::DbWeight::get().reads(2 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
// Storage: Uniques Asset (r:1 w:0)
// Storage: Uniques ItemPriceOf (r:0 w:1)
fn set_price() -> Weight {
Weight::from_ref_time(22_534_000 as u64)
// Minimum execution time: 25_337 nanoseconds.
Weight::from_ref_time(25_902_000 as u64)
.saturating_add(T::DbWeight::get().reads(1 as u64))
.saturating_add(T::DbWeight::get().writes(1 as u64))
}
@@ -286,7 +312,8 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Uniques Class (r:1 w:0)
// Storage: Uniques Account (r:0 w:2)
fn buy_item() -> Weight {
Weight::from_ref_time(45_272_000 as u64)
// Minimum execution time: 46_736 nanoseconds.
Weight::from_ref_time(47_264_000 as u64)
.saturating_add(T::DbWeight::get().reads(3 as u64))
.saturating_add(T::DbWeight::get().writes(4 as u64))
}
@@ -297,14 +324,16 @@ impl WeightInfo for () {
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassAccount (r:0 w:1)
fn create() -> Weight {
Weight::from_ref_time(33_075_000 as u64)
// Minimum execution time: 32_901 nanoseconds.
Weight::from_ref_time(33_628_000 as u64)
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassAccount (r:0 w:1)
fn force_create() -> Weight {
Weight::from_ref_time(19_528_000 as u64)
// Minimum execution time: 21_633 nanoseconds.
Weight::from_ref_time(22_380_000 as u64)
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().writes(2 as u64))
}
@@ -320,13 +349,14 @@ impl WeightInfo for () {
/// The range of component `m` is `[0, 1000]`.
/// The range of component `a` is `[0, 1000]`.
fn destroy(n: u32, m: u32, a: u32, ) -> Weight {
Weight::from_ref_time(0 as u64)
// Standard Error: 25_000
.saturating_add(Weight::from_ref_time(13_639_000 as u64).saturating_mul(n as u64))
// Standard Error: 25_000
.saturating_add(Weight::from_ref_time(2_393_000 as u64).saturating_mul(m as u64))
// Standard Error: 25_000
.saturating_add(Weight::from_ref_time(2_217_000 as u64).saturating_mul(a as u64))
// Minimum execution time: 2_429_508 nanoseconds.
Weight::from_ref_time(2_446_263_000 as u64)
// Standard Error: 28_236
.saturating_add(Weight::from_ref_time(8_477_090 as u64).saturating_mul(n as u64))
// Standard Error: 28_236
.saturating_add(Weight::from_ref_time(314_268 as u64).saturating_mul(m as u64))
// Standard Error: 28_236
.saturating_add(Weight::from_ref_time(249_624 as u64).saturating_mul(a as u64))
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().reads((1 as u64).saturating_mul(n as u64)))
.saturating_add(RocksDbWeight::get().writes(4 as u64))
@@ -339,7 +369,8 @@ impl WeightInfo for () {
// Storage: Uniques CollectionMaxSupply (r:1 w:0)
// Storage: Uniques Account (r:0 w:1)
fn mint() -> Weight {
Weight::from_ref_time(42_146_000 as u64)
// Minimum execution time: 41_938 nanoseconds.
Weight::from_ref_time(42_814_000 as u64)
.saturating_add(RocksDbWeight::get().reads(3 as u64))
.saturating_add(RocksDbWeight::get().writes(3 as u64))
}
@@ -348,7 +379,8 @@ impl WeightInfo for () {
// Storage: Uniques Account (r:0 w:1)
// Storage: Uniques ItemPriceOf (r:0 w:1)
fn burn() -> Weight {
Weight::from_ref_time(42_960_000 as u64)
// Minimum execution time: 43_593 nanoseconds.
Weight::from_ref_time(44_420_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(4 as u64))
}
@@ -357,17 +389,19 @@ impl WeightInfo for () {
// Storage: Uniques Account (r:0 w:2)
// Storage: Uniques ItemPriceOf (r:0 w:1)
fn transfer() -> Weight {
Weight::from_ref_time(33_025_000 as u64)
// Minimum execution time: 34_037 nanoseconds.
Weight::from_ref_time(34_848_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(4 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques Asset (r:100 w:100)
// Storage: Uniques Asset (r:102 w:102)
/// The range of component `i` is `[0, 5000]`.
fn redeposit(i: u32, ) -> Weight {
Weight::from_ref_time(0 as u64)
// Standard Error: 24_000
.saturating_add(Weight::from_ref_time(15_540_000 as u64).saturating_mul(i as u64))
// Minimum execution time: 23_295 nanoseconds.
Weight::from_ref_time(23_482_000 as u64)
// Standard Error: 9_490
.saturating_add(Weight::from_ref_time(10_899_320 as u64).saturating_mul(i as u64))
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().reads((1 as u64).saturating_mul(i as u64)))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
@@ -376,26 +410,30 @@ impl WeightInfo for () {
// Storage: Uniques Asset (r:1 w:1)
// Storage: Uniques Class (r:1 w:0)
fn freeze() -> Weight {
Weight::from_ref_time(25_194_000 as u64)
// Minimum execution time: 27_005 nanoseconds.
Weight::from_ref_time(27_344_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques Asset (r:1 w:1)
// Storage: Uniques Class (r:1 w:0)
fn thaw() -> Weight {
Weight::from_ref_time(25_397_000 as u64)
// Minimum execution time: 26_815 nanoseconds.
Weight::from_ref_time(27_400_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:1)
fn freeze_collection() -> Weight {
Weight::from_ref_time(19_278_000 as u64)
// Minimum execution time: 21_988 nanoseconds.
Weight::from_ref_time(22_596_000 as u64)
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:1)
fn thaw_collection() -> Weight {
Weight::from_ref_time(19_304_000 as u64)
// Minimum execution time: 21_886 nanoseconds.
Weight::from_ref_time(22_617_000 as u64)
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
@@ -403,20 +441,23 @@ impl WeightInfo for () {
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassAccount (r:0 w:2)
fn transfer_ownership() -> Weight {
Weight::from_ref_time(28_615_000 as u64)
// Minimum execution time: 30_241 nanoseconds.
Weight::from_ref_time(30_677_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(4 as u64))
}
// Storage: Uniques Class (r:1 w:1)
fn set_team() -> Weight {
Weight::from_ref_time(19_943_000 as u64)
// Minimum execution time: 23_011 nanoseconds.
Weight::from_ref_time(23_796_000 as u64)
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassAccount (r:0 w:1)
fn force_item_status() -> Weight {
Weight::from_ref_time(22_583_000 as u64)
// Minimum execution time: 25_739 nanoseconds.
Weight::from_ref_time(26_572_000 as u64)
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().writes(2 as u64))
}
@@ -424,7 +465,8 @@ impl WeightInfo for () {
// Storage: Uniques InstanceMetadataOf (r:1 w:0)
// Storage: Uniques Attribute (r:1 w:1)
fn set_attribute() -> Weight {
Weight::from_ref_time(47_520_000 as u64)
// Minimum execution time: 48_486 nanoseconds.
Weight::from_ref_time(49_029_000 as u64)
.saturating_add(RocksDbWeight::get().reads(3 as u64))
.saturating_add(RocksDbWeight::get().writes(2 as u64))
}
@@ -432,69 +474,79 @@ impl WeightInfo for () {
// Storage: Uniques InstanceMetadataOf (r:1 w:0)
// Storage: Uniques Attribute (r:1 w:1)
fn clear_attribute() -> Weight {
Weight::from_ref_time(45_316_000 as u64)
// Minimum execution time: 47_408 nanoseconds.
Weight::from_ref_time(48_753_000 as u64)
.saturating_add(RocksDbWeight::get().reads(3 as u64))
.saturating_add(RocksDbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques InstanceMetadataOf (r:1 w:1)
fn set_metadata() -> Weight {
Weight::from_ref_time(38_391_000 as u64)
// Minimum execution time: 40_085 nanoseconds.
Weight::from_ref_time(40_625_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques InstanceMetadataOf (r:1 w:1)
fn clear_metadata() -> Weight {
Weight::from_ref_time(38_023_000 as u64)
// Minimum execution time: 40_546 nanoseconds.
Weight::from_ref_time(41_113_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:1)
// Storage: Uniques ClassMetadataOf (r:1 w:1)
fn set_collection_metadata() -> Weight {
Weight::from_ref_time(37_398_000 as u64)
// Minimum execution time: 39_902 nanoseconds.
Weight::from_ref_time(40_599_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(2 as u64))
}
// Storage: Uniques Class (r:1 w:0)
// Storage: Uniques ClassMetadataOf (r:1 w:1)
fn clear_collection_metadata() -> Weight {
Weight::from_ref_time(35_621_000 as u64)
// Minimum execution time: 37_597 nanoseconds.
Weight::from_ref_time(37_964_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:0)
// Storage: Uniques Asset (r:1 w:1)
fn approve_transfer() -> Weight {
Weight::from_ref_time(25_856_000 as u64)
// Minimum execution time: 28_719 nanoseconds.
Weight::from_ref_time(29_213_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques Class (r:1 w:0)
// Storage: Uniques Asset (r:1 w:1)
fn cancel_approval() -> Weight {
Weight::from_ref_time(26_098_000 as u64)
// Minimum execution time: 27_608 nanoseconds.
Weight::from_ref_time(28_096_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques OwnershipAcceptance (r:1 w:1)
fn set_accept_ownership() -> Weight {
Weight::from_ref_time(24_076_000 as u64)
// Minimum execution time: 25_568 nanoseconds.
Weight::from_ref_time(26_098_000 as u64)
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques CollectionMaxSupply (r:1 w:1)
// Storage: Uniques Class (r:1 w:0)
fn set_collection_max_supply() -> Weight {
Weight::from_ref_time(22_035_000 as u64)
// Minimum execution time: 24_521 nanoseconds.
Weight::from_ref_time(25_062_000 as u64)
.saturating_add(RocksDbWeight::get().reads(2 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
// Storage: Uniques Asset (r:1 w:0)
// Storage: Uniques ItemPriceOf (r:0 w:1)
fn set_price() -> Weight {
Weight::from_ref_time(22_534_000 as u64)
// Minimum execution time: 25_337 nanoseconds.
Weight::from_ref_time(25_902_000 as u64)
.saturating_add(RocksDbWeight::get().reads(1 as u64))
.saturating_add(RocksDbWeight::get().writes(1 as u64))
}
@@ -503,7 +555,8 @@ impl WeightInfo for () {
// Storage: Uniques Class (r:1 w:0)
// Storage: Uniques Account (r:0 w:2)
fn buy_item() -> Weight {
Weight::from_ref_time(45_272_000 as u64)
// Minimum execution time: 46_736 nanoseconds.
Weight::from_ref_time(47_264_000 as u64)
.saturating_add(RocksDbWeight::get().reads(3 as u64))
.saturating_add(RocksDbWeight::get().writes(4 as u64))
}