Bastian Köcher
e3e651f72c
Happy new year ( #7814 )
...
* Happy new year
Updates the copyright years and fixes wrong license headers.
* Fix the template
* Split HEADER into HEADER-APACHE & HEADER-GPL
2021-01-04 09:03:13 +00:00
Shawn Tabrizi
36a684a14b
Support Multiple Instances with Benchmarks ( #7669 )
...
* Support multiple instances with benchmarks
* fix tests
* Apply suggestions from code review
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* docs
* fix output
* Update lib.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2020-12-11 09:20:10 +00:00
Gavin Wood
26465eadaa
Introduce cancel_proposal to rid us of those pesky proposals ( #7111 )
...
* Introduce `cancel_proposal`
Also fix proposal weight.
* Support proposal cancellation from runtime.
* Fixes
* Fixes
* Fixes
* Fixes
* Fixes
* Fixes
* Fixes
* Fix benchmarks
* fix benchmark
* whitelisted caller weights
* fix build
* Fixes
* Fixes
* Fixes
* Fixes
* Update frame/democracy/src/lib.rs
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
* Fixes
* Fixes
* Fixes
* Fixes
* Fixes
* doc updates
* new weights
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2020-09-24 21:33:02 +00:00
Shawn Tabrizi
4462f7150d
Enable verification logic when executing benchmarks ( #6929 )
...
* Add `--verify` flag to benchmark execution
* make it so `--verify` can be used for getting the actual benchmarks
* undo manual testing
* oops
* use benchmark config struct
* verify is default on, docs update
* remove clone
* improve formatting
* fix test
* bump impl for ci
2020-08-24 15:24:00 +02:00
Shawn Tabrizi
481ad884d6
Dynamic Benchmarking DB Whitelist ( #6815 )
...
* Add `get_whitelist` api
* add whitelisted caller
* Whitelist caller
* remove caller 0
* initial piping of origin (not actual value yet)
* remove attempt to pass origin around
* Add whitelist for `DidUpdate` storage on `pallet_timestamp`
* fix traits
* only add to whitelist if !contains
* PassBy not implemented error
* Whitelist read/writes explicitly per key
* update docs
* reduce trait constraint
* copy pasta
* Apply suggestions from code review
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
* rename functions @apopiak
* missed some renaming
* enable doc tests
* Update docs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
2020-08-19 16:15:50 +00:00
Shawn Tabrizi
dd6ef0a3a5
Improve Benchmark Writer: Remove Unused Components, Remove Multiply by Zero, Files Split by Pallet ( #6785 )
...
* initial improvements
* better file management, ignore unused components
* Output warning when components unused
* update comment
* Write even when base weight is zero
* remove unwrap where possible
* Dont sort components to dedup
* undo delete
* improve clarity of unused components
* remove unused dep
* Update Process.json
2020-08-03 12:41:54 +00:00
Shawn Tabrizi
01d0d13fad
Update Balances Pallet to use WeightInfo ( #6610 )
...
* Update balance benchmarks
* Update weight functions
* Remove user component
* make componentless
* Add support for `#[extra]` tag on benchmarks
* Update balances completely
* Apply suggestions from code review
Co-authored-by: Alexander Theißen <alex.theissen@me.com >
* Fix some tests
* Maybe fix to test. Need approval from @tomusdrw this is okay
* Make test better
* keep weights conservative
* Update macro for merge master
* Add headers
* Apply suggestions from code review
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
Co-authored-by: Alexander Theißen <alex.theissen@me.com >
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
2020-07-30 17:08:23 +02:00
Guillaume Thiolliere
1eeb4b0e3f
benchmarks! macro: factorize instance usage. ( #6750 )
...
* factorize benchmark!
* fix types
* fix types
2020-07-29 14:33:54 +02:00
Shawn Tabrizi
935ee6f545
Add DB Read/Write Tracking to Benchmarking Pipeline ( #6386 )
...
* initial mockup
* add and wipe
* track writes
* start to add to pipeline
* return all reads/writes
* Log reads and writes from bench db
* causes panic
* Allow multiple commits
* commit before ending benchmark
* doesn't work???
* fix
* Update lib.rs
* switch to struct for `BenchmarkResults`
* add to output
* fix test
* line width
* @kianenigma review
* Add Whitelist to DB Tracking in Benchmarks Pipeline (#6405 )
* hardcoded whitelist
* Add whitelist to pipeline
* Remove whitelist pipeline from CLI, add to runtime
* clean-up unused db initialized whitelist
* Add regression analysis to DB Tracking (#6475 )
* Add selector
* add tests
* debug formatter for easy formula
* Update client/db/src/bench.rs
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
Co-authored-by: arkpar <arkady.paronyan@gmail.com >
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
2020-06-24 21:03:55 +02:00
Benjamin Kampmann
be8c96adec
Relax substrate licensing scheme ( #5947 )
2020-05-15 13:21:56 +02:00
Marcio Diaz
7cc095ec9f
Add verify block to benchmark tests ( #5551 )
...
* Add verify block to benchmarks macro.
* Update all benchmarks.
* Add tests, add params.
* Should panic.
* ups, add closures
* Update tests.rs
* update macro syntax
* Revert benchmark syntax change
* verify only in tests
* Update tests.rs
* Uncomment staking
* Fix tests for benchmark instance
* Add docs
* Update frame/benchmarking/src/lib.rs
* add trace logs to benchmarks
* Verify returns closure
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2020-04-08 12:55:06 +02:00
Gavin Wood
b472d60a52
Batch benchmarks together with * notation. ( #5436 )
...
* Batch benchmarks together with `*` notation.
* Fix short structopt conflict
* Return error if `batches` is empty
* Move fast benchmarks macro into `frame_benchmarking` (#5445 )
* Move macro into `frame_benchmarking`
* Update docs
* Extra line
* Return error if `batches` is empty
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2020-03-31 15:20:09 +02:00
Marcio Diaz
22e23b0103
Benchmark Collective Pallet ( #5343 )
...
* Init
* Fix execute.
* Duplicate macro for instances temporarilly
* Add propose.
* Add vote, close.
* Propose from own module
* Add old members to set_members.
* Add previous proposals to propose.
* Compress a bit the macro.
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2020-03-24 18:06:29 +01:00
Marcio Diaz
f39e705523
Fix benchmarks! macro for non dispatchable code ( #5100 )
...
* Init allowing non dispatchable closure to be benchmarked.
* Remove example, add it in timestamp
* Fix nits.
* Move test to example.
* Update frame/example/src/lib.rs
Co-Authored-By: Shawn Tabrizi <shawntabrizi@gmail.com >
* Update frame/example/src/lib.rs
Co-Authored-By: Shawn Tabrizi <shawntabrizi@gmail.com >
* Apply review suggestion: move test to benchmarking crate.
* Update frame/benchmarking/src/lib.rs
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* Remove unused imports.
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Benjamin Kampmann <ben.kampmann@googlemail.com >
2020-03-04 10:13:14 +01:00
Marcio Diaz
347b5d641c
Add options to overwrite range bounds in benchmark command. ( #5072 )
...
* Add --mins --maxs to benchmark command.
* Apply review suggestions.
2020-02-28 15:40:42 +01:00
Marcio Diaz
d39605d9cd
Propagate DispatchError for benchmarks. ( #5075 )
...
* Propagate DispatchError for benchmarks.
* Apply review suggestions.
* Use RuntimeString.
* fix expect
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2020-02-28 12:05:27 +01:00
Marcio Diaz
d024364503
Add steps setting to benchmarking CLI ( #5033 )
...
* Add steps setting to CLI, use max value to hit worst case.
* Bump impl_version.
* Apply review suggestion.
2020-02-25 15:51:25 +01:00
Shawn Tabrizi
ad90ab7ec9
Add storage root recalculation time to benchmarks ( #5035 )
2020-02-24 18:07:38 +01:00
Gavin Wood
f5176ba377
Benchmark macro ( #4962 )
...
* MAcro benchamrks
* Iterative macro
* Tidying it up.
* Macro improvements
* Bits..
* Last benchmaks.
* Repo benchmark macro
* Add the possibility of evaluating arbitrary expressions in a
benchmaark
* Better syntax and docs
* Update `BenchmarkParameter`
* Add `ignore` to sudo-code in docs
* First try of timestamp implementation.
* Fix macro docs, remove warnings.
* Use macro in balances pallet.
* Make some space in frame benchmarking.
* Remove _benchmarks_seed variable.
* Bump impl_version.
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
Co-authored-by: Marcio Diaz <marcio@parity.io >
2020-02-20 17:20:16 +01:00