A method of updating a computer file from an old file into a new file
comprises blocking the new file and the old file into fixed-size blocks,
maintaining a window (collection of contiguous blocks) for each file on
which lookup preprocessing has been performed, and performing match
processing on each new file block in turn (comparing against both the old
and new windows) using a key-sampling technique combined with approximate
matching. For each new file block, the match information is then
optimized for coding efficiency and encoded into a patch file that
describes an algorithm for converting the old file into the new file. The
patch file application method and apparatus then performs the algorithm
described in the patch file. The method uses a fixed amount of
random-access memory regardless of the sizes of the two files and uses no
temporary mass storage. In addition, the method has a running time
roughly proportional to the size of the new file and allows the use of
parallel processing to reduce the time required. The system and method
produce patch files which are smaller than prior systems and methods, and
allow the operator of the apparatus to perform an
efficiency/effectiveness trade-off.