From: Dmitriy Vyukov Date: Tue, 13 Aug 2013 10:14:24 +0000 (+0400) Subject: runtime: eliminate excessive notewakeup calls in timers X-Git-Tag: go1.2rc2~634 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=d1b66439f91377bceee1dd190a0be6c8367f7268;p=gostls13.git runtime: eliminate excessive notewakeup calls in timers If the timer goroutine is wakeup by timeout, other goroutines will still notewakeup because sleeping is still set. R=golang-dev, r CC=golang-dev https://golang.org/cl/12763043 --- diff --git a/src/pkg/runtime/time.goc b/src/pkg/runtime/time.goc index 4f20300ff1..6670b45ba9 100644 --- a/src/pkg/runtime/time.goc +++ b/src/pkg/runtime/time.goc @@ -175,6 +175,7 @@ timerproc(void) for(;;) { runtime·lock(&timers); + timers.sleeping = false; now = runtime·nanotime(); for(;;) { if(timers.len == 0) {