runtime: do not park sysmon thread if any goroutines are running Sysmon thread parks if no goroutines are running (runtime.sched.npidle == runtime.gomaxprocs). Currently it's unparked when a goroutine enters syscall, it was enough to retake P's from blocking syscalls. But it's not enough for reliable goroutine preemption. We need to ensure that sysmon runs if any goroutines are running.
runtime: do not park sysmon thread if any goroutines are running
Sysmon thread parks if no goroutines are running (runtime.sched.npidle == runtime.gomaxprocs).
Currently it's unparked when a goroutine enters syscall, it was enough
to retake P's from blocking syscalls.
But it's not enough for reliable goroutine preemption. We need to ensure that
sysmon runs if any goroutines are running.

R=golang-dev, rsc
CC=golang-dev
https://codereview.appspot.com/12167043

tv42/old-go,apparentlymart/golang,pombredanne/go-deleteme,pombredanne/go-deleteme,apparentlymart/golang,pombredanne/go-deleteme,tv42/old-go,apparentlymart/golang,tv42/old-go,apparentlymart/golang,tv42/old-go,tv42/old-go,tv42/old-go,apparentlymart/golang,apparentlymart/golang,apparentlymart/golang,pombredanne/go-deleteme,tv42/old-go,pombredanne/go-deleteme,pombredanne/go-deleteme,pombredanne/go-deleteme