diff options
author | Cherry Zhang <cherryyz@google.com> | 2018-04-26 14:06:08 -0400 |
---|---|---|
committer | Cherry Zhang <cherryyz@google.com> | 2018-04-26 18:57:20 +0000 |
commit | 22f4280b9ac4194d48e0426f3b9743158724ae94 (patch) | |
tree | c0bba7a7eab190392b6266439cf31cc6df55ae8d /src/runtime/cgocall.go | |
parent | a3bafcf8ccb55b130c10cbf45e44ab77823672a1 (diff) | |
download | go-22f4280b9ac4194d48e0426f3b9743158724ae94.tar.gz go-22f4280b9ac4194d48e0426f3b9743158724ae94.zip |
runtime: remove the dummy arg of getcallersp
getcallersp is intrinsified, and so the dummy arg is no longer
needed. Remove it, as well as a few dummy args that are solely
to feed getcallersp.
Change-Id: Ibb6c948ff9c56537042b380ac3be3a91b247aaa6
Reviewed-on: https://go-review.googlesource.com/109596
Run-TryBot: Cherry Zhang <cherryyz@google.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/runtime/cgocall.go')
-rw-r--r-- | src/runtime/cgocall.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/runtime/cgocall.go b/src/runtime/cgocall.go index a06bed20f5..c85033f4bc 100644 --- a/src/runtime/cgocall.go +++ b/src/runtime/cgocall.go @@ -125,7 +125,7 @@ func cgocall(fn, arg unsafe.Pointer) int32 { // "system call", run the Go code (which may grow the stack), // and then re-enter the "system call" reusing the PC and SP // saved by entersyscall here. - entersyscall(0) + entersyscall() mp.incgo = true errno := asmcgocall(fn, arg) @@ -134,7 +134,7 @@ func cgocall(fn, arg unsafe.Pointer) int32 { // reschedule us on to a different M. endcgo(mp) - exitsyscall(0) + exitsyscall() // From the garbage collector's perspective, time can move // backwards in the sequence above. If there's a callback into @@ -188,7 +188,7 @@ func cgocallbackg(ctxt uintptr) { // save syscall* and let reentersyscall restore them. savedsp := unsafe.Pointer(gp.syscallsp) savedpc := gp.syscallpc - exitsyscall(0) // coming out of cgo call + exitsyscall() // coming out of cgo call gp.m.incgo = false cgocallbackg1(ctxt) |