]> Cypherpunks repositories - gostls13.git/commit
runtime: delete redundant code in the page allocator
authortony <jianfeng.tony@gmail.com>
Mon, 29 Sep 2025 14:25:57 +0000 (14:25 +0000)
committerKeith Randall <khr@golang.org>
Mon, 6 Oct 2025 21:20:22 +0000 (14:20 -0700)
commit4fca79833fcdd0dc19bb0feba8715a0def3d07be
tree8285185489c2324da65faa0af934030e2c1fefbb
parent719dfcf8a8478d70360bf3c34c0e920be7b32994
runtime: delete redundant code in the page allocator

The page allocator's scavenge index has sysGrow called on it twice,
once in pageAlloc.grow, and once in pageAlloc.sysGrow on 64-bit
platforms. Calling it twice is OK since sysGrow is idempotent,
but it's also wasteful. This change removes the call
in pageAlloc.sysGrow.

Change-Id: I5b955b6e2beed5c2b8305ab82b76718ea305792c
Reviewed-on: https://go-review.googlesource.com/c/go/+/707735
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
Reviewed-by: Carlos Amedee <carlos@golang.org>
src/runtime/mpagealloc_64bit.go