diff options
author | Siddhesh Poyarekar <siddhesh@redhat.com> | 2012-07-20 23:23:20 +0530 |
---|---|---|
committer | Siddhesh Poyarekar <siddhesh@redhat.com> | 2012-07-20 23:28:34 +0530 |
commit | b2ae49dab80bb00771dd4c29b518f1829690d55b (patch) | |
tree | c00539a38b053050c8d1417a78366361af9e33ae /nptl/ChangeLog | |
parent | d37cbdaa86f484dc5be58be391da739df862bf96 (diff) | |
download | glibc-b2ae49dab80bb00771dd4c29b518f1829690d55b.tar.gz |
Fix tst-pthread-getattr test case
In some cases, the compiler would optimize out the call to
allocate_and_test and thus result in a false positive for the test
case. Another problem was the fact that the compiler could in some
cases generate additional shifting of the stack pointer, resulting in
alloca moving the stack pointer beyond what is allowed by the
rlimit. Hence, accessing the stackaddr returned by pthread_getattr_np
is safer than relying on the alloca'd result.
Another problem is when RLIMIT may be very large, which may result in
violation of other resource limits. Hence we cap the max stack size to
8M for this test.
Diffstat (limited to 'nptl/ChangeLog')
-rw-r--r-- | nptl/ChangeLog | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/nptl/ChangeLog b/nptl/ChangeLog index b9a9dfb4d6..0a1c10fb8a 100644 --- a/nptl/ChangeLog +++ b/nptl/ChangeLog @@ -1,3 +1,13 @@ +2012-07-20 Siddhesh Poyarekar <siddhesh@redhat.com> + + * tst-pthread-getattr.c (MAX_STACK_SIZE): New max cap for stack + size. + (_MIN): New macro. + (allocate_and_test): Return STACKADDR. Access STACKADDR instead + of MEM to test. + (check_stack_top): Read valued written into STACKADDR in + allocate_and_test. Cap stack size to MAX_STACK_SIZE. + 2012-07-19 Siddhesh Poyarekar <siddhesh@redhat.com> * nptl-init.c (sighandler_setxid): Fix the comment that |