8400335

Using Variable Length Code Tables to Compress an Input Data Stream to a Compressed Output Data Stream

PublishedMarch 19, 2013
Assigneenot available in USPTO data we have
Technical Abstract

Patent Claims
28 claims

Legal claims defining the scope of protection, as filed with the USPTO.

1

1. A computer program product for compressing an input data stream to produce a compressed output data stream, the computer program product comprising a computer readable storage medium having computer readable program code embodied therein that executes to perform operations, the operations comprising: determining whether a number of at least two consecutive data units in the input data stream match the number of consecutive data units in a history buffer of previously received data units in the input data stream; in response to determining that the number of consecutive data units in the input data stream match the number of consecutive data units in the history buffer, generating a copy pointer symbol including data indicating a copy pointer symbol referencing previously received data units in the history buffer and indicating the determined number of consecutive data units; determining a relative displacement count in the history buffer at which the number of matching consecutive data units start; determining from a variable length code table an encoding of the relative displacement count in the history buffer; indicating in the generated copy pointer symbol the determined encoding of the relative displacement count; and outputting the copy pointer symbol in the compressed output data stream.

2

2. The computer program product of claim 1 , wherein the encodings of the relative displacement counts in the variable length code table include a prefix indicating a number of following bits used to indicate the relative displacement count in the history buffer where the consecutive data units start.

3

3. The computer program product of claim 2 , wherein for a 16 kilobyte unit history buffer: a first prefix value of 3 bits indicates that a next following 8 bits indicates a relative displacement count of 0 through 255 in the history buffer; a second prefix value of four bits indicates that a next following 8 bits indicates a relative displacement count of 256 through 511 in the history buffer; a third prefix value of four bits indicates that a next following 9 bits indicates a relative displacement count of 512 through 1023 in the history buffer; a fourth prefix value of three bits indicates that a next following 10 bits indicates a relative displacement count of 1024 through 2047 in the history buffer; a fifth prefix value of three bits indicates that a next following 11 bits indicates a relative displacement count of 2048 through 4095 in the history buffer; a sixth prefix value of two bits indicates that a next following 12 bits indicates a relative displacement count of 4096 through 8191 in the history buffer; and a seventh prefix value of 2 bits indicates that a next following 13 bits indicates a relative displacement count of 8192 through 16385 in the history buffer.

4

4. The computer program product of claim 2 , wherein for an 8 kilobyte history buffer: a first prefix value of 2 bits indicates that a next following 8 bits indicates a relative displacement count of 0 through 255 in the history buffer; a second prefix value of three bits indicates that a next following 8 bits indicates a relative displacement count of 256 through 511 in the history buffer; a third prefix value of three bits indicates that a next following 9 bits indicates a relative displacement count of 512 through 1023 in the history buffer; a fourth prefix value of three bits indicates that a next following 10 bits indicates a relative displacement count of 1024 through 2047 in the history buffer; a fifth prefix value of three bits indicates that a next following 11 bits indicates a relative displacement count of 2048 through 4095 in the history buffer; and a sixth prefix value of two bits indicates that a next following 12 bits indicates a relative displacement count of 4096 through 8191 in the history buffer.

5

5. The computer program product of claim 1 , wherein the operations further comprise: determining whether the number comprises a minimum number of consecutive data units; determining whether the relative displacement count in the history buffer at which the number of matching consecutive data units start is less than a predetermined displacement count in response to determining that the number comprises the minimum number of consecutive data units; indicating in the copy pointer symbol the relative displacement count using a fixed number of bits capable of representing displacement count values up to the predetermined displacement count in response to determining that the number comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement count; wherein the operations of determining from the variable length code table the encoding of the displacement count and indicating the determined encoding of the displacement count in the copy pointer symbol are performed in response to determining that the number of consecutive data units is more than the minimum number of consecutive data units, wherein the copy pointer symbol, formed in response to determining that the number comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement count, has fewer bits than the copy pointer symbol formed if the number is greater than the minimum number of consecutive data units and the relative displacement count is greater than the predetermined displacement count.

6

6. The computer program product of claim 5 wherein the operations further comprise: outputting a first of the minimum number of consecutive data units as a literal data symbol in the output data stream in response to determining that the relative displacement count at which the minimum number of matching consecutive data units start is greater than the predetermined displacement count; determining whether there are consecutive data units in the input data stream starting from a second of the minimum number of consecutive data units; and performing a further iteration of the operations to generate the copy pointer symbol for the consecutive data units in the input data stream starting from the second of the minimum number of consecutive data units.

7

7. The computer program product of claim 5 , wherein the variable length code table comprises a first variable length code table, and wherein determining from the first variable length code table the encoding is performed in response to the consecutive number of data units being greater than the minimum number of consecutive data units, and wherein the indicating in the copy pointer symbol the relative displacement count using a fixed number of bits in response to determining that the consecutive number of data units comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement comprises: determining from a second variable length code table an encoding of the relative displacement count in the history buffer, wherein the second variable length coding table includes fewer entries than the first variable length code table, and has a different number of prefix bits than corresponding entries in the first variable length code table.

8

8. The computer program product of claim 7 , wherein the data unit comprises a byte and the minimum number comprises two consecutive data units, wherein in the second variable length code table, a first prefix value of 1 bit indicates that a next following 8 bits indicates a relative displacement count of 0 through 255 in the history buffer, a second prefix value of two bits indicates that a next following 8 bits indicates a relative displacement count of 256 through 511 in the history buffer, and a third prefix value of two bits indicates that a next following 9 bits indicates a relative displacement count of 512 through 1023 in the history buffer, and wherein in the first variable length code table, prefix values for data units 0 through 1023 have a greater number of bits than the first, second, and third prefix values in the second variable length code table.

9

9. The computer program product of claim 1 , wherein determining that the number of the at least two consecutive data units match the number of consecutive data units in the history buffer comprises determining that there are multiple instances of consecutive data units in the history buffer matching the number of the at least two consecutive data units in the input stream, wherein the determined relative displacement count comprises a lowest relative displacement count value for the instances of the consecutive data units in the history buffer.

10

10. The computer program of claim 1 , further comprising: storing the compressed output data stream in a magnetic tape in a magnetic tape cartridge.

11

11. A system for compressing an input data stream to produce a compressed output data stream, comprising: a compression unit including: a variable length coding table; a compression program executed to perform operations, the operations comprising: determining whether a number of at least two consecutive data units in the input data stream match the number of consecutive data units in a history buffer of previously received data units in the input data stream; in response to determining that the number of consecutive data units in the input data stream match the number of consecutive data units in the history buffer, generating a copy pointer symbol including data indicating a copy pointer symbol referencing previously received data units in the history buffer and indicating the determined number of consecutive data units; determining a relative displacement count in the history buffer at which the number of matching consecutive data units start; determining from the variable length code table an encoding of the relative displacement count in the history buffer; indicating in the generated copy pointer symbol the determined encoding of the relative displacement count; and outputting the copy pointer symbol in the compressed output data stream.

12

12. The system of claim 11 , wherein the encodings of the relative displacement counts in the variable length code table include a prefix indicating a number of following bits used to indicate the relative displacement count in the history buffer where the consecutive data units start.

13

13. The system of claim 11 , wherein the operations further comprise: determining whether the number comprises a minimum number of consecutive data units; determining whether the relative displacement count in the history buffer at which the number of matching consecutive data units start is less than a predetermined displacement count in response to determining that the number comprises the minimum number of consecutive data units; indicating in the copy pointer symbol the relative displacement count using a fixed number of bits capable of representing displacement count values up to the predetermined displacement count in response to determining that the number comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement count; wherein the operations of determining from the variable length code table the encoding of the displacement count and indicating the determined encoding of the displacement count in the copy pointer symbol are performed in response to determining that the number of consecutive data units is more than the minimum number of consecutive data units, wherein the copy pointer symbol, formed in response to determining that the number comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement count, has fewer bits than the copy pointer symbol formed if the number is greater than the minimum number of consecutive data units and the relative displacement count is greater than the predetermined displacement count.

14

14. The system of claim 13 wherein the operations further comprise: outputting a first of the minimum number of consecutive data units as a literal data symbol in the output data stream in response to determining that the relative displacement count at which the minimum number of matching consecutive data units start is greater than the predetermined displacement count; determining whether there are consecutive data units in the input data stream starting from a second of the minimum number of consecutive data units; and performing a further iteration of the operations to generate the copy pointer symbol for the consecutive data units in the input data stream starting from the second of the minimum number of consecutive data units.

15

15. The system of claim 13 , wherein the variable length code table comprises a first variable length code table, and wherein determining from the first variable length code table the encoding is performed in response to the consecutive number of data units being greater than the minimum number of consecutive data units, further comprising: a second variable length code table, wherein the indicating in the copy pointer symbol the relative displacement count using a fixed number of bits in response to determining that the consecutive number of data units comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement comprises determining from a second variable length code table an encoding of the relative displacement count in the history buffer, wherein the second variable length coding table includes fewer entries than the first variable length code table, and has a different number of prefix bits than corresponding entries in the first variable length code table.

16

16. The system of claim 11 , wherein determining that the number of the at least two consecutive data units match the number of consecutive data units in the history buffer comprises determining that there are multiple instances of consecutive data units in the history buffer matching the number of the at least two consecutive data units in the input stream, wherein the determined relative displacement count comprises a lowest relative displacement count value for the instances of the consecutive data units in the history buffer.

17

17. A method for compressing an input data stream to produce a compressed output data stream, comprising: determining whether a number of at least two consecutive data units in the input data stream match the number of consecutive data units in a history buffer of previously received data units in the input data stream; in response to determining that the number of consecutive data units in the input data stream match the number of consecutive data units in the history buffer, generating a copy pointer symbol including data indicating a copy pointer symbol referencing previously received data units in the history buffer and indicating the determined number of consecutive data units; determining a relative displacement count in the history buffer at which the number of matching consecutive data units start; determining from a variable length code table an encoding of the relative displacement count in the history buffer; indicating in the generated copy pointer symbol the determined encoding of the relative displacement count; and outputting the copy pointer symbol in the compressed output data stream.

18

18. The method of claim 17 , wherein the encodings of the relative displacement counts in the variable length code table include a prefix indicating a number of following bits used to indicate the relative displacement count in the history buffer where the consecutive data units start.

19

19. The method of claim 17 , further comprising: determining whether the number comprises a minimum number of consecutive data units; determining whether the relative displacement count in the history buffer at which the number of matching consecutive data units start is less than a predetermined displacement count in response to determining that the number comprises the minimum number of consecutive data units; indicating in the copy pointer symbol the relative displacement count using a fixed number of bits capable of representing displacement count values up to the predetermined displacement count in response to determining that the number comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement count; wherein the operations of determining from the variable length code table the encoding of the displacement count and indicating the determined encoding of the displacement count in the copy pointer symbol are performed in response to determining that the number of consecutive data units is more than the minimum number of consecutive data units, wherein the copy pointer symbol, formed in response to determining that the number comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement count, has fewer bits than the copy pointer symbol formed if the number is greater than the minimum number of consecutive data units and the relative displacement count is greater than the predetermined displacement count.

20

20. The method of claim 19 wherein the operations further comprise: outputting a first of the minimum number of consecutive data units as a literal data symbol in the output data stream in response to determining that the relative displacement count at which the minimum number of matching consecutive data units start is greater than the predetermined displacement count; determining whether there are consecutive data units in the input data stream starting from a second of the minimum number of consecutive data units; and performing a further iteration of the operations to generate the copy pointer symbol for the consecutive data units in the input data stream starting from the second of the minimum number of consecutive data units.

21

21. The method of claim 19 , wherein the variable length code table comprises a first variable length code table, and wherein determining from the first variable length code table the encoding is performed in response to the consecutive number of data units being greater than the minimum number of consecutive data units, and wherein the indicating in the copy pointer symbol the relative displacement count using a fixed number of bits in response to determining that the consecutive number of data units comprises the minimum number of consecutive data units and the relative displacement count is less than the predetermined displacement comprises: determining from a second variable length code table an encoding of the relative displacement count in the history buffer, wherein the second variable length coding table includes fewer entries than the first variable length code table, and has a different number of prefix bits than corresponding entries in the first variable length code table.

22

22. The method of claim 17 , wherein determining that the number of the at least two consecutive data units match the number of consecutive data units in the history buffer comprises determining that there are multiple instances of consecutive data units in the history buffer matching the number of the at least two consecutive data units in the input stream, wherein the determined relative displacement count comprises a lowest relative displacement count value for the instances of the consecutive data units in the history buffer.

23

23. A computer readable storage medium including a data structure comprising: a variable length code table having encodings of relative displacement counts in a history buffer of previously received data units in an input data stream, wherein the variable length coding table is processed by a compression unit to determine an encoding of the relative displacement count in the history buffer at which matching consecutive data units in the input data stream start to include in a copy pointer symbol outputted in a compressed output data stream, wherein the copy pointer symbol further includes data indicating a copy pointer symbol referencing previously received data units in the history buffer and a determined number of consecutive bytes in the input data stream matching consecutive bytes starting at the relative displacement count in the history buffer.

