]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/internal/goobj: regenerate builtinlist
authorIan Lance Taylor <iant@golang.org>
Fri, 8 Nov 2024 20:51:28 +0000 (12:51 -0800)
committerGopher Robot <gobot@golang.org>
Fri, 8 Nov 2024 21:16:36 +0000 (21:16 +0000)
CL 622042 added rand as a compiler builtin, but did not update builtinlist.

Also update the mkbuiltin comment to refer to the current file location,
and add a comment for runtime.rand that it is called from the compiler.

For #54766

Change-Id: I99d2c0bb0658da333775afe2ed0447265c845c82
Reviewed-on: https://go-review.googlesource.com/c/go/+/626755
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: Michael Pratt <mpratt@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Auto-Submit: Ian Lance Taylor <iant@golang.org>

src/cmd/internal/goobj/builtinlist.go
src/cmd/internal/goobj/mkbuiltin.go
src/runtime/rand.go

index f091d77622f7402a3a92ed70247c9084d4b5a5f0..4e097b1199552d517591776cdc5f3a6a12cc58da 100644 (file)
@@ -88,6 +88,7 @@ var builtins = [...]struct {
        {"runtime.efaceeq", 1},
        {"runtime.panicrangestate", 1},
        {"runtime.deferrangefunc", 1},
+       {"runtime.rand", 1},
        {"runtime.rand32", 1},
        {"runtime.makemap64", 1},
        {"runtime.makemap", 1},
index 5ddf0e7d9a95627125a0ac8e6a1405c92f6bbcb0..9a6ad8c8c1c81c286ee1741271921092875073cd 100644 (file)
@@ -4,7 +4,7 @@
 
 //go:build ignore
 
-// Generate builtinlist.go from cmd/compile/internal/typecheck/builtin/runtime.go.
+// Generate builtinlist.go from cmd/compile/internal/typecheck/_builtin/runtime.go.
 
 package main
 
index 0d1d2fe5ba74ce3805a983988d13ebc79c487632..ba343af624663f42a7faf095c631f2270fea7585 100644 (file)
@@ -151,6 +151,8 @@ func rand32() uint32 {
 }
 
 // rand returns a random uint64 from the per-m chacha8 state.
+// This is called from compiler-generated code.
+//
 // Do not change signature: used via linkname from other packages.
 //
 //go:nosplit