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

Switch to the zlib flate2 decompression backend #593

Merged
merged 1 commit into from
Jul 12, 2023
Merged

Conversation

edmorley
Copy link
Member

The flate2 crate supports multiple backends for performing decompression:
https://github.com/rust-lang/flate2-rs#backends

The default miniz_oxide flate2 backend has poor performance in debug builds/under QEMU:
rust-lang/flate2-rs#297

Ideally we'd use the fastest zlib-ng backend, however it fails to cross-compile:
rust-lang/libz-sys#93

As such we have to use the next best alternate backend, which is the zlib backend.

(This is the backend that the Python CNB already uses.)

GUS-W-13745779.

@edmorley edmorley added examples faster tests Things that improve the runtime of tests libherokubuildpack labels Jul 12, 2023
@edmorley edmorley self-assigned this Jul 12, 2023
The `flate2` crate supports multiple backends for performing
decompression:
https://github.com/rust-lang/flate2-rs#backends

The default `miniz_oxide` flate2 backend has poor performance in debug
builds/under QEMU:
rust-lang/flate2-rs#297

Ideally we'd use the fastest `zlib-ng` backend, however it fails to
cross-compile:
rust-lang/libz-sys#93

As such we have to use the next best alternate backend, which is the
`zlib` backend.

(This is the backend that the Python CNB already uses.)

GUS-W-13745779.
@edmorley edmorley marked this pull request as ready for review July 12, 2023 12:56
@edmorley edmorley requested a review from a team as a code owner July 12, 2023 12:56
@edmorley edmorley merged commit 217fb3c into main Jul 12, 2023
4 checks passed
@edmorley edmorley deleted the edmorley/flate2-zlib branch July 12, 2023 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
examples faster tests Things that improve the runtime of tests libherokubuildpack
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants