[compiler-rt] [nsan] Add NsanThread and clear static TLS shadow (PR #102718)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 9 21:56:50 PDT 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 e0ddd42735b05fd6bee7fc24caeba5464e1a871a f000981885e3866c9a13cf433c9cb9de1999eb2c --extensions c,cpp,h -- compiler-rt/lib/nsan/nsan_thread.cpp compiler-rt/lib/nsan/nsan_thread.h compiler-rt/test/nsan/tls-reuse.c compiler-rt/lib/nsan/nsan.cpp compiler-rt/lib/nsan/nsan_interceptors.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/compiler-rt/test/nsan/tls-reuse.c b/compiler-rt/test/nsan/tls-reuse.c
index 5cf5f3eb71..fdc795a9b4 100644
--- a/compiler-rt/test/nsan/tls-reuse.c
+++ b/compiler-rt/test/nsan/tls-reuse.c
@@ -9,7 +9,7 @@ __thread float x;
static void *ThreadFn(void *a) {
long i = (long)a;
- for (long j = i * 1000; j < (i+1) * 1000; j++)
+ for (long j = i * 1000; j < (i + 1) * 1000; j++)
x += j;
printf("%f\n", x);
return 0;
``````````
</details>
https://github.com/llvm/llvm-project/pull/102718
More information about the llvm-commits
mailing list