aboutsummaryrefslogtreecommitdiff
path: root/src/pkg/runtime/proc.c
diff options
context:
space:
mode:
authorDmitriy Vyukov <dvyukov@google.com>2014-01-21 11:20:23 +0400
committerDmitriy Vyukov <dvyukov@google.com>2014-01-21 11:20:23 +0400
commit1ba04c171a3c3a1ea0e5157e8340b606ec9d8949 (patch)
tree4f83adad4db1e331a5cc4b6d32643e176fb4ea57 /src/pkg/runtime/proc.c
parentabd588aa835fa3f462640cc8eba6d192a8462667 (diff)
downloadgo-1ba04c171a3c3a1ea0e5157e8340b606ec9d8949.tar.xz
runtime: per-P defer pool
Instead of a per-goroutine stack of defers for all sizes, introduce per-P defer pool for argument sizes 8, 24, 40, 56, 72 bytes. For a program that starts 1e6 goroutines and then joins then: old: rss=6.6g virtmem=10.2g time=4.85s new: rss=4.5g virtmem= 8.2g time=3.48s R=golang-codereviews, rsc CC=golang-codereviews https://golang.org/cl/42750044
Diffstat (limited to 'src/pkg/runtime/proc.c')
-rw-r--r--src/pkg/runtime/proc.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/pkg/runtime/proc.c b/src/pkg/runtime/proc.c
index 693cacaa58..47012ae550 100644
--- a/src/pkg/runtime/proc.c
+++ b/src/pkg/runtime/proc.c
@@ -204,7 +204,6 @@ runtimeĀ·main(void)
d.link = g->defer;
d.argp = (void*)-1;
d.special = true;
- d.free = false;
g->defer = &d;
if(m != &runtimeĀ·m0)