deps: migrate to LibDeflate v1, require Julia 1.12 - #63
Open
Beforerr wants to merge 1 commit into
Open
Conversation
LibDeflate v1 requires Julia >= 1.12, so raise the julia compat bound and
drop the `lts` CI entry.
v1's unsafe_gzip_decompress! subsumes the hand-rolled _unsafe_gzip_decompress!
in src/decompress/gzip.jl, which is deleted. Beyond the API change this gains:
- a length check on short input, where the old code computed
UInt(cSize - 10) and threw InexactError out of a GC.@preserve block
- ISIZE validation, which the old code read but trusted
- trailer located via libdeflate's consumed-input count instead of the
last 8 bytes of the range (equivalent here, since CDF supplies an exact
cSize, but no longer an assumption we own)
The known-size path is kept via the 5-arg form, which also tightens the
CVVR payload to exactly N * sizeof(eltype(dest)); the old code accepted a
short ISIZE and left the tail of dest uninitialized.
The whole-file (CCR) path now uses gzip_isize_decompress!, dropping the
length(input) * 10 output-size guess that could fail on high compression
ratios when the expected size was unknown.
Base.OncePerProcess is unconditional on 1.12, so the decompressor-pool
fallback in src/loading/variable.jl goes away.
Claude-Session: https://claude.ai/code/session_01TFkXrFHTxMKhiaoTHVQZ9F
Contributor
Benchmark Results (Julia v1)Time benchmarks
Memory benchmarks
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
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.
LibDeflate v1 requires Julia >= 1.12, so raise the julia compat bound and
drop the
ltsCI entry.v1's unsafe_gzip_decompress! subsumes the hand-rolled _unsafe_gzip_decompress!
in src/decompress/gzip.jl, which is deleted. Beyond the API change this gains:
UInt(cSize - 10) and threw InexactError out of a GC.@preserve block
last 8 bytes of the range (equivalent here, since CDF supplies an exact
cSize, but no longer an assumption we own)
The known-size path is kept via the 5-arg form, which also tightens the
CVVR payload to exactly N * sizeof(eltype(dest)); the old code accepted a
short ISIZE and left the tail of dest uninitialized.
The whole-file (CCR) path now uses gzip_isize_decompress!, dropping the
length(input) * 10 output-size guess that could fail on high compression
ratios when the expected size was unknown.