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

internal/lz4block: Simplify portable decoder #159

Merged
merged 1 commit into from Feb 5, 2022

Conversation

greatroar
Copy link
Contributor

@greatroar greatroar commented Jan 30, 2022

The custom copy code isn't needed. After copying from the dictionary, we can adjust di and mLen and continue to copy from dst as usual. Also, we only need one case to copy from the dictionary, since copy stops at the end of its shortest input.

@greatroar greatroar force-pushed the simplify-decode-other branch 2 times, most recently from 1f5868d to c89b4a4 Compare January 30, 2022 11:22
@greatroar
Copy link
Contributor Author

Closing for now. The test I added shows an inconsistency between the Go and asm implementations.

@greatroar
Copy link
Contributor Author

The inconsistency is #160; it's harmless, just unfortunate. Added an additional test that passes with all four decoders.

@pierrec pierrec merged commit 4b2f324 into pierrec:v4 Feb 5, 2022
@greatroar greatroar deleted the simplify-decode-other branch February 6, 2022 12:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants