mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
runtime: don't panic in castogscanstatus
The panic calls gopanic which may have write barriers, but castogscanstatus is called from //go:nowritebarrier contexts. The panic is dead code anyway, and appears immediately before a call to 'throw'. Change-Id: I4a8e296b71bf002295a3aa1db4f723c305ed939a Reviewed-on: https://go-review.googlesource.com/c/go/+/717406 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Cherry Mui <cherryyz@google.com>
This commit is contained in:
parent
43491f8d52
commit
b5353fd90a
1 changed files with 2 additions and 2 deletions
|
|
@ -1254,8 +1254,8 @@ func castogscanstatus(gp *g, oldval, newval uint32) bool {
|
|||
}
|
||||
}
|
||||
print("runtime: castogscanstatus oldval=", hex(oldval), " newval=", hex(newval), "\n")
|
||||
throw("castogscanstatus")
|
||||
panic("not reached")
|
||||
throw("bad oldval passed to castogscanstatus")
|
||||
return false
|
||||
}
|
||||
|
||||
// casgstatusAlwaysTrack is a debug flag that causes casgstatus to always track
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue