From f49c1563ff2405b0db4b3ef77dd9bbb8ee64deb1 Mon Sep 17 00:00:00 2001 From: "W. Felix Handte" Date: Wed, 2 Sep 2020 12:40:42 -0400 Subject: [PATCH] Force-Inline ZSTD_insertAndFindFirstIndex_internal() Without this, gcc was declining to inline the function in `ZSTD_noDict` mode, resulting in a ~10% slowdown. --- lib/compress/zstd_lazy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/compress/zstd_lazy.c b/lib/compress/zstd_lazy.c index 5d32c78b8..33acf687e 100644 --- a/lib/compress/zstd_lazy.c +++ b/lib/compress/zstd_lazy.c @@ -447,7 +447,7 @@ static size_t ZSTD_BtFindBestMatch_extDict_selectMLS ( /* Update chains up to ip (excluded) Assumption : always within prefix (i.e. not within extDict) */ -static U32 ZSTD_insertAndFindFirstIndex_internal( +FORCE_INLINE_TEMPLATE U32 ZSTD_insertAndFindFirstIndex_internal( ZSTD_matchState_t* ms, const ZSTD_compressionParameters* const cParams, const BYTE* ip, U32 const mls) -- 2.47.2