aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/compile/internal/test
diff options
context:
space:
mode:
authorMichael Pratt <mpratt@google.com>2024-05-03 13:03:04 -0400
committerMichael Pratt <mpratt@google.com>2024-10-14 19:58:47 +0000
commitc39bc22c141bc6990e4e2abf604dcf56669ff779 (patch)
tree5384243aaaa9d9f9796674223cf186ee3ceb63a9 /src/cmd/compile/internal/test
parent48849e0866f64a40d04a9151e44e5a73acdfc17b (diff)
downloadgo-c39bc22c141bc6990e4e2abf604dcf56669ff779.tar.xz
all: wire up swisstable maps
Use the new SwissTable-based map in internal/runtime/maps as the basis for the runtime map when GOEXPERIMENT=swissmap. Integration is complete enough to pass all.bash. Notable missing features: * Race integration / concurrent write detection * Stack-allocated maps * Specialized "fast" map variants * Indirect key / elem For #54766. Cq-Include-Trybots: luci.golang.try:gotip-linux-ppc64_power10,gotip-linux-amd64-longtest-swissmap Change-Id: Ie97b656b6d8e05c0403311ae08fef9f51756a639 Reviewed-on: https://go-review.googlesource.com/c/go/+/594596 Reviewed-by: Keith Randall <khr@golang.org> Reviewed-by: Keith Randall <khr@google.com> Reviewed-by: Michael Knyszek <mknyszek@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Diffstat (limited to 'src/cmd/compile/internal/test')
-rw-r--r--src/cmd/compile/internal/test/inl_test.go15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/cmd/compile/internal/test/inl_test.go b/src/cmd/compile/internal/test/inl_test.go
index 5a8a156f02..758479b622 100644
--- a/src/cmd/compile/internal/test/inl_test.go
+++ b/src/cmd/compile/internal/test/inl_test.go
@@ -39,10 +39,7 @@ func TestIntendedInlining(t *testing.T) {
"adjustpointer",
"alignDown",
"alignUp",
- "bucketMask",
- "bucketShift",
"chanbuf",
- "evacuated",
"fastlog2",
"float64bits",
"funcspdelta",
@@ -62,9 +59,6 @@ func TestIntendedInlining(t *testing.T) {
"stringStructOf",
"subtract1",
"subtractb",
- "tophash",
- "(*bmap).keys",
- "(*bmap).overflow",
"(*waitq).enqueue",
"funcInfo.entry",
@@ -236,6 +230,15 @@ func TestIntendedInlining(t *testing.T) {
},
}
+ if !goexperiment.SwissMap {
+ // Maps
+ want["runtime"] = append(want["runtime"], "bucketMask")
+ want["runtime"] = append(want["runtime"], "bucketShift")
+ want["runtime"] = append(want["runtime"], "evacuated")
+ want["runtime"] = append(want["runtime"], "tophash")
+ want["runtime"] = append(want["runtime"], "(*bmap).keys")
+ want["runtime"] = append(want["runtime"], "(*bmap).overflow")
+ }
if runtime.GOARCH != "386" && runtime.GOARCH != "loong64" && runtime.GOARCH != "mips64" && runtime.GOARCH != "mips64le" && runtime.GOARCH != "riscv64" {
// nextFreeFast calls sys.TrailingZeros64, which on 386 is implemented in asm and is not inlinable.
// We currently don't have midstack inlining so nextFreeFast is also not inlinable on 386.