Skip to content
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

PoC for short benchmarking in CI with frame-omni-bencher #298

Closed
wants to merge 3 commits into from

Conversation

bkontur
Copy link
Contributor

@bkontur bkontur commented Apr 30, 2024

Closes: #197

  • bump sp-genesis-builder and add get_preset feature to the runtimes
    [2024-04-30T11:14:22Z WARN  frame_omni_bencher] The FRAME omni-bencher is not yet battle tested - double check the results.
    [2024-04-30T11:14:22Z INFO  frame_benchmarking_cli::pallet::command] Loading WASM from ./target/production/wbuild/asset-hub-kusama-runtime/asset_hub_kusama_runtime.compact.compressed.wasm
    Error: Input("Could not call runtime API to build the genesis spec: Other: Exported method GenesisBuilder_get_preset is not found")
    
  • find out how to use frame-omni-bencher - GHA? or download released binary? or whatever?
  • Does not require a CHANGELOG entry

.github/workflows/test.yml Outdated Show resolved Hide resolved
bkontur and others added 2 commits May 2, 2024 12:41
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@bkontur bkontur closed this Jul 11, 2024
@bkontur bkontur deleted the bko-short-benchmarks branch July 11, 2024 15:44
fellowship-merge-bot bot pushed a commit that referenced this pull request Jul 24, 2024
…pec-builder` stuff to `get_preset` (#379)

This PR introduces a new CI pipeline for checking and running runtime
benchmarks as part of the test pipelines. This means we will now know if
any changes break the benchmarks.

The pipeline is based on downloading `frame-omni-bencher` (building it
in-place is too expensive for every matrix run) and running it with a
minimal setup: `--steps 2 --repeat 1`.

Another part of this PR splits the default genesis setups from
`chain-spec-generator` and moves them to the
`sp_genesis_builder::GenesisBuilder::get_preset` runtime API
implementation for every runtime, which is required by
`frame-omni-bencher`.


Closes: #197
Relates to: #298
Relates to: #324

<!-- Remember that you can run `/merge` to enable auto-merge in the PR
-->

<!-- Remember to modify the changelog. If you don't need to modify it,
you can check the following box.
Instead, if you have already modified it, simply delete the following
line. -->

- [X] Does not require a CHANGELOG entry

## Future works

When [this issue](paritytech/polkadot-sdk#5083)
is fixed, I will rewrite
[weight-generation.md](https://github.com/polkadot-fellows/runtimes/blob/main/docs/weight-generation.md).
The new version will be significantly simplified, with instructions to
simply download `frame-omni-bencher`, build the runtime WASM, and run
it—no other steps will be necessary.

```
2024-07-18 14:45:51 Using the chain spec instead of the runtime to generate the genesis state is deprecated. Please remove the `--chain`/`--dev`/`--local` argument, point `--runtime` to your runtime blob and set `--genesis-builder=runtime`. This warning may become a hard error any time after December 2024.    
```

---------

Co-authored-by: Bastian Köcher <git@kchr.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[CI] Add pipeline for checking benchmarks
2 participants