aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/signal_amd64.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/signal_amd64.go')
-rw-r--r--src/runtime/signal_amd64.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/runtime/signal_amd64.go b/src/runtime/signal_amd64.go
index e45fbb4a87..20490cffbf 100644
--- a/src/runtime/signal_amd64.go
+++ b/src/runtime/signal_amd64.go
@@ -9,7 +9,8 @@
package runtime
import (
- "runtime/internal/sys"
+ "internal/abi"
+ "internal/goarch"
"unsafe"
)
@@ -70,17 +71,17 @@ func (c *sigctxt) preparePanic(sig uint32, gp *g) {
// Go special registers. We inject sigpanic0 (instead of sigpanic),
// which takes care of that.
if shouldPushSigpanic(gp, pc, *(*uintptr)(unsafe.Pointer(sp))) {
- c.pushCall(funcPC(sigpanic0), pc)
+ c.pushCall(abi.FuncPCABI0(sigpanic0), pc)
} else {
// Not safe to push the call. Just clobber the frame.
- c.set_rip(uint64(funcPC(sigpanic0)))
+ c.set_rip(uint64(abi.FuncPCABI0(sigpanic0)))
}
}
func (c *sigctxt) pushCall(targetPC, resumePC uintptr) {
// Make it look like we called target at resumePC.
sp := uintptr(c.rsp())
- sp -= sys.PtrSize
+ sp -= goarch.PtrSize
*(*uintptr)(unsafe.Pointer(sp)) = resumePC
c.set_rsp(uint64(sp))
c.set_rip(uint64(targetPC))