[compiler-rt] [asan, test] Make alloca_loop_unpoisoning.cpp robust and fix s390x failure (PR #78774)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 19 12:13:59 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 0784b1eefa36d4acbb0dacd2d18796e26313b6c5 3833b05746922726eb5a8b512a8a9f5caf7a96c5 -- compiler-rt/test/asan/TestCases/alloca_loop_unpoisoning.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/compiler-rt/test/asan/TestCases/alloca_loop_unpoisoning.cpp b/compiler-rt/test/asan/TestCases/alloca_loop_unpoisoning.cpp
index bf84ab3d20..0967b34dc7 100644
--- a/compiler-rt/test/asan/TestCases/alloca_loop_unpoisoning.cpp
+++ b/compiler-rt/test/asan/TestCases/alloca_loop_unpoisoning.cpp
@@ -25,12 +25,14 @@ __attribute__((noinline)) void foo(int len) {
char x;
top = &x;
volatile char array[len];
- if (len) array[0] = 0;
+ if (len)
+ array[0] = 0;
assert(!(reinterpret_cast<uintptr_t>(array) & 31L));
alloca(len);
for (int i = 0; i < 32; ++i) {
volatile char array[i];
- if (i) array[0] = 0;
+ if (i)
+ array[0] = 0;
bot = alloca(i);
assert(!(reinterpret_cast<uintptr_t>(bot) & 31L));
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/78774
More information about the llvm-commits
mailing list