binjs-ref icon indicating copy to clipboard operation
binjs-ref copied to clipboard

Context 0.1: Huffman tables

Open Yoric opened this issue 4 years ago • 4 comments

This is a first step towards decompressing Huffman content.

Yoric avatar Sep 17 '19 08:09 Yoric

I think it LGTM. I'm wondering if you couldn't use an existing implementation on crates.io? Looking at the results https://crates.io/search?q=huffman, they doesn't seem commonly used tho.

xtuc avatar Sep 17 '19 10:09 xtuc

I've looked at a few crates and they all seemed to use actual trees to represent Huffman codes, which makes them very slow for our use case.

Yoric avatar Sep 17 '19 11:09 Yoric

Happy to review... could you look at the failing test first?

dominiccooney avatar Sep 25 '19 08:09 dominiccooney

I've reworked the MultiLookupHuffmanTable to remove some assumptions on the prefix bit length.

Yoric avatar Sep 25 '19 14:09 Yoric