Skip to content

Commit

Permalink
Skip msan and tsan
Browse files Browse the repository at this point in the history
  • Loading branch information
Mochi Xu authored and Shanfeng Pang committed Apr 16, 2024
1 parent 484e551 commit 1c58bd0
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 13 deletions.
21 changes: 14 additions & 7 deletions programs/server/Server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -458,29 +458,36 @@ void setOOMScore(int value, Poco::Logger * log)

extern "C" void tantivy_log_callback(int level, const char * thread_info, const char * message)
{
#if defined(MEMORY_SANITIZER)
__msan_unpoison_string(thread_info);
__msan_unpoison_string(message);
#endif
// Ensure that null pointers are replaced with empty strings
const char * safe_thread_info = thread_info ? thread_info : "";
const char * safe_message = message ? message : "";
Poco::Logger & logger = Poco::Logger::get("TantivyLibrary");
switch (level)
{
case -2: // -2 -> fatal
LOG_FATAL(&logger, "{} - {}", thread_info, message);
LOG_FATAL(&logger, "{} - {}", safe_thread_info, safe_message);
break;
case -1: // -1 -> error
LOG_ERROR(&logger, "{} - {}", thread_info, message);
LOG_ERROR(&logger, "{} - {}", safe_thread_info, safe_message);
break;
case 0: // 0 -> warning
LOG_WARNING(&logger, "{} - {}", thread_info, message);
LOG_WARNING(&logger, "{} - {}", safe_thread_info, safe_message);
break;
case 1: // 1 -> info
LOG_INFO(&logger, "{} - {}", thread_info, message);
LOG_INFO(&logger, "{} - {}", safe_thread_info, safe_message);
break;
case 2: // 2 -> debug
LOG_DEBUG(&logger, "{} - {}", thread_info, message);
LOG_DEBUG(&logger, "{} - {}", safe_thread_info, safe_message);
break;
case 3: // 3 -> tracing
LOG_TRACE(&logger, "{} - {}", thread_info, message);
LOG_TRACE(&logger, "{} - {}", safe_thread_info, safe_message);
break;
default:
LOG_DEBUG(&logger, "{} - {}", thread_info, message);
LOG_DEBUG(&logger, "{} - {}", safe_thread_info, safe_message);
}
}

Expand Down
2 changes: 1 addition & 1 deletion rust/supercrate/libs/tantivy_search
Submodule tantivy_search updated from dd4e0e to 06a58e
2 changes: 1 addition & 1 deletion src/Core/Settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ class IColumn;
M(UInt64, merge_tree_max_rows_to_use_cache, (128 * 8192), "The maximum number of rows per request, to use the cache of uncompressed data. If the request is large, the cache is not used. (For large queries not to flush out the cache.)", 0) \
M(UInt64, merge_tree_max_bytes_to_use_cache, (192 * 10 * 1024 * 1024), "The maximum number of bytes per request, to use the cache of uncompressed data. If the request is large, the cache is not used. (For large queries not to flush out the cache.)", 0) \
M(Bool, do_not_merge_across_partitions_select_final, false, "Merge parts only in one partition in select final", 0) \
M(Bool, allow_experimental_inverted_index, false, "If it is set to true, allow to use experimental inverted index.", 0) \
M(Bool, allow_experimental_inverted_index, true, "If it is set to true, allow to use experimental inverted index.", 0) \
\
M(UInt64, mysql_max_rows_to_insert, 65536, "The maximum number of rows in MySQL batch insertion of the MySQL storage engine", 0) \
\
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
-- Tags: no-tsan, no-msan

SET allow_experimental_inverted_index = 1;
SET log_queries = 1;
SET mutations_sync = 1;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
-- Tags: no-tsan, no-msan

SET allow_experimental_inverted_index = 1;
SET log_queries = 1;
SET mutations_sync = 1;
Expand Down
4 changes: 0 additions & 4 deletions tests/tsan_suppressions.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1 @@
# We have no suppressions!
src:*/TantivyIndexStoreStorages/MergeTree/TantivyIndexStore.cpp*
src:*/tantivy_search/*
func:__interceptor_memmove
func:memcpy

0 comments on commit 1c58bd0

Please sign in to comment.