239 lines
9.6 KiB
Rust
239 lines
9.6 KiB
Rust
// This file is part of Ghost Network.
|
|
|
|
// Ghost Network is free software: you can redistribute it and/or modify
|
|
// it under the terms of the GNU General Public License as published by
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
// (at your option) any later version.
|
|
|
|
// Ghost Network is distributed in the hope that it will be useful,
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
// GNU General Public License for more details.
|
|
|
|
// You should have received a copy of the GNU General Public License
|
|
// along with Ghost Network. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
//! Autogenerated weights for `ghost_networks`
|
|
//!
|
|
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0
|
|
//! DATE: 2026-02-26, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
|
|
//! WORST CASE MAP SIZE: `1000000`
|
|
//! HOSTNAME: `ghostown`, CPU: `Intel(R) Core(TM) i3-2310M CPU @ 2.10GHz`
|
|
//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("casper-dev")`, DB CACHE: 1024
|
|
|
|
// Executed Command:
|
|
// ./target/release/ghost
|
|
// benchmark
|
|
// pallet
|
|
// --chain=casper-dev
|
|
// --steps=50
|
|
// --repeat=20
|
|
// --pallet=ghost_networks
|
|
// --extrinsic=*
|
|
// --heap-pages=4096
|
|
// --header=./file_header.txt
|
|
// --output=./runtime/casper/src/weights/ghost_networks.rs
|
|
|
|
#![cfg_attr(rustfmt, rustfmt_skip)]
|
|
#![allow(unused_parens)]
|
|
#![allow(unused_imports)]
|
|
|
|
use frame_support::{
|
|
traits::Get,
|
|
weights::{
|
|
Weight, constants::RocksDbWeight
|
|
}
|
|
};
|
|
use sp_std::marker::PhantomData;
|
|
|
|
/// Weight functions needed for ghost_networks
|
|
pub trait WeightInfo {
|
|
fn register_network(i: u32, j: u32, k: u32, ) -> Weight;
|
|
fn update_network_name(n: u32, ) -> Weight;
|
|
fn update_network_endpoint(n: u32, ) -> Weight;
|
|
fn update_network_finality_delay() -> Weight;
|
|
fn update_network_rate_limit_delay() -> Weight;
|
|
fn update_network_block_distance() -> Weight;
|
|
fn update_network_type() -> Weight;
|
|
fn update_network_gatekeeper() -> Weight;
|
|
fn update_network_topic_name() -> Weight;
|
|
fn update_incoming_network_fee() -> Weight;
|
|
fn update_outgoing_network_fee() -> Weight;
|
|
fn update_avg_block_speed() -> Weight;
|
|
fn remove_network() -> Weight;
|
|
}
|
|
|
|
impl WeightInfo for () {
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
/// Storage: `GhostNetworks::NetworkIndexes` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::NetworkIndexes` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
|
|
/// The range of component `i` is `[1, 20]`.
|
|
/// The range of component `j` is `[1, 150]`.
|
|
/// The range of component `k` is `[1, 20]`.
|
|
fn register_network(_i: u32, j: u32, k: u32, ) -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `109`
|
|
// Estimated: `3574`
|
|
// Minimum execution time: 48_419_000 picoseconds.
|
|
Weight::from_parts(35_655_823, 0)
|
|
.saturating_add(Weight::from_parts(0, 3574))
|
|
// Standard Error: 1_212
|
|
.saturating_add(Weight::from_parts(96_762, 0).saturating_mul(j.into()))
|
|
// Standard Error: 9_235
|
|
.saturating_add(Weight::from_parts(1_460_410, 0).saturating_mul(k.into()))
|
|
.saturating_add(RocksDbWeight::get().reads(2))
|
|
.saturating_add(RocksDbWeight::get().writes(2))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
/// The range of component `n` is `[1, 20]`.
|
|
fn update_network_name(_n: u32, ) -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 48_422_000 picoseconds.
|
|
Weight::from_parts(49_987_541, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
/// The range of component `n` is `[1, 150]`.
|
|
fn update_network_endpoint(n: u32, ) -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 48_651_000 picoseconds.
|
|
Weight::from_parts(50_776_912, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
// Standard Error: 1_062
|
|
.saturating_add(Weight::from_parts(838, 0).saturating_mul(n.into()))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_network_finality_delay() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 48_080_000 picoseconds.
|
|
Weight::from_parts(51_781_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_network_rate_limit_delay() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 47_950_000 picoseconds.
|
|
Weight::from_parts(48_925_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_network_block_distance() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 48_324_000 picoseconds.
|
|
Weight::from_parts(50_801_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_network_type() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 46_962_000 picoseconds.
|
|
Weight::from_parts(47_729_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_network_gatekeeper() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 48_728_000 picoseconds.
|
|
Weight::from_parts(53_054_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_network_topic_name() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 48_632_000 picoseconds.
|
|
Weight::from_parts(49_954_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_incoming_network_fee() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 47_660_000 picoseconds.
|
|
Weight::from_parts(53_763_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_outgoing_network_fee() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 48_164_000 picoseconds.
|
|
Weight::from_parts(48_953_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn update_avg_block_speed() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 47_789_000 picoseconds.
|
|
Weight::from_parts(52_131_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(1))
|
|
.saturating_add(RocksDbWeight::get().writes(1))
|
|
}
|
|
/// Storage: `GhostNetworks::NetworkIndexes` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::NetworkIndexes` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
|
|
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
|
|
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
|
|
fn remove_network() -> Weight {
|
|
// Proof Size summary in bytes:
|
|
// Measured: `339`
|
|
// Estimated: `3804`
|
|
// Minimum execution time: 49_720_000 picoseconds.
|
|
Weight::from_parts(50_526_000, 0)
|
|
.saturating_add(Weight::from_parts(0, 3804))
|
|
.saturating_add(RocksDbWeight::get().reads(2))
|
|
.saturating_add(RocksDbWeight::get().writes(2))
|
|
}
|
|
}
|