aboutsummaryrefslogtreecommitdiff
path: root/libgo/go
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@gcc.gnu.org>2017-07-21 17:50:14 +0000
committerIan Lance Taylor <ian@gcc.gnu.org>2017-07-21 17:50:14 +0000
commit048f0471d203ae4ce74af80b32e4b40ec1d1f1f6 (patch)
tree3c7084a485b8a44b5ee8a461cffa7b3146df19be /libgo/go
parent5a5838e09e1e7fdb51d45c094a570f36de133b93 (diff)
downloadgcc-048f0471d203ae4ce74af80b32e4b40ec1d1f1f6.zip
gcc-048f0471d203ae4ce74af80b32e4b40ec1d1f1f6.tar.gz
gcc-048f0471d203ae4ce74af80b32e4b40ec1d1f1f6.tar.bz2
runtime: allocate more stack space in CgoCallbackGC test
Allocate enough stack space so that the test will work on a system that does not support split stacks. This test is actually not very meaningful for gccgo at present, but it doesn't hurt to keep running it. Updates golang/go#20931 Reviewed-on: https://go-review.googlesource.com/50630 From-SVN: r250433
Diffstat (limited to 'libgo/go')
-rw-r--r--libgo/go/runtime/testdata/testprogcgo/callback.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/libgo/go/runtime/testdata/testprogcgo/callback.go b/libgo/go/runtime/testdata/testprogcgo/callback.go
index 7b58f4a..a49fc19 100644
--- a/libgo/go/runtime/testdata/testprogcgo/callback.go
+++ b/libgo/go/runtime/testdata/testprogcgo/callback.go
@@ -23,7 +23,9 @@ static void foo() {
pthread_t th;
pthread_attr_t attr;
pthread_attr_init(&attr);
- pthread_attr_setstacksize(&attr, 256 << 10);
+ // For gccgo use a stack size large enough for all the callbacks,
+ // in case we are on a platform that does not support -fsplit-stack.
+ pthread_attr_setstacksize(&attr, 512 * 10000);
pthread_create(&th, &attr, thr, 0);
pthread_join(th, 0);
}