]> Cypherpunks repositories - gostls13.git/commit
runtime: use memclrNoHeapPointers to clear inline mark bits
authorMichael Anthony Knyszek <mknyszek@google.com>
Mon, 14 Jul 2025 19:33:13 +0000 (19:33 +0000)
committerGopher Robot <gobot@golang.org>
Tue, 15 Jul 2025 19:24:37 +0000 (12:24 -0700)
commit75a19dbcd7e69dc619fd57b9ed32f697121160ba
treeb93428a7a5aa396b03d18c9ea5af46bef9b5c749
parent6d4a91c7a5b5723aa1fc1461eb3e9602ccf9606a
runtime: use memclrNoHeapPointers to clear inline mark bits

Clearing the inline mark bits with memclrNoHeapPointers is slightly
better than having the compiler insert, e.g. duffzero, since it can take
advantage of wider SIMD instructions. duffzero is likely going away, but
we know things the compiler doesn't, such as the fact that this memory
is nicely aligned. In this particular case, memclrNoHeapPointers does a
better job.

For #73581.

Change-Id: I3918096929acfe6efe6f469fb089ebe04b4acff5
Reviewed-on: https://go-review.googlesource.com/c/go/+/687938
Reviewed-by: Michael Pratt <mpratt@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Auto-Submit: Michael Knyszek <mknyszek@google.com>
src/runtime/mgcmark_greenteagc.go