]> git.ipfire.org Git - thirdparty/xz.git/commit
liblzma: Fix building with NVHPC (NVIDIA HPC SDK).
authorSergey Kosukhin <sergey.kosukhin@mpimet.mpg.de>
Wed, 13 Mar 2024 12:07:13 +0000 (13:07 +0100)
committerLasse Collin <lasse.collin@tukaani.org>
Wed, 22 May 2024 11:07:37 +0000 (14:07 +0300)
commit403b4c78b81f67bc3787542f55f555407253316c
treeffad05b4d572474164df1030d0e447dc39884c45
parent1888fb49f629340758e98e69d5aa328f6f73c5e1
liblzma: Fix building with NVHPC (NVIDIA HPC SDK).

NVHPC compiler has several issues that make it impossible to
build liblzma:
  - the compiler cannot handle unions that contain pointers that
    are not the first members;
  - the compiler cannot handle the assembler code in range_decoder.h
    (LZMA_RANGE_DECODER_CONFIG has to be set to zero);
  - the compiler fails to produce valid code for delta_decode if the
    vectorization is enabled, which results in failed tests.

This introduces NVHPC-specific workarounds that address the issues.

(cherry picked from commit 096bc0e3f8fb4bfc4d2f3f64a7f219401ffb4c31)
src/liblzma/common/string_conversion.c
src/liblzma/delta/delta_decoder.c
src/liblzma/rangecoder/range_decoder.h