An instruction for direct interpretation of LZ77-compressed programs

  • Authors:
  • Christopher W. Fraser

  • Affiliations:
  • Microsoft Research, One Microsoft Way, Redmond, WA 98052, U.S.A.

  • Venue:
  • Software—Practice & Experience
  • Year:
  • 2006

Quantified Score

Hi-index 0.01

Visualization

Abstract

A new instruction adapts LZ77 compression for use inside running programs. The instruction economically references and reuses code fragments that are too small to package as conventional subroutines. The compressed code is interpreted directly, with neither prior nor on-the-fly decompression. Hardware implementations seem plausible and could benefit both memory-constrained and more conventional systems. The method is extremely simple. It has been added to a pre-existing, bytecoded instruction set, and it added only 10 lines of C to the bytecode interpreter. It typically cuts code size by a third; that is, typical compression ratios are roughly 0.67×. More ambitious compressors are available, but they are more complex, which retards adoption. The current method offers a useful trade-off to these more complex systems. Copyright © 2005 John Wiley & Sons, Ltd.