aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/debugcall.go
diff options
context:
space:
mode:
authorCherry Zhang <cherryyz@google.com>2020-10-21 20:43:16 -0400
committerCherry Zhang <cherryyz@google.com>2020-10-30 21:13:24 +0000
commit8414b1a5a40e5ef19508e4895b4c12a91fa498e7 (patch)
treeb65be785a3ade7b8d8c627313de8affe68f2a8be /src/runtime/debugcall.go
parent420c68dd68c648af6642dd7e5cf6dacf9f067f6e (diff)
downloadgo-8414b1a5a40e5ef19508e4895b4c12a91fa498e7.tar.xz
runtime: remove go115ReduceLiveness and go115RestartSeq
Make them always true. Delete code that are only executed when they are false. Change-Id: I6194fa00de23486c2b0a0c9075fe3a09d9c52762 Reviewed-on: https://go-review.googlesource.com/c/go/+/264339 Trust: Cherry Zhang <cherryyz@google.com> Reviewed-by: Austin Clements <austin@google.com>
Diffstat (limited to 'src/runtime/debugcall.go')
-rw-r--r--src/runtime/debugcall.go34
1 files changed, 8 insertions, 26 deletions
diff --git a/src/runtime/debugcall.go b/src/runtime/debugcall.go
index b5480c73ae..efc68a767d 100644
--- a/src/runtime/debugcall.go
+++ b/src/runtime/debugcall.go
@@ -76,32 +76,14 @@ func debugCallCheck(pc uintptr) string {
return
}
- if !go115ReduceLiveness {
- // Look up PC's register map.
- pcdata := int32(-1)
- if pc != f.entry {
- pc--
- pcdata = pcdatavalue(f, _PCDATA_RegMapIndex, pc, nil)
- }
- if pcdata == -1 {
- pcdata = 0 // in prologue
- }
- stkmap := (*stackmap)(funcdata(f, _FUNCDATA_RegPointerMaps))
- if pcdata == _PCDATA_RegMapUnsafe || stkmap == nil {
- // Not at a safe point.
- ret = debugCallUnsafePoint
- return
- }
- } else {
- // Check that this isn't an unsafe-point.
- if pc != f.entry {
- pc--
- }
- up := pcdatavalue(f, _PCDATA_UnsafePoint, pc, nil)
- if up != _PCDATA_UnsafePointSafe {
- // Not at a safe point.
- ret = debugCallUnsafePoint
- }
+ // Check that this isn't an unsafe-point.
+ if pc != f.entry {
+ pc--
+ }
+ up := pcdatavalue(f, _PCDATA_UnsafePoint, pc, nil)
+ if up != _PCDATA_UnsafePointSafe {
+ // Not at a safe point.
+ ret = debugCallUnsafePoint
}
})
return ret