diff --git a/src/runtime/hashmap.go b/src/runtime/hashmap.go index aaaef48381..9ca33992bb 100644 --- a/src/runtime/hashmap.go +++ b/src/runtime/hashmap.go @@ -96,9 +96,6 @@ const ( // sentinel bucket ID for iterator checks noCheck = 1<<(8*ptrSize) - 1 - - // trigger a garbage collection at every alloc called from this code - checkgc = false ) // A header for a Go map. @@ -246,16 +243,10 @@ func makemap(t *maptype, hint int64, h *hmap, bucket unsafe.Pointer) *hmap { // If hint is large zeroing this memory could take a while. buckets := bucket if B != 0 { - if checkgc { - memstats.next_gc = memstats.heap_alloc - } buckets = newarray(t.bucket, uintptr(1)<