This is an automated email from the ASF dual-hosted git repository.
yiguolei pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push:
new 512806f902 [fix](ubsan) UBSAN avoid thread local switch
512806f902 is described below
commit 512806f902f620158241e3b728da356da5c1a1e0
Author: Xinyi Zou <[email protected]>
AuthorDate: Sat May 20 07:14:43 2023 +0800
[fix](ubsan) UBSAN avoid thread local switch
---
be/src/runtime/thread_context.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/be/src/runtime/thread_context.h b/be/src/runtime/thread_context.h
index 9d4a88de7b..c6f6a46c4e 100644
--- a/be/src/runtime/thread_context.h
+++ b/be/src/runtime/thread_context.h
@@ -37,7 +37,7 @@
#include "util/defer_op.h" // IWYU pragma: keep
// Used to observe the memory usage of the specified code segment
-#ifdef USE_MEM_TRACKER
+#if defined(USE_MEM_TRACKER) && !defined(UNDEFINED_BEHAVIOR_SANITIZER)
// Count a code segment memory (memory malloc - memory free) to int64_t
// Usage example: int64_t scope_mem = 0; { SCOPED_MEM_COUNT(&scope_mem); xxx;
xxx; }
#define SCOPED_MEM_COUNT(scope_mem) \
@@ -56,7 +56,7 @@
#endif
// Used to observe query/load/compaction/e.g. execution thread memory usage
and respond when memory exceeds the limit.
-#ifdef USE_MEM_TRACKER
+#if defined(USE_MEM_TRACKER) && !defined(UNDEFINED_BEHAVIOR_SANITIZER)
// Attach to query/load/compaction/e.g. when thread starts.
// This will save some info about a working thread in the thread context.
// And count the memory during thread execution (is actually also the code
segment that executes the function)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]