From fc469314420f553906a283656ae39bafcf5af1b0 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Tue, 16 Sep 2014 11:03:11 -0400 Subject: runtime: remove untyped allocation of ParFor Now it's two allocations. I don't see much downside to that, since the two pieces were in different cache lines anyway. Rename 'conservative' to 'cgo_conservative_type' and make clear that _cgo_allocate is the only allowed user. This depends on CL 141490043, which removes the other use of conservative (in defer). LGTM=dvyukov, iant R=khr, dvyukov, iant CC=golang-codereviews, rlh https://golang.org/cl/139610043 --- src/runtime/malloc.c | 8 -------- 1 file changed, 8 deletions(-) (limited to 'src/runtime/malloc.c') diff --git a/src/runtime/malloc.c b/src/runtime/malloc.c index e5c7e09592..cfb698ac21 100644 --- a/src/runtime/malloc.c +++ b/src/runtime/malloc.c @@ -21,10 +21,6 @@ MHeap runtime·mheap; #pragma dataflag NOPTR MStats runtime·memstats; -Type* runtime·conservative; - -void runtime·gc_notype_ptr(Eface*); - int32 runtime·mlookup(void *v, byte **base, uintptr *size, MSpan **sp) { @@ -115,7 +111,6 @@ runtime·mallocinit(void) uintptr limit; uint64 i; bool reserved; - Eface notype_eface; p = nil; p_size = 0; @@ -243,9 +238,6 @@ runtime·mallocinit(void) // Initialize the rest of the allocator. runtime·MHeap_Init(&runtime·mheap); g->m->mcache = runtime·allocmcache(); - - runtime·gc_notype_ptr(¬ype_eface); - runtime·conservative = notype_eface.type; } void* -- cgit v1.3-5-g45d5