aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/runtime2.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/runtime2.go')
-rw-r--r--src/runtime/runtime2.go8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/runtime/runtime2.go b/src/runtime/runtime2.go
index bfd857e8d5..3eada37840 100644
--- a/src/runtime/runtime2.go
+++ b/src/runtime/runtime2.go
@@ -209,7 +209,7 @@ type eface struct {
data unsafe.Pointer
}
-func efaceOf(ep *interface{}) *eface {
+func efaceOf(ep *any) *eface {
return (*eface)(unsafe.Pointer(ep))
}
@@ -255,6 +255,8 @@ func efaceOf(ep *interface{}) *eface {
// so I can't see them ever moving. If we did want to start moving data
// in the GC, we'd need to allocate the goroutine structs from an
// alternate arena. Using guintptr doesn't make that problem any worse.
+// Note that pollDesc.rg, pollDesc.wg also store g in uintptr form,
+// so they would need to be updated too if g's start moving.
type guintptr uintptr
//go:nosplit
@@ -939,7 +941,7 @@ func extendRandom(r []byte, n int) {
}
// A _defer holds an entry on the list of deferred calls.
-// If you add a field here, add code to clear it in freedefer and deferProcStack
+// If you add a field here, add code to clear it in deferProcStack.
// This struct must match the code in cmd/compile/internal/ssagen/ssa.go:deferstruct
// and cmd/compile/internal/ssagen/ssa.go:(*state).call.
// Some defers will be allocated on the stack and some on the heap.
@@ -982,7 +984,7 @@ type _defer struct {
// adjustment takes care of them.
type _panic struct {
argp unsafe.Pointer // pointer to arguments of deferred call run during panic; cannot move - known to liblink
- arg interface{} // argument to panic
+ arg any // argument to panic
link *_panic // link to earlier panic
pc uintptr // where to return to in runtime if this panic is bypassed
sp unsafe.Pointer // where to return to in runtime if this panic is bypassed