aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/internal/obj
diff options
context:
space:
mode:
authorKeith Randall <khr@golang.org>2026-03-17 11:13:16 -0700
committerGopher Robot <gobot@golang.org>2026-03-17 13:49:58 -0700
commitcd2fa3b48dc059203aa724474e19096928b3f71f (patch)
tree320e87c87cb0e25263aa1af7b7a6914379b0c52a /src/cmd/internal/obj
parenta6949e942c4287fcccf3264b8df6190c88609cb7 (diff)
downloadgo-cd2fa3b48dc059203aa724474e19096928b3f71f.tar.xz
runtime: fix memclrNoHeapPointersPreemptible
memclrNoHeapPointersChunked was originally written for clearing fresh allocations. It converts to uintptr early and thus doesn't handle the case where the pointer points to the stack. At the preemption point, the buffer being pointed to might be on the stack and copied to a new location. Then we'd end up zeroing random heap memory when we return from preemption. Fix it to keep the pointer to the allocation in an unsafe.Pointer, so it gets updated correctly on a stack copy. Update #78081 (Fixes?) Change-Id: Id25c7faf45f201929cb8c8bbcc7c8bd4f67c31ac Reviewed-on: https://go-review.googlesource.com/c/go/+/756122 Auto-Submit: Keith Randall <khr@golang.org> Reviewed-by: Michael Pratt <mpratt@google.com> Reviewed-by: Keith Randall <khr@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Diffstat (limited to 'src/cmd/internal/obj')
0 files changed, 0 insertions, 0 deletions