Running tar with GenWQE hardware-acceleration

6.10 LPAR mode z/VM guest

GenWQE provides two tools, genwqe_gzip and genwqe_gunzip, that can be used in place of the common code gzip and gunzip tools. The GenWQE versions of the tools use hardware acceleration.

About this task

If called with the z option, the tar utility uses the first gzip tool in the search path, which is usually the common code version. By inserting the path to the GenWQE version of the gzip tool at the beginning of the PATH variable, you can make the tar utility use hardware acceleration.

The effect is most marked for a single large text file. The example that follows compresses a directory with the Linux® source code.

Procedure

  1. Run the tar command as usual to use software compression. To obtain performance data, specify the tar command as an argument to the time command.
    # time tar cfz linux-src.sw.tar.gz linux-src
    real 0m22.329s
    user 0m22.147s
    sys 0m0.849s
  2. Run the tar command with an adjusted PATH variable to use GenWQE hardware acceleration. Again, use the time command to obtain performance data.
    # time PATH=/usr/lib/genwqe:$PATH \
    tar cfz linux-src.hw.tar.gz linux-src
    real 0m1.323s
    user 0m0.242s
    sys 0m1.023s
    In the example, the accelerated operation is significantly faster.

    The hardware-compressed data is slightly larger than the software-compressed version of the same data.

    Note: In this scenario, the path to the GenWQE gzip tool is /usr/lib/genwqe. This path depends on distribution-specific requirements and might be different for your distribution.