summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorReid Kleckner <rnk@google.com>2016-04-04 18:27:32 +0000
committerReid Kleckner <rnk@google.com>2016-04-04 18:27:32 +0000
commit5e263ef18766b562a05aa6736d6c7ea3c8af3b4e (patch)
treea477cb00e20bfe714383abe76922fed27677f2bb /test
parentc651d88e495a25aaa6e2369ee969e67f693d3ade (diff)
Apply suggestion from HJ Lu to avoid misaligned stack in test
Fixes PR27191 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@265322 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/asan/TestCases/Linux/clone_test.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/asan/TestCases/Linux/clone_test.cc b/test/asan/TestCases/Linux/clone_test.cc
index e9c1f166e..f6eb26100 100644
--- a/test/asan/TestCases/Linux/clone_test.cc
+++ b/test/asan/TestCases/Linux/clone_test.cc
@@ -22,7 +22,7 @@ int Child(void *arg) {
int main(int argc, char **argv) {
const int kStackSize = 1 << 20;
- char child_stack[kStackSize + 1];
+ char __attribute__((aligned(16))) child_stack[kStackSize + 1];
char *sp = child_stack + kStackSize; // Stack grows down.
printf("Parent: %p\n", sp);
pid_t clone_pid = clone(Child, sp, CLONE_FILES | CLONE_VM, NULL);