Skip to content

Commit

Permalink
runtime, internal/syscall/unix: mark getrandom vDSO as non-escaping
Browse files Browse the repository at this point in the history
Updates #66779

Change-Id: Iaa3eda4309bb1e8c28136dd048479e7269f4c189
  • Loading branch information
mateusz834 committed Sep 30, 2024
1 parent 1d0f5c4 commit 1cea46d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/internal/syscall/unix/getrandom.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import (
)

//go:linkname vgetrandom runtime.vgetrandom
//go:noescape
func vgetrandom(p []byte, flags uint32) (ret int, supported bool)

var getrandomUnsupported atomic.Bool
Expand Down
1 change: 1 addition & 0 deletions src/runtime/vgetrandom_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import (
"unsafe"
)

//go:noescape
func vgetrandom1(buf *byte, length uintptr, flags uint32, state uintptr, stateSize uintptr) int

var vgetrandomAlloc struct {
Expand Down

0 comments on commit 1cea46d

Please sign in to comment.