]> Cypherpunks repositories - gostls13.git/commit
syscall: implement rawVforkSyscall for remaining linux platforms
authorJoel Sing <joel@sing.id.au>
Tue, 7 May 2019 07:56:49 +0000 (17:56 +1000)
committerJoel Sing <joel@sing.id.au>
Wed, 3 Mar 2021 05:33:21 +0000 (05:33 +0000)
commit00cb841b83ad157bc21d36daf0626bbcd4af0d57
tree10d3c992346b69236eb1356bfd381cc5e4f49584
parentf2df1e3c34ceb2225d0df5c9ec92d5dc9e9ba919
syscall: implement rawVforkSyscall for remaining linux platforms

This allows the use of CLONE_VFORK and CLONE_VM for fork/exec, preventing
'fork/exec ...: cannot allocate memory' failures from occuring when attempting
to execute commands from a Go process that has a large memory footprint.
Additionally, this should reduce the latency of fork/exec on these platforms.

Fixes #31936

Change-Id: I4e28cf0763173145cacaa5340680dca9ff449305
Reviewed-on: https://go-review.googlesource.com/c/go/+/295849
Trust: Joel Sing <joel@sing.id.au>
Run-TryBot: Joel Sing <joel@sing.id.au>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
src/syscall/asm_linux_386.s
src/syscall/asm_linux_amd64.s
src/syscall/asm_linux_arm.s
src/syscall/asm_linux_arm64.s
src/syscall/asm_linux_mips64x.s
src/syscall/asm_linux_mipsx.s
src/syscall/exec_linux.go
src/syscall/syscall_linux_386.go
src/syscall/syscall_linux_arm.go
src/syscall/syscall_linux_mips64x.go
src/syscall/syscall_linux_mipsx.go