-
Notifications
You must be signed in to change notification settings - Fork 835
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
Benchmark network stack CPU usage #5220
Comments
We had a discussion with @AndreiEres & @lexnv, and to follow up, I'd like to summarize the understanding of the issue from the networking team perspective:
It would be really helpful if you could implement such benchmarks, as we are going to need them anyway |
There is a disadvantage here, currently the subsystem-bench are a good tool for estimating the load of subsystem on real networks, it allows you to configure high level properties of the network(num_validators, num_cores, num_parachains, num_candidates to validate) and it generate the equivalent messages a node would have to process. Currently, the oversimplified setup is:
What I understand you are suggesting implementing a pipeline like: I think that's a good first step and it allows you for comparison between Litep2p and Libp2p backend, but it doesn't cover the part where you benchmark as much as possible from the node running all together. My suggestion would be, when we implement this to also have in mind the longer pipeline I suggested above, so that we would still be able to glue everything together at some point in the future. |
+1 on what @alexggh said above.
The subsystem benchmarks will report the networking stack usage as part of the tests we already have. So you can compare the |
Sounds like a plan! Thanks for the clarifications! 🙏 Indeed the subsystem benchmark brings a good improvement from the current state. We can handle the protocol-specific benchmarks as part of the networking team, since we'd need to know if new changes impact the performance of the lower-level components and make informed decisions about optimizations |
Sorry for being late to the party, and sorry for the delay in providing the collected information. Here is my understanding of the current situation. In Polkadot, we are replacing Thus, the actual work can be divided into two different tasks that are not connected to each other and can be implemented independently:
Using the analogy of testing, the first benchmark is the integration test, while the second consists of several unit tests. How do you guys find this approach? What should I change or add? |
# Description Implemented benchmarks for Notifications and RequestResponse protocols with libp2p implementation. These benchmarks allow us to monitor regressions and implement fixes before they are observed in real chain. In the future, they can be used for targeted optimizations of litep2p compared to libp2p. Part of #5220 Next steps: - Add benchmarks for litep2p implementation - Optimize load to get better results - Add benchmarks to CI to catch regressions ## Integration Benchmarks don't affect downstream projects. --------- Co-authored-by: alvicsam <[email protected]> Co-authored-by: GitHub Action <[email protected]>
Currently the only way to catch network stack performance regressions or compare litep2p with libp2p is to actually run the nodes in a network and look at the CPU usage metrics of the networking tasks.
Implementing such a network stack performance benchmark (perhaps as part of the subsystem benchmarks) would provide the following benefits:
CC @AndreiEres @dmitry-markin
The text was updated successfully, but these errors were encountered: