Distance pallet benchmark
Merge request reports
Activity
assigned to @bgallois
- Resolved by Benjamin Gallois
J'avais commencé le benchmark de distance mais n'ai plus avancé depuis un moment, sur la branche
tuxmain/benchmark-distance
que je viens de pousser. Comme il y a déjà le mock et certaines fonctions tu peux reprendre le code si c'est utile.
added RN-runtime label
changed milestone to %runtime-700
- Resolved by Benjamin Gallois
- Added benchmarks for the distance pallet (for both testing and runtime).
- Included our weights in the runtime.
- Calculated provisional weights using my personal machine (to be recomputed on the target machine).
Note:
One technical point is the author check at https://git.duniter.org/nodes/rust/duniter-v2s/-/blob/master/pallets/distance/src/lib.rs#L228 that is implemented at https://github.com/paritytech/substrate/blob/033d4e86cc7eff0066cd376b9375f815761d653c/frame/authorship/src/lib.rs#L80-L93 and then at https://github.com/paritytech/substrate/blob/033d4e86cc7eff0066cd376b9375f815761d653c/frame/babe/src/lib.rs#L493-L507. Therefore, the complexity of this check depends on the number of items and the ordering of the items.Based on my research and testing, in our configuration, it seems that only BABE and GRANDPA use the Digest system. The number of items seems to be always one, or the BABE digest is the first when the extrinsic call is performed. Therefore, I have kept the number at one during the benchmark and have not added another complexity parameter.
requested review from @HugoTrentesaux
Did not really understand this Digest system. I mark this MR as "approved" but maybe @tuxmain would like to review more carefully.
requested review from @tuxmain and removed review request for @HugoTrentesaux
added 17 commits
-
45b62973...b793b455 - 11 commits from branch
nodes/rust:master
- 1d5cd029 - add pallet distance benchmarks
- 0adcd132 - add benchmarks for runtime
- fc138f7c - add benchmarks for test
- 606e617a - use our weights
- dbb186db - fix runtime-benchmarks feature for testing
- 6cec1103 - add digest decoding complexity
Toggle commit list-
45b62973...b793b455 - 11 commits from branch
mentioned in commit 89c4fdb9
mentioned in issue #126 (closed)