From 528bafa0498bb26a3b3961fa5bf50d02bd7101bb Mon Sep 17 00:00:00 2001 From: Michael Anthony Knyszek Date: Tue, 4 Mar 2025 19:02:48 +0000 Subject: runtime: move sizeclass defs to new package internal/runtime/gc We will want to reference these definitions from new generator programs, and this is a good opportunity to cleanup all these old C-style names. Change-Id: Ifb06f0afc381e2697e7877f038eca786610c96de Reviewed-on: https://go-review.googlesource.com/c/go/+/655275 Auto-Submit: Michael Knyszek LUCI-TryBot-Result: Go LUCI Reviewed-by: Cherry Mui Reviewed-by: Michael Pratt --- src/runtime/mpagealloc.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/runtime/mpagealloc.go') diff --git a/src/runtime/mpagealloc.go b/src/runtime/mpagealloc.go index c9491e31f4..4c58fb6e02 100644 --- a/src/runtime/mpagealloc.go +++ b/src/runtime/mpagealloc.go @@ -49,6 +49,7 @@ package runtime import ( "internal/runtime/atomic" + "internal/runtime/gc" "unsafe" ) @@ -58,7 +59,7 @@ const ( pallocChunkPages = 1 << logPallocChunkPages pallocChunkBytes = pallocChunkPages * pageSize logPallocChunkPages = 9 - logPallocChunkBytes = logPallocChunkPages + pageShift + logPallocChunkBytes = logPallocChunkPages + gc.PageShift // The number of radix bits for each level. // -- cgit v1.3