Confirm custom Huffman trees still incompatible with original nuke1

Tested custom trees with the custom master fix in place — the original
still hangs.  The tree incompatibility is a separate issue from the
SuperMaster path hang (both are real problems, both are now understood).

Custom trees give ~40% better compression for text data (1066 vs 1688
bytes for textfile.txt) but are incompatible with nuke1's assumptions.
Default tree retained for backward compatibility.

Updated roadmap to separate the backward compat (done) from the tree
optimization (remaining).
This commit is contained in:
Eremey Valetov
2026-03-29 15:36:48 -04:00
parent 6e62a7aa28
commit 75a5ea541e
2 changed files with 15 additions and 11 deletions
+5 -3
View File
@@ -697,9 +697,11 @@ static int flush_block(struct compressor *c, int is_last)
u8 lengths[NumSymbols];
/* Use the default tree for backward compatibility with the original
UC2 Pro's ASM decompressor kernel. Custom trees from our treegen
cause the original to hang (the tree encoding is valid but the
ASM kernel has undocumented assumptions about tree shapes). */
UC2 Pro's ASM decompressor (nuke1). Custom trees from our treegen
produce valid bitstreams but nuke1 hangs on them — the original's
tree generation (TREEGEN.CPP) produces different Huffman code
assignments that nuke1 depends on. The default tree gives ~40%
worse compression but full backward compatibility. */
uc2_default_lengths(lengths);
/* Emit block-present flag */