Fix compiler warning on ARM64 with JIT.

This commit is contained in:
Zoltán Herczeg 2020-01-31 10:09:38 +00:00
parent ed8a3146b9
commit d71dc302a5
1 changed files with 26 additions and 4 deletions

View File

@ -117,11 +117,16 @@ PCRE2_UCHAR char2a = ic.c.c3;
# ifdef FFCPS_CHAR1A2A # ifdef FFCPS_CHAR1A2A
cmp1a = VDUPQ(char1a); cmp1a = VDUPQ(char1a);
cmp2a = VDUPQ(char2a); cmp2a = VDUPQ(char2a);
cmp1b = VDUPQ(0); /* to avoid errors on older compilers -Werror=maybe-uninitialized */
cmp2b = VDUPQ(0); /* to avoid errors on older compilers -Werror=maybe-uninitialized */
# else # else
PCRE2_UCHAR char1b = ic.c.c2; PCRE2_UCHAR char1b = ic.c.c2;
PCRE2_UCHAR char2b = ic.c.c4; PCRE2_UCHAR char2b = ic.c.c4;
if (char1a == char1b) if (char1a == char1b)
{
cmp1a = VDUPQ(char1a); cmp1a = VDUPQ(char1a);
cmp1b = VDUPQ(0); /* to avoid errors on older compilers -Werror=maybe-uninitialized */
}
else else
{ {
sljit_u32 bit1 = char1a ^ char1b; sljit_u32 bit1 = char1a ^ char1b;
@ -140,7 +145,10 @@ else
} }
if (char2a == char2b) if (char2a == char2b)
{
cmp2a = VDUPQ(char2a); cmp2a = VDUPQ(char2a);
cmp2b = VDUPQ(0); /* to avoid errors on older compilers -Werror=maybe-uninitialized */
}
else else
{ {
sljit_u32 bit2 = char2a ^ char2b; sljit_u32 bit2 = char2a ^ char2b;
@ -208,8 +216,16 @@ if (p1 < str_ptr)
else else
data2 = shift_left_n_lanes(data, offs1 - offs2); data2 = shift_left_n_lanes(data, offs1 - offs2);
data = fast_forward_char_pair_compare(compare1_type, data, cmp1a, cmp1b); if (compare1_type == compare_match1)
data2 = fast_forward_char_pair_compare(compare2_type, data2, cmp2a, cmp2b); data = VCEQQ(data, cmp1a);
else
data = fast_forward_char_pair_compare(compare1_type, data, cmp1a, cmp1b);
if (compare2_type == compare_match1)
data2 = VCEQQ(data2, cmp2a);
else
data2 = fast_forward_char_pair_compare(compare2_type, data2, cmp2a, cmp2b);
vect_t eq = VANDQ(data, data2); vect_t eq = VANDQ(data, data2);
#endif #endif
@ -275,8 +291,14 @@ while (str_ptr < str_end)
data = VCEQQ(data, cmp1a); data = VCEQQ(data, cmp1a);
data2 = VCEQQ(data2, cmp2a); data2 = VCEQQ(data2, cmp2a);
# else # else
data = fast_forward_char_pair_compare(compare1_type, data, cmp1a, cmp1b); if (compare1_type == compare_match1)
data2 = fast_forward_char_pair_compare(compare2_type, data2, cmp2a, cmp2b); data = VCEQQ(data, cmp1a);
else
data = fast_forward_char_pair_compare(compare1_type, data, cmp1a, cmp1b);
if (compare2_type == compare_match1)
data2 = VCEQQ(data2, cmp2a);
else
data2 = fast_forward_char_pair_compare(compare2_type, data2, cmp2a, cmp2b);
# endif # endif
eq = VANDQ(data, data2); eq = VANDQ(data, data2);