Commit f025d19
committed
runtime: hold traceAcquire across casgstatus in injectglist
Currently injectglist emits all the trace events before actually calling
casgstatus on each goroutine. This is a problem, since tracing can
observe an inconsistent state (gstatus does not match tracer's 'emitted
an event' state).
This change fixes the problem by having injectglist do what every other
scheduler function does, and that's wrap each call to casgstatus in
traceAcquire/traceRelease.
Fixes #70883.
Change-Id: I857e96cec01688013597e8efc0c4c3d0b72d3a70
Reviewed-on: https://go-review.googlesource.com/c/go/+/638558
Reviewed-by: Michael Pratt <[email protected]>
LUCI-TryBot-Result: Go LUCI <[email protected]>1 parent 1e9835f commit f025d19
1 file changed
Lines changed: 7 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3894 | 3894 | | |
3895 | 3895 | | |
3896 | 3896 | | |
3897 | | - | |
3898 | | - | |
3899 | | - | |
3900 | | - | |
3901 | | - | |
3902 | | - | |
3903 | | - | |
3904 | 3897 | | |
3905 | 3898 | | |
3906 | 3899 | | |
3907 | 3900 | | |
3908 | 3901 | | |
3909 | 3902 | | |
| 3903 | + | |
3910 | 3904 | | |
3911 | 3905 | | |
3912 | 3906 | | |
3913 | 3907 | | |
| 3908 | + | |
| 3909 | + | |
| 3910 | + | |
| 3911 | + | |
| 3912 | + | |
| 3913 | + | |
3914 | 3914 | | |
3915 | 3915 | | |
3916 | 3916 | | |
| |||
0 commit comments