1. 11 Jul, 2013 5 commits
    • Dmitriy Vyukov's avatar
      runtime: fix CPU underutilization · 32fef990
      Dmitriy Vyukov authored
      runtime.newproc/ready are deliberately sloppy about waking new M's,
      they only ensure that there is at least 1 spinning M.
      Currently to compensate for that, schedule() checks if the current P
      has local work and there are no spinning M's, it wakes up another one.
      It does not work if goroutines do not call schedule.
      With this change a spinning M wakes up another M when it finds work to do.
      It's also not ideal, but it fixes the underutilization.
      A proper check would require to know the exact number of runnable G's,
      but it's too expensive to maintain.
      Fixes #5586.
      This is reincarnation of cl/9776044 with the bug fixed.
      The bug was due to code added after cl/9776044 was created:
      if(tick - (((uint64)tick*0x4325c53fu)>>36)*61 == 0 && runtime·sched.runqsize > 0) {
              runtime·lock(&runtime·sched);
              gp = globrunqget(m->p, 1);
              runtime·unlock(&runtime·sched);
      }
      If M gets gp from global runq here, it does not reset m->spinning.
      
      R=golang-dev, rsc
      CC=golang-dev
      https://golang.org/cl/10743044
      32fef990
    • ChaiShushan's avatar
      net/rpc: fix a test bug · 735cf529
      ChaiShushan authored
      R=golang-dev, rsc
      CC=golang-dev
      https://golang.org/cl/10855043
      735cf529
    • Dmitriy Vyukov's avatar
      runtime: adjust traceback for new preemptive reality · 01e1b0cb
      Dmitriy Vyukov authored
      Currently it crashes as follows:
      fatal error: unknown pc
      ...
      goroutine 71698 [runnable]:
      runtime.racegoend()
              src/pkg/runtime/race.c:171
      runtime.goexit()
              src/pkg/runtime/proc.c:1276 +0x9
      created by runtime_test.testConcurrentReadsAfterGrowth
              src/pkg/runtime/map_test.go:264 +0x332
      
      R=golang-dev, rsc
      CC=golang-dev
      https://golang.org/cl/10674047
      01e1b0cb
    • Nigel Tao's avatar
      image/draw: add the Quantizer type. · c77baac5
      Nigel Tao authored
      R=r
      CC=andybons, golang-dev
      https://golang.org/cl/11148043
      c77baac5
    • Russ Cox's avatar
      cmd/ld: correct assignment of sizes to mach-o symbols · a2c30fe6
      Russ Cox authored
      If you compute the size by subtraction from the address
      of the next symbol, it helps to wait until the symbols have
      been sorted by address.
      
      R=golang-dev, r
      CC=golang-dev
      https://golang.org/cl/11143043
      a2c30fe6
  2. 10 Jul, 2013 8 commits
  3. 09 Jul, 2013 5 commits
  4. 08 Jul, 2013 1 commit
  5. 07 Jul, 2013 1 commit
  6. 05 Jul, 2013 5 commits
  7. 04 Jul, 2013 1 commit
  8. 03 Jul, 2013 6 commits
  9. 02 Jul, 2013 8 commits