Record encoding concurrency - #2536
Merged
Merged
Conversation
…change early abort mechanism that will be taken advantage of later
… table generators for greater parallelism
nazar-pc
requested review from
NingLin-P,
rg3l3dr,
shamil-gadelshin and
vedhavyas
as code owners
February 19, 2024 01:53
nazar-pc
enabled auto-merge
February 19, 2024 01:53
EmilFattakhov
approved these changes
Feb 19, 2024
EmilFattakhov
left a comment
Member
There was a problem hiding this comment.
People are gonna love this, will get it added to the docs!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This leverages scalability introduced in #2526 and allows to improve CPU usage and plotting speed as the result.
The idea here is that there are both parallel and sequential parts of the table generation, so by generating a few tables at a time we can overlap sequential parts with parallel parts and improve CPU utilization. While generating tables for all records requires a lot of RAM, generating tables for only a few records at a time is not too bad.
--record-encoding-concurrencyoption was added to override default behavior (one record for each 2 cores, but not more than 8 in parallel, which according to my testing with P-cores, E-cores and P+E cores seems to result in peak performance). To get old behavior and lower RAM usage--record-encoding-concurrency 1can be used.Code contributor checklist: