aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/string.go
diff options
context:
space:
mode:
authorCherry Mui <cherryyz@google.com>2021-05-21 13:37:19 -0400
committerCherry Mui <cherryyz@google.com>2021-05-21 22:40:36 +0000
commit626e89c261297d13ef892bb569640cd72c35b98a (patch)
tree1df4d16feb06a16f2e81735fe971a4bf53323ca9 /src/runtime/string.go
parent6a81e063dd0bf28d21b7085cc1d9e76eaeb78460 (diff)
downloadgo-626e89c261297d13ef892bb569640cd72c35b98a.tar.xz
[dev.typeparams] runtime: replace funcPC with internal/abi.FuncPCABIInternal
At this point all funcPC references are ABIInternal functions. Replace with the intrinsics. Change-Id: I3ba7e485c83017408749b53f92877d3727a75e27 Reviewed-on: https://go-review.googlesource.com/c/go/+/321954 Trust: Cherry Mui <cherryyz@google.com> Run-TryBot: Cherry Mui <cherryyz@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Michael Knyszek <mknyszek@google.com>
Diffstat (limited to 'src/runtime/string.go')
-rw-r--r--src/runtime/string.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/runtime/string.go b/src/runtime/string.go
index d6030a1dca..3c215d3754 100644
--- a/src/runtime/string.go
+++ b/src/runtime/string.go
@@ -5,6 +5,7 @@
package runtime
import (
+ "internal/abi"
"internal/bytealg"
"runtime/internal/sys"
"unsafe"
@@ -88,7 +89,7 @@ func slicebytetostring(buf *tmpBuf, ptr *byte, n int) (str string) {
racereadrangepc(unsafe.Pointer(ptr),
uintptr(n),
getcallerpc(),
- funcPC(slicebytetostring))
+ abi.FuncPCABIInternal(slicebytetostring))
}
if msanenabled {
msanread(unsafe.Pointer(ptr), uintptr(n))
@@ -152,7 +153,7 @@ func slicebytetostringtmp(ptr *byte, n int) (str string) {
racereadrangepc(unsafe.Pointer(ptr),
uintptr(n),
getcallerpc(),
- funcPC(slicebytetostringtmp))
+ abi.FuncPCABIInternal(slicebytetostringtmp))
}
if msanenabled && n > 0 {
msanread(unsafe.Pointer(ptr), uintptr(n))
@@ -203,7 +204,7 @@ func slicerunetostring(buf *tmpBuf, a []rune) string {
racereadrangepc(unsafe.Pointer(&a[0]),
uintptr(len(a))*unsafe.Sizeof(a[0]),
getcallerpc(),
- funcPC(slicerunetostring))
+ abi.FuncPCABIInternal(slicerunetostring))
}
if msanenabled && len(a) > 0 {
msanread(unsafe.Pointer(&a[0]), uintptr(len(a))*unsafe.Sizeof(a[0]))