aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/alg.go
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2024-05-22 17:09:02 -0400
committerRuss Cox <rsc@golang.org>2024-05-29 16:25:21 +0000
commit9a8995b8b6a08d5fe01122771f962b36336f8aec (patch)
tree0222395807dfced049e2602280a7f8614b2addbe /src/runtime/alg.go
parenta3a584e4abad776f4b8e5cab5b5923724fdf75d9 (diff)
downloadgo-9a8995b8b6a08d5fe01122771f962b36336f8aec.tar.xz
all: document legacy //go:linkname for modules with ≥100 dependents
For #67401. Change-Id: I015408a3f437c1733d97160ef2fb5da6d4efcc5c Reviewed-on: https://go-review.googlesource.com/c/go/+/587598 Reviewed-by: Cherry Mui <cherryyz@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Auto-Submit: Russ Cox <rsc@golang.org>
Diffstat (limited to 'src/runtime/alg.go')
-rw-r--r--src/runtime/alg.go22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/runtime/alg.go b/src/runtime/alg.go
index c11ef4c6ef..c55f916a7a 100644
--- a/src/runtime/alg.go
+++ b/src/runtime/alg.go
@@ -51,10 +51,12 @@ var useAeshash bool
// Notable members of the hall of shame include:
// - github.com/aacfactory/fns
// - github.com/dgraph-io/ristretto
+// - github.com/minio/simdjson-go
// - github.com/nbd-wtf/go-nostr
// - github.com/outcaste-io/ristretto
// - github.com/puzpuzpuz/xsync/v2
// - github.com/puzpuzpuz/xsync/v3
+// - github.com/segmentio/parquet-go
//
// Do not remove or change the type signature.
// See go.dev/issue/67401.
@@ -62,7 +64,26 @@ var useAeshash bool
//go:linkname memhash
func memhash(p unsafe.Pointer, h, s uintptr) uintptr
+// memhash32 should be an internal detail,
+// but widely used packages access it using linkname.
+// Notable members of the hall of shame include:
+// - github.com/segmentio/parquet-go
+//
+// Do not remove or change the type signature.
+// See go.dev/issue/67401.
+//
+//go:linkname memhash32
func memhash32(p unsafe.Pointer, h uintptr) uintptr
+
+// memhash64 should be an internal detail,
+// but widely used packages access it using linkname.
+// Notable members of the hall of shame include:
+// - github.com/segmentio/parquet-go
+//
+// Do not remove or change the type signature.
+// See go.dev/issue/67401.
+//
+//go:linkname memhash64
func memhash64(p unsafe.Pointer, h uintptr) uintptr
// strhash should be an internal detail,
@@ -72,6 +93,7 @@ func memhash64(p unsafe.Pointer, h uintptr) uintptr
// - github.com/bytedance/sonic
// - github.com/bytedance/go-tagexpr/v2
// - github.com/cloudwego/frugal
+// - github.com/cloudwego/dynamicgo
//
// Do not remove or change the type signature.
// See go.dev/issue/67401.