diff options
author | Austin Clements <austin@google.com> | 2019-10-13 11:27:47 -0400 |
---|---|---|
committer | Austin Clements <austin@google.com> | 2019-11-02 21:51:07 +0000 |
commit | 40b74558771ba9db493728dcaabe43318daf9b97 (patch) | |
tree | 9a93c52f88a3c047ad7a04f3ac55e10baefe8dd6 /src/runtime/runtime1.go | |
parent | bdb5e9d170939a044621ddaa7622ff28d538875d (diff) | |
download | go-40b74558771ba9db493728dcaabe43318daf9b97.tar.gz go-40b74558771ba9db493728dcaabe43318daf9b97.zip |
runtime: add GODEBUG=asyncpreemptoff=1
This doesn't do anything yet, but it will provide a way to disable
non-cooperative preemption.
For #10958, #24543.
Change-Id: Ifdef303f103eabd0922ced8d9bebbd5f0aa2cda4
Reviewed-on: https://go-review.googlesource.com/c/go/+/201757
Run-TryBot: Austin Clements <austin@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Diffstat (limited to 'src/runtime/runtime1.go')
-rw-r--r-- | src/runtime/runtime1.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/runtime/runtime1.go b/src/runtime/runtime1.go index ad29818e0a..180dd7c7e4 100644 --- a/src/runtime/runtime1.go +++ b/src/runtime/runtime1.go @@ -315,6 +315,7 @@ var debug struct { scheddetail int32 schedtrace int32 tracebackancestors int32 + asyncpreemptoff int32 } var dbgvars = []dbgVar{ @@ -334,6 +335,7 @@ var dbgvars = []dbgVar{ {"scheddetail", &debug.scheddetail}, {"schedtrace", &debug.schedtrace}, {"tracebackancestors", &debug.tracebackancestors}, + {"asyncpreemptoff", &debug.asyncpreemptoff}, } func parsedebugvars() { |