diff options
| author | Russ Cox <rsc@golang.org> | 2008-12-19 03:13:39 -0800 |
|---|---|---|
| committer | Russ Cox <rsc@golang.org> | 2008-12-19 03:13:39 -0800 |
| commit | da0a7d7b8f896bc2117ce488c4e245d626ef8aba (patch) | |
| tree | 9b40150f73466d543e7724ee596fb3c4ef094e72 /src/runtime/proc.c | |
| parent | ba882f9940361e7f9f969fcc1cc613e735d38191 (diff) | |
| download | go-da0a7d7b8f896bc2117ce488c4e245d626ef8aba.tar.xz | |
malloc bug fixes.
use malloc by default.
free stacks.
R=r
DELTA=424 (333 added, 29 deleted, 62 changed)
OCL=21553
CL=21584
Diffstat (limited to 'src/runtime/proc.c')
| -rw-r--r-- | src/runtime/proc.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/runtime/proc.c b/src/runtime/proc.c index 2d9ce77efd..01581569f7 100644 --- a/src/runtime/proc.c +++ b/src/runtime/proc.c @@ -97,6 +97,10 @@ schedinit(void) byte *p; mallocinit(); + + // Allocate internal symbol table representation now, + // so that we don't need to call malloc when we crash. + findfunc(0); sched.gomaxprocs = 1; p = getenv("GOMAXPROCS"); @@ -440,7 +444,7 @@ matchmg(void) notewakeup(&m->havenextg); }else{ m = mal(sizeof(M)); - m->g0 = malg(1024); + m->g0 = malg(8192); m->nextg = g; m->id = sched.mcount++; if(debug) { |
