]> Cypherpunks repositories - gostls13.git/commit
runtime: use default system stack size, not 64 kB, on non-cgo macOS
authorRuss Cox <rsc@golang.org>
Wed, 5 Jun 2019 16:31:42 +0000 (12:31 -0400)
committerRuss Cox <rsc@golang.org>
Thu, 6 Jun 2019 00:11:29 +0000 (00:11 +0000)
commitc00ff65d016c07f7feb188ca0458ae3bae0f1532
tree309125bbbc653cb3407df085c55a49e5b54964e0
parente9073ef809895740b3e3876148af808c51c016d5
runtime: use default system stack size, not 64 kB, on non-cgo macOS

At least one libc call we make
(res_search, which calls _mdns_query and then mdns_item_call)
pushes a 64 kB stack frame onto the stack.
Then it faults on the guard page.

Use the default system stack size, under the assumption
that the C code being called is compatible with that stack size.

For #31705.

Change-Id: I1b0bfc2e54043c49f0709255988ef920ce30ee82
Reviewed-on: https://go-review.googlesource.com/c/go/+/180779
Run-TryBot: Russ Cox <rsc@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/runtime/os_darwin.go
src/runtime/sys_darwin.go
src/runtime/sys_darwin_386.s
src/runtime/sys_darwin_amd64.s
src/runtime/sys_darwin_arm.s
src/runtime/sys_darwin_arm64.s