Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Duniter v2S
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
nodes
rust
Duniter v2S
Commits
ea9f4a81
Commit
ea9f4a81
authored
3 years ago
by
Éloïs
Browse files
Options
Downloads
Patches
Plain Diff
feat(weights): use our benchmarks for frame_system
parent
dd1828ea
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
runtime/common/src/pallets_config.rs
+1
-1
1 addition, 1 deletion
runtime/common/src/pallets_config.rs
runtime/common/src/weights.rs
+1
-0
1 addition, 0 deletions
runtime/common/src/weights.rs
runtime/common/src/weights/frame_system.rs
+84
-0
84 additions, 0 deletions
runtime/common/src/weights/frame_system.rs
with
86 additions
and
1 deletion
runtime/common/src/pallets_config.rs
+
1
−
1
View file @
ea9f4a81
...
...
@@ -69,7 +69,7 @@ macro_rules! pallets_config {
/// The data to be stored in an account.
type
AccountData
=
pallet_duniter_account
::
AccountData
<
Balance
>
;
/// Weight information for the extrinsics of this pallet.
type
SystemWeightInfo
=
frame_system
::
weights
::
Substrate
Weight
<
Runtime
>
;
type
SystemWeightInfo
=
common_runtime
::
weights
::
frame_system
::
Weight
Info
<
Runtime
>
;
/// This is used as an identifier of the chain. 42 is the generic substrate prefix.
type
SS58Prefix
=
SS58Prefix
;
/// The set code logic, just the default since we're not a parachain.
...
...
This diff is collapsed.
Click to expand it.
runtime/common/src/weights.rs
+
1
−
0
View file @
ea9f4a81
...
...
@@ -14,6 +14,7 @@
// You should have received a copy of the GNU Affero General Public License
// along with Substrate-Libre-Currency. If not, see <https://www.gnu.org/licenses/>.
pub
mod
frame_system
;
pub
mod
pallet_babe
;
pub
mod
pallet_balances
;
pub
mod
pallet_grandpa
;
This diff is collapsed.
Click to expand it.
runtime/common/src/weights/frame_system.rs
0 → 100644
+
84
−
0
View file @
ea9f4a81
// Copyright 2021-2022 Axiom-Team
//
// This file is part of Duniter-v2S.
//
// Duniter-v2S is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as published by
// the Free Software Foundation, version 3 of the License.
//
// Duniter-v2S 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 Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>.
//! Autogenerated weights for `frame_system`
//!
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
//! DATE: 2022-06-11, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]`
//! EXECUTION: Some(Wasm), WASM-EXECUTION: Interpreted, CHAIN: Some("dev"), DB CACHE: 1024
// Executed Command:
// ./duniter
// benchmark
// --chain=dev
// --steps=50
// --repeat=20
// --pallet=frame_system
// --extrinsic=*
// --execution=wasm
// --wasm-execution=interpreted-i-know-what-i-do
// --heap-pages=4096
// --output=.
#![cfg_attr(rustfmt,
rustfmt_skip)]
#![allow(unused_parens)]
#![allow(unused_imports)]
use
frame_support
::{
traits
::
Get
,
weights
::
Weight
};
use
sp_std
::
marker
::
PhantomData
;
/// Weight functions for `frame_system`.
pub
struct
WeightInfo
<
T
>
(
PhantomData
<
T
>
);
impl
<
T
:
frame_system
::
Config
>
frame_system
::
WeightInfo
for
WeightInfo
<
T
>
{
fn
remark
(
b
:
u32
,
)
->
Weight
{
(
56_698_000
as
Weight
)
// Standard Error: 0
.saturating_add
((
238_000
as
Weight
)
.saturating_mul
(
b
as
Weight
))
}
fn
remark_with_event
(
b
:
u32
,
)
->
Weight
{
(
1_830_806_000
as
Weight
)
// Standard Error: 0
.saturating_add
((
254_000
as
Weight
)
.saturating_mul
(
b
as
Weight
))
}
// Storage: System Digest (r:1 w:1)
// Storage: unknown [0x3a686561707061676573] (r:0 w:1)
fn
set_heap_pages
()
->
Weight
{
(
74_351_000
as
Weight
)
.saturating_add
(
T
::
DbWeight
::
get
()
.reads
(
1
as
Weight
))
.saturating_add
(
T
::
DbWeight
::
get
()
.writes
(
2
as
Weight
))
}
// Storage: Skipped Metadata (r:0 w:0)
fn
set_storage
(
i
:
u32
,
)
->
Weight
{
(
0
as
Weight
)
// Standard Error: 26_000
.saturating_add
((
38_883_000
as
Weight
)
.saturating_mul
(
i
as
Weight
))
.saturating_add
(
T
::
DbWeight
::
get
()
.writes
((
1
as
Weight
)
.saturating_mul
(
i
as
Weight
)))
}
// Storage: Skipped Metadata (r:0 w:0)
fn
kill_storage
(
i
:
u32
,
)
->
Weight
{
(
14_386_000
as
Weight
)
// Standard Error: 16_000
.saturating_add
((
18_658_000
as
Weight
)
.saturating_mul
(
i
as
Weight
))
.saturating_add
(
T
::
DbWeight
::
get
()
.writes
((
1
as
Weight
)
.saturating_mul
(
i
as
Weight
)))
}
// Storage: Skipped Metadata (r:0 w:0)
fn
kill_prefix
(
p
:
u32
,
)
->
Weight
{
(
0
as
Weight
)
// Standard Error: 8_000
.saturating_add
((
6_532_000
as
Weight
)
.saturating_mul
(
p
as
Weight
))
.saturating_add
(
T
::
DbWeight
::
get
()
.writes
((
1
as
Weight
)
.saturating_mul
(
p
as
Weight
)))
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment