Skip to main content

Preface

The INFOPAK ENTRYPOINT product enables compression and decompression of data when invoked from a user application program. INFOPAK ENTRYPOINT is easily installed and does not require any changes for use on DOS or MVS.

  • a compression module, delivered as four object modules on a magnetic tape must be linked together to produce a single reentry load module and the result stored in a load module library.

INFOPAK EntryPoint employees artificial intelligence techniques and high speed scanning to perform a three dimensional analysis of data, making compression decisions based on the type of data found. The scanning program may decide to use several different encoding methods within the data for optimum performance/compression. Operation of the compression routine is transparent to the application program.

INFOPAK EntryPoint installation

DOS Entry Point

The format of the DOS standard label tape is:

File1:INFO.INFCMRHF with entry point INFCMR00

File2:INFO.INFCPHF0

File3:INFO.INFDCHF0

File4:INFO.INFCMPPE

The user should use a standard link to create one load module from these four files with an entry point of INFCMR00.

MVS Entry Point

MVS EntryPoint is delivered as one file, INFCMRE0, with a copy of this manual and a typed JCL procedure for installation.

Using INFCMR00

To use entry point INFCMR00 you must INCLUDE INFCMRE0 in the link edit input.

The compression/decompression module provided by INFOPAK has an entry point INFCMR00 to perform the compression or decompression of any data area. The module is reentrant and can be used by COBOL or ASSEMBLER programs to compress or decompress data sets.

Calling INFCMR00

The call is made with five parameters:

  1. Function code

    This word (PIC S9(8) COMP in COBOL) indicates whether this is compression or decompression. This word must be initialized with a Compression Function code, see Compression Function Codes, for compression and x'00000004' for decompression. This word is divided into two halfword values. The first halfword indicates the type of compression to be used. The second halfword indicates compression or decompression.

  2. Input area

    Name of the field which contains the input data to compress or decompress, depending on the function code.

  3. Length of the input area

    This word (PIC S9(8) COMP in COBOL) contains the length of the input area.

  4. Output area

    Depending on the function code, this area contains the compressed or the decompressed data after the call.

  5. Length of the output area

    This word (PIC S9(8) COMP in COBOL) indicates the required length of the output area. When returning control to the calling program, INFCMR00 places the actual length of the compressed or decompressed output into this field. If the length specified here initially was insufficient (i.e. the resultant compressed or decompressed data is longer than the output length that was specified), INFCMR00 fills the output area with the compressed or decompressed data up to the insufficient length and issues a return code (RETURN-CODE in COBOL) of 4.

note

Each parameter is mandatory.

Cobol example

 *
* CALL PARAMETERS
*
01 INPLNGTH PIC S9(08) COMP.
01 INPAREA PIC X(100).
01 OUTLNGTH PIC S9(08) COMP.
01 OUTAREA PIC X(101).
01 FUNC PIC S9(08) COMP.
*
* 1) COMPRESSION
*
MOVE 0 TO FUNC. Huffman COMPRESSION
MOVE 100 TO INPLNGTH. LENGTH OF DATA TO BE COMPRESSED
MOVE 101 TO OUTLNGTH. LENGTH OF COMPRESSED DATA
CALL 'INFCMR00' USING FUNC INPAREA INPLNGTH OUTAREA OUTLNGTH.
*
* 2) DECOMPRESSION
*
MOVE 4 TO FUNC. DECOMPRESSION
MOVE OUTLNGTH TO INPLNGTH. INITIALIZE INPUT LENGTH
MOVE OUTAREA TO INPAREA. AND INPUT AREA
MOVE 101 TO OUTLNGTH. LENGTH OF DECOMPRESSED DATA
CALL 'INFCMR00' USING FUNC INPAREA INPLNGTH OUTAREA OUTLNGTH.

Assembler example

 *
* CALL PARAMETERS
*
INPLNGTH DS F
INPAREA DC CL100' '
OUTLNGTH DS F
OUTAREA DS 0CL101
FUNC DS F
*
* 1) COMPRESSION
*
LA 7,0 Huffman COMPRESSION
ST 7,FUNC FUNCTION CODE
LA 7,100
ST 7,INPLNGTH LENGTH OF DATA TO BE COMPRESSED
LA 7,101
ST 7,OUTLNGTH LENGTH OF COMPRESSED DATA
CALL INFCMR00,(FUNC,INPAREA,INPLNGTH,OUTAREA,OUTLNGTH),VL
*
* 2) DECOMPRESSION
*
LA 7,4
ST 7,FUNC FUNCTION CODE
L 7,OUTLNGTH
ST 7,INPLNGTH INITIALIZE INPUT LENGTH
BCTR 7,0
EX 7,EXMOVE AND INPUT AREA
LA 7,101
ST 7,OUTLNGTH LENGTH OF DECOMPRESSED DATA
CALL INFCMR00,(FUNC,INPAREA,INPLNGTH,OUTAREA,OUTLNGTH),VL
BR 14
*
EXMOVE MVC INPAREA(0),OUTAREA

note

The two preceding examples illustrate the compression of a data area followed by its decompression. When calling for decompression, the example reinitializes the length of the input area with the output length that was provided by INFCMP00 when it performed the compression, and reinitializes the input area with the compressed data from the output area. The length of the output area was reinitialized to be the same as it is for compression.

note

Notice that for compression the length of the output area is one byte more than the input area. This guarantees, in compression, that the output length will be sufficient.

Compression Function Codes

This word is divided into two halfword values. The first halfword indicates the type of compression to be used. The second halfword indicates compression or decompression.

     Function Code TYPE Compression
x'00000000' Huffman compression request
x'00080000' hardware compression request if available or
hardware simulation
x'000C0000' hardware compression request if available
or Hoffman if not available
x'00000004' decompression request