Scroll to navigation

qbdiff(1) General Commands Manual qbdiff(1)

NAME

qbdiff - quick binary diff

SYNOPSIS

qbdiff [ old_file new_file diff_file ]

DESCRIPTION

Computes the difference between two binary files and writes it to a binary file suitable for use with qbpatch. qbdiff is an improved and modernised version of bsdiff by Colin Percival. qbdiff is generally faster and can take advantage of multiple CPU cores.

The command-line invocation is deliberately the same as of bsdiff

PATCH COMPRESSION

qbdiff uses the lzma compression algorithm to compress the patch file. lzma takes considerably more time to compress data in exchange for a good compression ratio and fast decompression. The compression ratio is usually better than this of bzip2 on binary data, and since lzma is highly assymmetric, it's also two to six times faster in decompression (and thus patch application).

MEMORY MANAGEMENT

The bsdiff memory usage is max(17*n,9*n+m)+O(1), while qbdiff memory usage is usually bounded by O(5*n+m)+O(1) in most use cases - the improvement is clear and almost twofold-threefold.

INTEGRITY CHECKING

qbdiff will compute the BLAKE2b checksum of new_file and embed it into the patch file. The checksum is verified when qbpatch finishes patching the file.

AUTHOR

Kamila Szewczyk, kspalaiologos@gmail.com.

https://github.com/kspalaiologos/qbdiff

Thanks to: Ilya Grebnov, Benjamin Strachan, Colin Percival, Igor Pavlov, Lasse Collin

SEE ALSO

bsdiff(1), bspatch(1), qbpatch(1)

version v1.0.0