From 8fbaa4f70bf1bd2c2beb1bfdcce78863aaf08e0e Mon Sep 17 00:00:00 2001 From: Austin Clements Date: Thu, 16 Mar 2017 14:16:31 -0400 Subject: runtime: rename _MSpanStack -> _MSpanManual We're about to generalize _MSpanStack to be used for other forms of in-heap manual memory management in the runtime. This is an automated rename of _MSpanStack to _MSpanManual plus some comment fix-ups. For #19325. Change-Id: I1e20a57bb3b87a0d324382f92a3e294ffc767395 Reviewed-on: https://go-review.googlesource.com/38574 Run-TryBot: Austin Clements TryBot-Result: Gobot Gobot Reviewed-by: Rick Hudson --- src/runtime/stack.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/runtime/stack.go') diff --git a/src/runtime/stack.go b/src/runtime/stack.go index e81bb5ba4c..b8397279a9 100644 --- a/src/runtime/stack.go +++ b/src/runtime/stack.go @@ -220,7 +220,7 @@ func stackpoolalloc(order uint8) gclinkptr { // Adds stack x to the free pool. Must be called with stackpoolmu held. func stackpoolfree(x gclinkptr, order uint8) { s := mheap_.lookup(unsafe.Pointer(x)) - if s.state != _MSpanStack { + if s.state != _MSpanManual { throw("freeing stack not in a stack span") } if s.stackfreelist.ptr() == nil { @@ -465,7 +465,7 @@ func stackfree(stk stack) { } } else { s := mheap_.lookup(v) - if s.state != _MSpanStack { + if s.state != _MSpanManual { println(hex(s.base()), v) throw("bad span state") } -- cgit v1.3