summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Moinvaziri <nathan@nathanm.com>2020-05-24 10:01:05 -0700
committerHans Kristian Rosbach <hk-github@circlestorm.org>2020-05-25 15:19:35 +0200
commit7a107a1bc626406efe8c970ef53b5af68609bfe2 (patch)
tree740955b536c799910f792a5c46d94b86c7dca198
parent9dd427a1566a6273c4b409269a414459ccbdd2c6 (diff)
downloadProject-Tick-7a107a1bc626406efe8c970ef53b5af68609bfe2.tar.gz
Project-Tick-7a107a1bc626406efe8c970ef53b5af68609bfe2.zip
Rename match_p.h to match_tpl.h since it has been converted to a template header file.
-rw-r--r--CMakeLists.txt2
-rw-r--r--arch/x86/compare258_avx.c10
-rw-r--r--arch/x86/compare258_sse.c2
-rw-r--r--compare258.c8
-rw-r--r--match_tpl.h (renamed from match_p.h)0
-rw-r--r--win32/Makefile.a646
-rw-r--r--win32/Makefile.arm6
-rw-r--r--win32/Makefile.msc6
8 files changed, 20 insertions, 20 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 9fbdd58102..5a5d0dabd3 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -764,7 +764,7 @@ set(ZLIB_PRIVATE_HDRS
inflate_p.h
inftrees.h
insert_string_tpl.h
- match_p.h
+ match_tpl.h
memcopy.h
trees.h
trees_emit.h
diff --git a/arch/x86/compare258_avx.c b/arch/x86/compare258_avx.c
index 34e93bbcba..fe38d16c9e 100644
--- a/arch/x86/compare258_avx.c
+++ b/arch/x86/compare258_avx.c
@@ -18,13 +18,13 @@
/* UNALIGNED_OK, AVX2 intrinsic comparison */
static inline int32_t compare256_unaligned_avx2_static(const unsigned char *src0, const unsigned char *src1) {
int32_t len = 0;
-
+
do {
__m256i ymm_src0, ymm_src1, ymm_cmp;
ymm_src0 = _mm256_loadu_si256((__m256i*)src0);
ymm_src1 = _mm256_loadu_si256((__m256i*)src1);
ymm_cmp = _mm256_cmpeq_epi8(ymm_src0, ymm_src1); /* non-identical bytes = 00, identical bytes = FF */
- int mask = _mm256_movemask_epi8(ymm_cmp);
+ int mask = _mm256_movemask_epi8(ymm_cmp);
if ((unsigned int)mask != 0xFFFFFFFF) {
int match_byte = __builtin_ctz(~mask); /* Invert bits so identical = 0 */
return (int32_t)(len + match_byte);
@@ -35,7 +35,7 @@ static inline int32_t compare256_unaligned_avx2_static(const unsigned char *src0
ymm_src0 = _mm256_loadu_si256((__m256i*)src0);
ymm_src1 = _mm256_loadu_si256((__m256i*)src1);
ymm_cmp = _mm256_cmpeq_epi8(ymm_src0, ymm_src1);
- mask = _mm256_movemask_epi8(ymm_cmp);
+ mask = _mm256_movemask_epi8(ymm_cmp);
if ((unsigned int)mask != 0xFFFFFFFF) {
int match_byte = __builtin_ctz(~mask);
return (int32_t)(len + match_byte);
@@ -47,7 +47,7 @@ static inline int32_t compare256_unaligned_avx2_static(const unsigned char *src0
return 256;
}
-static inline int32_t compare258_unaligned_avx2_static(const unsigned char *src0, const unsigned char *src1) {
+static inline int32_t compare258_unaligned_avx2_static(const unsigned char *src0, const unsigned char *src1) {
if (*(uint16_t *)src0 != *(uint16_t *)src1)
return (*src0 == *src1);
@@ -62,6 +62,6 @@ int32_t compare258_unaligned_avx2(const unsigned char *src0, const unsigned char
#define COMPARE256 compare256_unaligned_avx2_static
#define COMPARE258 compare258_unaligned_avx2_static
-#include "match_p.h"
+#include "match_tpl.h"
#endif
diff --git a/arch/x86/compare258_sse.c b/arch/x86/compare258_sse.c
index 9695529e2f..2c274823fc 100644
--- a/arch/x86/compare258_sse.c
+++ b/arch/x86/compare258_sse.c
@@ -69,6 +69,6 @@ int32_t compare258_unaligned_sse4(const unsigned char *src0, const unsigned char
#define COMPARE256 compare256_unaligned_sse4_static
#define COMPARE258 compare258_unaligned_sse4_static
-#include "match_p.h"
+#include "match_tpl.h"
#endif
diff --git a/compare258.c b/compare258.c
index 76d062779c..cb75d0974d 100644
--- a/compare258.c
+++ b/compare258.c
@@ -61,7 +61,7 @@ int32_t compare258_c(const unsigned char *src0, const unsigned char *src1) {
#define COMPARE256 compare256_c_static
#define COMPARE258 compare258_c_static
-#include "match_p.h"
+#include "match_tpl.h"
#ifdef UNALIGNED_OK
/* UNALIGNED_OK, 16-bit integer comparison */
@@ -101,7 +101,7 @@ int32_t compare258_unaligned_16(const unsigned char *src0, const unsigned char *
#define COMPARE256 compare256_unaligned_16_static
#define COMPARE258 compare258_unaligned_16_static
-#include "match_p.h"
+#include "match_tpl.h"
#ifdef HAVE_BUILTIN_CTZ
/* UNALIGNED_OK, 32-bit integer comparison */
@@ -139,7 +139,7 @@ int32_t compare258_unaligned_32(const unsigned char *src0, const unsigned char *
#define COMPARE256 compare256_unaligned_32_static
#define COMPARE258 compare258_unaligned_32_static
-#include "match_p.h"
+#include "match_tpl.h"
#endif
@@ -179,7 +179,7 @@ int32_t compare258_unaligned_64(const unsigned char *src0, const unsigned char *
#define COMPARE256 compare256_unaligned_64_static
#define COMPARE258 compare258_unaligned_64_static
-#include "match_p.h"
+#include "match_tpl.h"
#endif
diff --git a/match_p.h b/match_tpl.h
index 93aa0d475f..93aa0d475f 100644
--- a/match_p.h
+++ b/match_tpl.h
diff --git a/win32/Makefile.a64 b/win32/Makefile.a64
index 52aafd3606..ece0150725 100644
--- a/win32/Makefile.a64
+++ b/win32/Makefile.a64
@@ -126,9 +126,9 @@ compress.obj: $(SRCDIR)/compress.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h
uncompr.obj: $(SRCDIR)/uncompr.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h
crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32.h
deflate.obj: $(SRCDIR)/deflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
-deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
-deflate_medium.obj: $(SRCDIR)/deflate_medium.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
-deflate_slow.obj: $(SRCDIR)/deflate_slow.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
+deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
+deflate_medium.obj: $(SRCDIR)/deflate_medium.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
+deflate_slow.obj: $(SRCDIR)/deflate_slow.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
infback.obj: $(SRCDIR)/infback.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h
inffast.obj: $(SRCDIR)/inffast.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/memcopy.h
inflate.obj: $(SRCDIR)/inflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/memcopy.h $(SRCDIR)/functable.h
diff --git a/win32/Makefile.arm b/win32/Makefile.arm
index 2c3a82d4e8..2e64886c5d 100644
--- a/win32/Makefile.arm
+++ b/win32/Makefile.arm
@@ -140,9 +140,9 @@ compress.obj: $(SRCDIR)/compress.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h
uncompr.obj: $(SRCDIR)/uncompr.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h
crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32.h
deflate.obj: $(SRCDIR)/deflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
-deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
-deflate_medium.obj: $(SRCDIR)/deflate_medium.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
-deflate_slow.obj: $(SRCDIR)/deflate_slow.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
+deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
+deflate_medium.obj: $(SRCDIR)/deflate_medium.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
+deflate_slow.obj: $(SRCDIR)/deflate_slow.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
infback.obj: $(SRCDIR)/infback.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h
inffast.obj: $(SRCDIR)/inffast.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/memcopy.h
inflate.obj: $(SRCDIR)/inflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/memcopy.h $(SRCDIR)/functable.h
diff --git a/win32/Makefile.msc b/win32/Makefile.msc
index ec24b45f01..e12bc592a5 100644
--- a/win32/Makefile.msc
+++ b/win32/Makefile.msc
@@ -131,10 +131,10 @@ compress.obj: $(SRCDIR)/compress.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h
uncompr.obj: $(SRCDIR)/uncompr.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h
crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32.h
deflate.obj: $(SRCDIR)/deflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
-deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
-deflate_medium.obj: $(SRCDIR)/deflate_medium.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
+deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
+deflate_medium.obj: $(SRCDIR)/deflate_medium.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
deflate_quick.obj: $(SRCDIR)/arch/x86/deflate_quick.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/memcopy.h
-deflate_slow.obj: $(SRCDIR)/deflate_slow.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/match_p.h $(SRCDIR)/functable.h
+deflate_slow.obj: $(SRCDIR)/deflate_slow.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h
infback.obj: $(SRCDIR)/infback.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h
inffast.obj: $(SRCDIR)/inffast.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/memcopy.h
inflate.obj: $(SRCDIR)/inflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/memcopy.h $(SRCDIR)/functable.h