From 3cf83c182af504bcffb82f3fc78a0c8b0ffb3aaa Mon Sep 17 00:00:00 2001 From: Keith Randall Date: Mon, 30 Jun 2014 19:48:08 -0700 Subject: undo CL 104200047 / 318b04f28372 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Breaks windows and race detector. TBR=rsc ««« original CL description runtime: stack allocator, separate from mallocgc In order to move malloc to Go, we need to have a separate stack allocator. If we run out of stack during malloc, malloc will not be available to allocate a new stack. Stacks are the last remaining FlagNoGC objects in the GC heap. Once they are out, we can get rid of the distinction between the allocated/blockboundary bits. (This will be in a separate change.) Fixes #7468 Fixes #7424 LGTM=rsc, dvyukov R=golang-codereviews, dvyukov, khr, dave, rsc CC=golang-codereviews https://golang.org/cl/104200047 »»» TBR=rsc CC=golang-codereviews https://golang.org/cl/101570044 --- src/pkg/runtime/mcentral.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/pkg/runtime/mcentral.c') diff --git a/src/pkg/runtime/mcentral.c b/src/pkg/runtime/mcentral.c index 9291c24856..203558fca5 100644 --- a/src/pkg/runtime/mcentral.c +++ b/src/pkg/runtime/mcentral.c @@ -263,8 +263,6 @@ MCentral_Grow(MCentral *c) runtime·unlock(c); runtime·MGetSizeClassInfo(c->sizeclass, &size, &npages, &n); s = runtime·MHeap_Alloc(&runtime·mheap, npages, c->sizeclass, 0, 1); - if(s->next != nil || s->prev != nil) - runtime·throw("internal error: MSpan should not be in a list"); if(s == nil) { // TODO(rsc): Log out of memory runtime·lock(c); -- cgit v1.3