-
Notifications
You must be signed in to change notification settings - Fork 839
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EPMB Benchmarking: Make it work in CI #7714
Comments
can these values
be a default ones (regardless of env variables) if we build with --feature=runtime-benchmarks? |
Fixing the command bot Fixing the CI |
They slow down the chain spec generation for all pallets if they are. I am in agreement with @re-gius that if anything, let's just allow additional args/envs to be set in cmd bot. |
I can work on the command bot and keep you updated here |
Working on it in #7747 |
@mordamax let's discuss the approach here: some comments I received:
|
TLDR - changing cmd.yml is tricky, and we should do this only if it really necessary for majority use-cases, for more narrow cases it's better to perform changes in cmd.yml - which you can test right away from your original PR + cover with unit-tests to make sure you're propagating --flags correctly and not affecting other logic (see test_cmd.py) How to test cmd.yml changes:
also small note from me: LOG='runtime::multiblock-election=info,runtime::staking=info' don't add quotes if possible, as they are restricted by regex, as well as Re logs, if they are typical for this runtime, could be added to https://github.com/paritytech/polkadot-sdk/blob/master/.github/workflows/runtimes-matrix.json adding it as arguments can more complicate the usage of cmd bot, as many people use it for many use-cases that was ~95% of what i told in DM, sharing here :) |
At the moment we cannot run the benchmarks for all of the multi-block election pallets in the CI or bot.
These pallets are:
pallet_election_provider_multi_block
pallet_election_provider_multi_block::signed
pallet_election_provider_multi_block::unsigned
pallet_election_provider_multi_block::verifier
At the moment, these pallets only exist in the substrate-node runtime.
The reasons we cannot benchmark them in CI are:
--heap-pages 65000
--default-pov-mode measured
VALIDATORS=1000 NOMINATORS=25000
. These will in turn create a large enough genesis config in the substrate node to do a full size election, and properly benchmark it.feature = "staking-playground"
is also set in thestaging-node-cli
. Ref. We can remove thisif
statement if need be and always use these environment variables.For the time being, I have circumvented this via:
polkadot-sdk/.github/workflows/tests.yml
Line 38 in 86e069b
And for actual weight generation, I have to use a manual connection to the reference hardware machine to get the updated weights, which is rather slow.
Moreover, it is a sloppy hack from my side and should be fixed.
Fixing the command bot
The easier path is to enable the command bot to be able to support this. It would need to:
Fixing the CI
I am less sure if this is feasible. The environment variables that I am talking about here will slow down the weight generation for all pallets. We should only attempt this IFF either:
For reference, here is how I currently benchmark the said pallets
Note that we can use
--default-pov-mode measured
to the code.The text was updated successfully, but these errors were encountered: