diff options
| author | Keith Randall <khr@golang.org> | 2016-04-19 19:35:10 -0700 |
|---|---|---|
| committer | Keith Randall <khr@golang.org> | 2016-04-20 14:02:22 +0000 |
| commit | 001e8e8070e8ed3a578dbad93cc3f70257e965bd (patch) | |
| tree | 13300d3f022b1d24571be6c267979e5d8d0c48e5 /src/runtime/panic.go | |
| parent | 731531980a36f1fa6434c947c54daf8ba530a65f (diff) | |
| download | go-001e8e8070e8ed3a578dbad93cc3f70257e965bd.tar.xz | |
runtime: simplify mallocgc flag argument
mallocgc can calculate noscan itself. The only remaining
flag argument is needzero, so we just make that a boolean arg.
Fixes #15379
Change-Id: I839a70790b2a0c9dbcee2600052bfbd6c8148e20
Reviewed-on: https://go-review.googlesource.com/22290
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/runtime/panic.go')
| -rw-r--r-- | src/runtime/panic.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/runtime/panic.go b/src/runtime/panic.go index 59fbc83369..382a20e4e7 100644 --- a/src/runtime/panic.go +++ b/src/runtime/panic.go @@ -205,7 +205,7 @@ func newdefer(siz int32) *_defer { if d == nil { // Allocate new defer+args. total := roundupsize(totaldefersize(uintptr(siz))) - d = (*_defer)(mallocgc(total, deferType, 0)) + d = (*_defer)(mallocgc(total, deferType, true)) } d.siz = siz gp := mp.curg |
