is a simple program to compress or uncompress files using LZF (sometimes known as "Lempel-Ziv Fast") coding. LZF is extremely fast, about 75% of the performance of memcpy(3)
for many inputs, while offering a moderate compression ratio, usually between 1.5:1 and 2:1.
When compressing, it removes each input file and replaces it with an output file with the suffix “.lzf” appended. When uncompressing, it removes each input file and replaces it with an output file with the suffix “.lzf” removed. If no files are specified as arguments, standard input and standard output are used as input and output respectively.
If invoked as lzf, the default mode of operation is to compress. If invoked as unlzf, the default mode of operation is to uncompress. If invoked as lzfcat, the default mode of operation is to uncompress to standard output.
program was first included with version 0.1 of Marc Lehmann's LZF library. It was rewritten for version 2.0 of the library to offer the current syntax, which is mostly compatible with other compression utilities such as gzip(1)
. The lzf
program first appeared in NetBSD 7.0