diff options
author | Yann Collet <cyan@fb.com> | 2019-12-03 00:38:33 (GMT) |
---|---|---|
committer | Yann Collet <cyan@fb.com> | 2019-12-03 00:38:33 (GMT) |
commit | 0f6cbd996fbaade6715c7009c6f8dbb0f23f0b4b (patch) | |
tree | c635b37e08a6a9172ab63c06fff35f76e2729ca9 /lib/lz4.c | |
parent | bed083b3c76ae3ea76a5fc2edb822220fb69f680 (diff) | |
download | lz4-0f6cbd996fbaade6715c7009c6f8dbb0f23f0b4b.zip lz4-0f6cbd996fbaade6715c7009c6f8dbb0f23f0b4b.tar.gz lz4-0f6cbd996fbaade6715c7009c6f8dbb0f23f0b4b.tar.bz2 |
faster decoding speed with Visual
by enabling the fast decoder path.
Visual requires a different set of macro constants to detect x86 / x64.
On my laptop, decoding speed on x64 went up from 3.12 to 3.45 GB/s.
32-bit is less impressive, though still favorable,
with speed increasing from 2.55 to 2.60 GB/s.
So both cases are now enabled.
Suggested by Bartosz Taudul (@wolfpld).
Diffstat (limited to 'lib/lz4.c')
-rw-r--r-- | lib/lz4.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -374,12 +374,12 @@ static const int dec64table[8] = {0, 0, 0, -1, -4, 1, 2, 3}; #ifndef LZ4_FAST_DEC_LOOP -# if defined(__i386__) || defined(__x86_64__) +# if defined __i386__ || defined _M_IX86 || defined __x86_64__ || defined _M_X64 # define LZ4_FAST_DEC_LOOP 1 # elif defined(__aarch64__) && !defined(__clang__) /* On aarch64, we disable this optimization for clang because on certain - * mobile chipsets and clang, it reduces performance. For more information - * refer to https://github.com/lz4/lz4/pull/707. */ + * mobile chipsets, performance is reduced with clang. For information + * refer to https://github.com/lz4/lz4/pull/707 */ # define LZ4_FAST_DEC_LOOP 1 # else # define LZ4_FAST_DEC_LOOP 0 |