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

Improve dictionary compression speed #4170

Merged
merged 3 commits into from
Oct 17, 2024
Merged

Improve dictionary compression speed #4170

merged 3 commits into from
Oct 17, 2024

Conversation

Cyan4973
Copy link
Contributor

@Cyan4973 Cyan4973 commented Oct 16, 2024

This patch generally improves dictionary compression speed for the fast strategy, aka levels 1 & 2, following a method similar to #4165 .

The gains are not uniform, and depend on the shape of the data. Tested on a set of various scenarios, one can observe speed gains as large as +14%, and as low as -2%, with the majority being around +5%. Therefore, this change is mostly positive, and when it's not, it's just by a small amount.

I also tried the same modification for dfast strategy, aka levels 3 & 4, but did not observe similar speed gains. That being said, during the investigation process, a few minor modifications were made to the dfast dictionary compression code, leading generally to slightly better compression ratios, by favoring longer matches over short ones.

@Cyan4973 Cyan4973 marked this pull request as ready for review October 16, 2024 17:46
@Cyan4973 Cyan4973 merged commit 18a4219 into dev Oct 17, 2024
91 checks passed
@Cyan4973 Cyan4973 deleted the dict_cSpeed branch December 16, 2024 05:58
@Cyan4973 Cyan4973 mentioned this pull request Feb 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants