Skip to content

Commit

Permalink
fix pcNameFileLine in runtime_go1.21.go
Browse files Browse the repository at this point in the history
  • Loading branch information
phuslu committed May 5, 2024
1 parent 904dc61 commit 7136d3a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions runtime_go1.21.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ type inlineFrame struct {
}

type srcFunc struct {
datap *uintptr
datap unsafe.Pointer
nameOff int32
startLine int32
funcID uint8
Expand All @@ -57,7 +57,7 @@ func pcNameFileLine(pc uintptr) (name, file string, line int32) {

// It's important that interpret pc non-strictly as cgoTraceback may
// have added bogus PCs with a valid funcInfo but invalid PCDATA.
u, uf := newInlineUnwinder(funcInfo, pc)
u, uf := newInlineUnwinder(funcInfo, pc, nil)
sf := inlineUnwinder_srcFunc(&u, uf)
name = srcFunc_name(sf)
// name = funcNameForPrint(srcFunc_name(sf))
Expand All @@ -66,7 +66,7 @@ func pcNameFileLine(pc uintptr) (name, file string, line int32) {
}

//go:linkname newInlineUnwinder runtime.newInlineUnwinder
func newInlineUnwinder(f funcInfo, pc uintptr) (inlineUnwinder, inlineFrame)
func newInlineUnwinder(f funcInfo, pc uintptr, cache unsafe.Pointer) (inlineUnwinder, inlineFrame)

//go:linkname inlineUnwinder_srcFunc runtime.(*inlineUnwinder).srcFunc
func inlineUnwinder_srcFunc(*inlineUnwinder, inlineFrame) srcFunc
Expand Down

0 comments on commit 7136d3a

Please sign in to comment.