QuickLZ, for Really Fast Lossless Compression
Posted by Sachin Garg on 10th October 2006 | Permanent Link
Lasse Reinhold recently released alpha version of QuickLZ, a very fast lossless compression algorithm coded in 386 compatible assembly (code is inline C, so you can readily use it in C/C++ projects). To quote Werner Bergmans, “QuickLZ is now the fastest command line compression program ever tested on maximum compression”.
For more details, you can also check this comp.compression thread.
It uses a LZ77 based algorithm and is GPL licensed:
The current implementation is using LZ77 encoding with a 16 Kbyte window, a maximum matchlength of 72 bytes and separate handling of RLE sequences.
LZ matches are stored as an offset (values 3…17476) and a matchlength, both in form of bitfields of variable length so that small values, which are frequent in LZ compression, have shorter bitfields. RLE sequences are stored as a runlength followed by the byte to be repeated with the runlength (values 3…588) being a variable sized bitfield. Literals (uncompressed bytes) are prefixed by a 0 bit followed by the uncompressed byte.
A hash table of 2048 entries is used to find LZ matches. The has table is updated on each uncompressed byte, on each byte following an LZ match and on each byte following an RLE sequence. If we name that byte Bi and the following two bytes Bi+1and Bi+2, we can call D = Bi | (Bi+1 << 8) | (Bi+2 << 16). The hash table is now updated such that hash[((D >> 13) ^ D) && 0x7ff] = O where O is the offset of Bi.
Code doesn’t yet uses any MMX/SSE2 features and Lasse is planning some further optimizations in algorithm. I was almost holding my breath to see how much further this will go.
Anyway, next version will probably deserve another post for itself.
October 12th, 2006 at 9:28 pm
excellent work on this software. Any plans to licence it ?
October 14th, 2006 at 4:25 pm
Yes, I would like to see more information on licensing also. Great work.
October 14th, 2006 at 8:30 pm
doh, its GPL’ed, says on the site, checking it out now :)
October 15th, 2006 at 4:55 pm
There will be a commercial license available around the end of october because the commercial version needs to thoroughly tested and rock stable.
So stay tuned :-)
November 8th, 2006 at 8:28 pm
Version 1.0 is out and a commercial license is available.
November 26th, 2006 at 6:26 pm
Version 1.10 is out - kicks LZO’s b*** at decompression speed ;-)
November 27th, 2006 at 11:45 am
The “fastest in its class” compression/decompression library just got better.