]> Cypherpunks repositories - gostls13.git/commit
runtime: process ptr bitmaps one word at a time
authorKeith Randall <khr@golang.org>
Sat, 7 May 2022 01:40:17 +0000 (18:40 -0700)
committerKeith Randall <khr@golang.org>
Tue, 16 Aug 2022 20:39:44 +0000 (20:39 +0000)
commite49e8764553bf510b5d9f6fb38aeec0850ec6672
tree7263557e805de72ab63d14d34cf3ec80836017f4
parent6a9c674a09b057a641527ac847cbdf1a3824b753
runtime: process ptr bitmaps one word at a time

[This is a retry of CL 407036 + its revert CL 422394. The only
content change is the 1-line change in cmd/internal/obj/objfile.go.]

Read the bitmaps one uintptr at a time instead of one byte at a time.

Performance so far:
 Allocation heavy, no retention: ~30% faster in heapBitsSetType
 Scan heavy, ~no allocation: ~even in scanobject

Change-Id: I04d899e1dbd23e989e9f552cdc1880318779c14c
Reviewed-on: https://go-review.googlesource.com/c/go/+/422635
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@google.com>
Run-TryBot: Keith Randall <khr@golang.org>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
src/cmd/compile/internal/reflectdata/reflect.go
src/cmd/internal/obj/objfile.go
src/reflect/type.go
src/runtime/mbitmap.go