24

24. The computer readable storage medium of claim 23 , wherein the encodings of the relative displacement counts in the variable length code table include a prefix indicating a number of following bits used to indicate the relative displacement count in the history buffer where the consecutive data units start.

25

25. The computer readable storage medium of claim 24 , wherein for a 16 kilobyte unit history buffer: a first prefix value of 3 bits indicates that a next following 8 bits indicates a relative displacement count of 0 through 255 in the history buffer; a second prefix value of four bits indicates that a next following 8 bits indicates a relative displacement count of 256 through 511 in the history buffer; a third prefix value of four bits indicates that a next following 9 bits indicates a relative displacement count of 512 through 1023 in the history buffer; a fourth prefix value of three bits indicates that a next following 10 bits indicates a relative displacement count of 1024 through 2047 in the history buffer; a fifth prefix value of three bits indicates that a next following 11 bits indicates a relative displacement count of 2048 through 4095 in the history buffer; a sixth prefix value of two bits indicates that a next following 12 bits indicates a relative displacement count of 4096 through 8191 in the history buffer; and a seventh prefix value of 2 bits indicates that a next following 13 bits indicates a relative displacement count of 8192 through 16385 in the history buffer.

26

26. The computer readable storage medium of claim 24 , wherein for an 8 kilobyte history buffer: a first prefix value of 2 bits indicates that a next following 8 bits indicates a relative displacement count of 0 through 255 in the history buffer; a second prefix value of three bits indicates that a next following 8 bits indicates a relative displacement count of 256 through 511 in the history buffer; a third prefix value of three bits indicates that a next following 9 bits indicates a relative displacement count of 512 through 1023 in the history buffer; a fourth prefix value of three bits indicates that a next following 10 bits indicates a relative displacement count of 1024 through 2047 in the history buffer; a fifth prefix value of three bits indicates that a next following 11 bits indicates a relative displacement count of 2048 through 4095 in the history buffer; and a sixth prefix value of two bits indicates that a next following 12 bits indicates a relative displacement count of 4096 through 8191 in the history buffer.

27

27. The computer readable storage medium of claim 23 , wherein the variable length code table comprises a first variable length code table, and wherein the first variable length code table is processed when a consecutive number of the matching data units is greater than a minimum number of consecutive data units, further comprising: a second variable length code table including an encoding of the relative displacement count in the history buffer, wherein the second variable length coding table includes fewer entries than the first variable length code table, and has a different number of prefix bits than corresponding entries in the first variable length code table, wherein the second variable length code table is processed to determine the encoding of the relative displacement count when the consecutive number of matching data units comprises the minimum number of consecutive data units and the relative displacement count is less than a predetermined displacement count.

28

28. The computer readable storage medium of claim 27 , wherein the data unit comprises a byte and the minimum number comprises two consecutive data units, wherein in the second variable length code table, a first prefix value of 1 bit indicates that a next following 8 bits indicates a relative displacement count of 0 through 255 in the history buffer, a second prefix value of two bits indicates that a next following 8 bits indicates a relative displacement count of 256 through 511 in the history buffer, and a third prefix value of two bits indicates that a next following 9 bits indicates a relative displacement count of 512 through 1023 in the history buffer, and wherein in the first variable length code table, prefix values for data units 0 through 1023 have a greater number of bits than the first, second, and third prefix values in the second variable length code table.

Patent Metadata

Filing Date

Unknown

Publication Date

March 19, 2013

Inventors

Glen A. Jaquette

Want to explore more patents?

Browse 5M+ US patents with plain-English claim translations and AI-generated analysis.

Citation & reuse

Analysis on this page is generated by Patentable — an AI-powered patent intelligence platform. AI-generated summaries, explanations, and analysis may be reused with attribution and a visible link back to the canonical URL below. Patent abstracts and claims are USPTO public domain.

Cite as: Patentable. “USING VARIABLE LENGTH CODE TABLES TO COMPRESS AN INPUT DATA STREAM TO A COMPRESSED OUTPUT DATA STREAM” (8400335). https://patentable.app/patents/8400335

© 2026 Patentable. All rights reserved.

Patentable is a research and drafting-assistant tool, not a law firm, and does not provide legal advice. Documents we generate are drafts for review by a licensed patent attorney.

USING VARIABLE LENGTH CODE TABLES TO COMPRESS AN INPUT DATA STREAM TO A COMPRESSED OUTPUT DATA STREAM — Glen A. Jaquette | Patentable