diff options
author | sskvor <sskvor@yandex-team.com> | 2024-12-24 17:42:43 +0300 |
---|---|---|
committer | sskvor <sskvor@yandex-team.com> | 2024-12-24 18:15:03 +0300 |
commit | 8317ba3835dc7e9c854f6472cb686b1e3e3dd7c8 (patch) | |
tree | c4ace4d078ceb17478183cca7832f9ad67cf1fd0 | |
parent | c82d5a2884d9a51553c32c75645f4ae2d1c1c227 (diff) | |
download | ydb-8317ba3835dc7e9c854f6472cb686b1e3e3dd7c8.tar.gz |
[library/cpp/hyperscan] Dropsupport ()
commit_hash:f0e4b9bf3cc217402238bf1efcc4b8695f6a3709
-rw-r--r-- | library/cpp/regex/hyperscan/hyperscan.cpp | 16 | ||||
-rw-r--r-- | library/cpp/regex/hyperscan/hyperscan.h | 2 | ||||
-rw-r--r-- | library/cpp/regex/hyperscan/ut/hyperscan_ut.cpp | 1 | ||||
-rw-r--r-- | library/cpp/regex/hyperscan/ya.make | 1 | ||||
-rw-r--r-- | yql/essentials/udfs/common/hyperscan/test/canondata/test.test_Error_/extracted | 2 |
5 files changed, 4 insertions, 18 deletions
diff --git a/library/cpp/regex/hyperscan/hyperscan.cpp b/library/cpp/regex/hyperscan/hyperscan.cpp index 5b6069d4a3..0a4bfcb9ec 100644 --- a/library/cpp/regex/hyperscan/hyperscan.cpp +++ b/library/cpp/regex/hyperscan/hyperscan.cpp @@ -6,8 +6,6 @@ #include <contrib/libs/hyperscan/runtime_corei7/hs_runtime.h> #include <contrib/libs/hyperscan/runtime_avx2/hs_common.h> #include <contrib/libs/hyperscan/runtime_avx2/hs_runtime.h> -#include <contrib/libs/hyperscan/runtime_avx512/hs_common.h> -#include <contrib/libs/hyperscan/runtime_avx512/hs_runtime.h> #include <util/generic/singleton.h> #include <util/system/sanitizers.h> @@ -19,10 +17,9 @@ namespace NHyperscan { namespace NPrivate { ERuntime DetectCurrentRuntime() { - // TODO: Remove MSanIsOn check upon DEVTOOLSSUPPORT-49258 resolution - if (NX86::HaveAVX512F() && NX86::HaveAVX512BW() && !NSan::MSanIsOn()) { - return ERuntime::AVX512; - } else if (NX86::HaveAVX() && NX86::HaveAVX2()) { + // NOTE: We explicitly disable AVX512 runtime, there are bugs with + // trivial string matching. See SPI-122953 & SPI-117618. + if (NX86::HaveAVX() && NX86::HaveAVX2()) { return ERuntime::AVX2; } else if (NX86::HaveSSE42() && NX86::HavePOPCNT()) { return ERuntime::Corei7; @@ -41,8 +38,6 @@ namespace NHyperscan { return 0; case ERuntime::AVX2: return CPU_FEATURES_AVX2; - case ERuntime::AVX512: - return CPU_FEATURES_AVX512; } } @@ -78,11 +73,6 @@ namespace NHyperscan { SerializeDatabase = avx2_hs_serialize_database; DeserializeDatabase = avx2_hs_deserialize_database; break; - case ERuntime::AVX512: - AllocScratch = avx512_hs_alloc_scratch; - Scan = avx512_hs_scan; - SerializeDatabase = avx512_hs_serialize_database; - DeserializeDatabase = avx512_hs_deserialize_database; } } diff --git a/library/cpp/regex/hyperscan/hyperscan.h b/library/cpp/regex/hyperscan/hyperscan.h index 1c8f404389..eae82fa384 100644 --- a/library/cpp/regex/hyperscan/hyperscan.h +++ b/library/cpp/regex/hyperscan/hyperscan.h @@ -11,7 +11,6 @@ namespace NHyperscan { using TCPUFeatures = decltype(hs_platform_info_t::cpu_features); constexpr TCPUFeatures CPU_FEATURES_AVX2 = HS_CPU_FEATURES_AVX2; - constexpr TCPUFeatures CPU_FEATURES_AVX512 = HS_CPU_FEATURES_AVX512 | HS_CPU_FEATURES_AVX2; template<typename TNativeDeleter, TNativeDeleter NativeDeleter> class TDeleter { @@ -35,7 +34,6 @@ namespace NHyperscan { Core2 = 0, Corei7 = 1, AVX2 = 2, - AVX512 = 3 }; ERuntime DetectCurrentRuntime(); diff --git a/library/cpp/regex/hyperscan/ut/hyperscan_ut.cpp b/library/cpp/regex/hyperscan/ut/hyperscan_ut.cpp index 9caa53f2e7..75cd0bcc89 100644 --- a/library/cpp/regex/hyperscan/ut/hyperscan_ut.cpp +++ b/library/cpp/regex/hyperscan/ut/hyperscan_ut.cpp @@ -210,7 +210,6 @@ Y_UNIT_TEST_SUITE(HyperscanWrappers) { ERuntime::Core2, ERuntime::Corei7, ERuntime::AVX2, - ERuntime::AVX512 }; // Unfortunately, we cannot emulate runtimes with more capabilities than current machine. diff --git a/library/cpp/regex/hyperscan/ya.make b/library/cpp/regex/hyperscan/ya.make index 72abbef9a2..1a052ae214 100644 --- a/library/cpp/regex/hyperscan/ya.make +++ b/library/cpp/regex/hyperscan/ya.make @@ -5,7 +5,6 @@ PEERDIR( contrib/libs/hyperscan/runtime_core2 contrib/libs/hyperscan/runtime_corei7 contrib/libs/hyperscan/runtime_avx2 - contrib/libs/hyperscan/runtime_avx512 ) SRCS( diff --git a/yql/essentials/udfs/common/hyperscan/test/canondata/test.test_Error_/extracted b/yql/essentials/udfs/common/hyperscan/test/canondata/test.test_Error_/extracted index d3707ae88c..21ca8cec79 100644 --- a/yql/essentials/udfs/common/hyperscan/test/canondata/test.test_Error_/extracted +++ b/yql/essentials/udfs/common/hyperscan/test/canondata/test.test_Error_/extracted @@ -3,6 +3,6 @@ <tmp_path>/program.sql:<main>:8:1: Error: Execution of node: YtMap! SELECT $match(value) AS match FROM Input; ^ - <tmp_path>/program.sql:<main>:6:21: Error: library/cpp/regex/hyperscan/hyperscan.cpp:102: Failed to compile regex: ^*$. Error message (hyperscan): Invalid repeat at index 1. + <tmp_path>/program.sql:<main>:6:21: Error: library/cpp/regex/hyperscan/hyperscan.cpp:92: Failed to compile regex: ^*$. Error message (hyperscan): Invalid repeat at index 1. $match = Hyperscan::Match("*"); ^
\ No newline at end of file |