Commit 9b88857f authored by Shenghou Ma's avatar Shenghou Ma

[dev.power64] runtime: disable GC and use a larger default stack

LGTM=rsc
R=rsc, iant
CC=golang-codereviews
https://golang.org/cl/128120043
parent f0393221
......@@ -278,7 +278,7 @@ func profilealloc(mp *m, x unsafe.Pointer, size uintptr) {
// force = 1 - do GC regardless of current heap usage
// force = 2 - go GC and eager sweep
func gogc(force int32) {
if memstats.enablegc == 0 {
if GOARCH == "power64" || GOARCH == "power64le" || memstats.enablegc == 0 {
return
}
......
......@@ -1305,6 +1305,10 @@ runtime·gc(int32 force)
if(!mstats.enablegc || g == g->m->g0 || g->m->locks > 0 || runtime·panicking)
return;
if(thechar == '9') {
runtime·gcpercent = -1;
return;
}
if(runtime·gcpercent == GcpercentUnknown) { // first time through
runtime·lock(&runtime·mheap);
if(runtime·gcpercent == GcpercentUnknown)
......
......@@ -76,7 +76,7 @@ enum {
// The minimum stack segment size to allocate.
// If the amount needed for the splitting frame + StackExtra
// is less than this number, the stack will have this size instead.
StackMin = 8192,
StackMin = 65536,
StackSystemRounded = StackSystem + (-StackSystem & (StackMin-1)),
FixedStack = StackMin + StackSystemRounded,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment