]> git.ipfire.org Git - thirdparty/xz.git/commit
liblzma: memcmplen.h: Use 8-byte method on 64-bit unaligned archs
authorLasse Collin <lasse.collin@tukaani.org>
Mon, 13 Jan 2025 06:44:58 +0000 (08:44 +0200)
committerLasse Collin <lasse.collin@tukaani.org>
Mon, 13 Jan 2025 06:44:58 +0000 (08:44 +0200)
commit51f038f8cbd5d8a95954c05bfcbbc32f2a313615
treece7a44df9be166d056a65df2cb010b8dbe988f42
parent96336b0110d47756a9fd2a103fbf0a99e905fbed
liblzma: memcmplen.h: Use 8-byte method on 64-bit unaligned archs

Previously it was enabled only on x86-64 and ARM64 when also support
for unaligned access was detected or manually enabled at built time.

In the default build configuration, the 8-byte method is now enabled
also on 64-bit RISC-V and 64-bit PowerPC (both endiannesses). It was
reported that on big endian POWER9, encoding time may reduce 12-13 %.

This change only affects builds with GCC and Clang because the code
uses __builtin_ctzll or __builtin_clzll.

Thanks to Marcus Comstedt for testing on POWER9.
src/liblzma/common/memcmplen.h