]> Cypherpunks.ru repositories - gostls13.git/blobdiff - src/runtime/signal_unix.go
[dev.typeparams] all: merge master (16e82be) into dev.typeparams
[gostls13.git] / src / runtime / signal_unix.go
index 0b3414d45781d08a2282e026d3d6560cec74f73c..8117582855db02d55e1b874a4f71630427f8ed30 100644 (file)
@@ -281,6 +281,8 @@ func setProcessCPUProfiler(hz int32) {
                it.it_value = it.it_interval
                setitimer(_ITIMER_PROF, &it, nil)
        } else {
+               setitimer(_ITIMER_PROF, &itimerval{}, nil)
+
                // If the Go signal handler should be disabled by default,
                // switch back to the signal handler that was installed
                // when we enabled profiling. We don't try to handle the case
@@ -304,8 +306,6 @@ func setProcessCPUProfiler(hz int32) {
                                setsig(_SIGPROF, h)
                        }
                }
-
-               setitimer(_ITIMER_PROF, &itimerval{}, nil)
        }
 }
 
@@ -383,7 +383,7 @@ func preemptM(mp *m) {
 //go:nosplit
 func sigFetchG(c *sigctxt) *g {
        switch GOARCH {
-       case "arm", "arm64":
+       case "arm", "arm64", "ppc64", "ppc64le":
                if !iscgo && inVDSOPage(c.sigpc()) {
                        // When using cgo, we save the g on TLS and load it from there
                        // in sigtramp. Just use that.