[compiler-rt] [ASan][Win][compiler-rt] Fixes stack overflow when ntdll has mem* calls during exception handling (PR #120110)

via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 16 08:43:31 PST 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff 3c3094b60d3587b1db8ef35b3bf54e73ac5894d9 b7325c4fbb3c71ae832a9c658334c5fda74d92cc --extensions cpp,h -- compiler-rt/lib/asan/asan_interceptors_memintrinsics.cpp compiler-rt/lib/asan/asan_poisoning.h compiler-rt/lib/asan/asan_rtl.cpp compiler-rt/lib/sanitizer_common/sanitizer_win.cpp compiler-rt/lib/sanitizer_common/sanitizer_win.h
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/compiler-rt/lib/asan/asan_interceptors_memintrinsics.cpp b/compiler-rt/lib/asan/asan_interceptors_memintrinsics.cpp
index 0e27d868df..68b02f981a 100644
--- a/compiler-rt/lib/asan/asan_interceptors_memintrinsics.cpp
+++ b/compiler-rt/lib/asan/asan_interceptors_memintrinsics.cpp
@@ -53,9 +53,9 @@ bool ShouldReplaceIntrinsic(bool isNtdllCallee, void *addr, uptr size,
 using namespace __asan;
 
 #if SANITIZER_WINDOWS64
-#define IS_NTDLL_CALLEE __sanitizer::IsNtdllCallee(_ReturnAddress())
+#  define IS_NTDLL_CALLEE __sanitizer::IsNtdllCallee(_ReturnAddress())
 #else
-#define IS_NTDLL_CALLEE false
+#  define IS_NTDLL_CALLEE false
 #endif
 
 // memcpy is called during __asan_init() from the internals of printf(...).

``````````

</details>


https://github.com/llvm/llvm-project/pull/120110


More information about the llvm-commits mailing list