From: George Wort Date: Tue, 22 Jun 2021 11:34:35 +0000 (+0100) Subject: Fix error in initial noodle double final call. X-Git-Tag: v5.4.3+vectorscan~103 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d1009e8830e7337bf46328b7691f0ebe4054c821;p=thirdparty%2Fvectorscan.git Fix error in initial noodle double final call. Change-Id: Ie044988f183b47e0b2f1eed3b4bd23de75c3117d --- diff --git a/src/hwlm/noodle_engine_simd.hpp b/src/hwlm/noodle_engine_simd.hpp index 510f179e..7a535e8f 100644 --- a/src/hwlm/noodle_engine_simd.hpp +++ b/src/hwlm/noodle_engine_simd.hpp @@ -108,7 +108,7 @@ hwlm_error_t scanDoubleUnaligned(const struct noodTable *n, const u8 *buf, SuperVector caseMask, SuperVector mask1, SuperVector mask2, typename SuperVector::movemask_type *lastz1, const struct cb_info *cbi, size_t len, size_t start, size_t end) { const u8 *d = buf + start; - DEBUG_PRINTF("start %zu end %zu", start, end); + DEBUG_PRINTF("start %zu end %zu\n", start, end); const size_t l = end - start; assert(l <= S); if (!l) { diff --git a/src/hwlm/noodle_engine_sve.hpp b/src/hwlm/noodle_engine_sve.hpp index 41329737..3c0931a8 100644 --- a/src/hwlm/noodle_engine_sve.hpp +++ b/src/hwlm/noodle_engine_sve.hpp @@ -245,7 +245,7 @@ hwlm_error_t scanDouble(const struct noodTable *n, const u8 *buf, size_t len, // Check first position in scalar so as to remove underflow possibilities. size_t matchPos = d - buf; DEBUG_PRINTF("Test match pos %zu\n", matchPos); - RETURN_IF_TERMINATED(final(n, d, len, true, cbi, matchPos)); + RETURN_IF_TERMINATED(final(n, buf, len, true, cbi, matchPos)); d += 2; if (d >= e) { return HWLM_SUCCESS;