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

[lib] Fix UBSAN warning in ZSTD_decompressSequences() #2625

Merged
merged 1 commit into from
May 7, 2021

Conversation

terrelln
Copy link
Contributor

@terrelln terrelln commented May 6, 2021

This moves the pointer addition below the error check, and also moves BIT_reloadDStream() to the bottom of the loop.

Benchmarks run at level 1 on the silesia corpus.

Platform Compiler dev PR
i9-9900k gcc 10.2 1213 MB/s 1207 MB/s
i9-9900k clang 11.1 1032 MB/s 1072 MB/s
Macbook clang 1269 MB/s 1271 MB/s
devserver gcc 840 MB/s 846 MB/s
devserver clang 761 MB/s 780 MB/s

Fixes #2590.

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.

UB in ZSTD_decompressSequences_body when error-valued onSeqSize is added to op
3 participants