From 969bea8d59daa6bdd478b71f6e99d8b8f625a140 Mon Sep 17 00:00:00 2001 From: cui fliter Date: Thu, 3 Nov 2022 15:39:41 +0800 Subject: [PATCH] runtime: fix a few function names on comments Change-Id: I9ef4898d68dfd06618c0bd8e23f81a1d2c77a836 Signed-off-by: cui fliter Reviewed-on: https://go-review.googlesource.com/c/go/+/447460 Auto-Submit: Michael Pratt TryBot-Result: Gopher Robot Reviewed-by: Matthew Dempsky Reviewed-by: Michael Pratt Run-TryBot: Michael Pratt --- src/runtime/internal/sys/intrinsics_common.go | 2 +- src/runtime/os_openbsd_syscall2.go | 2 +- src/runtime/stack.go | 2 +- src/runtime/stubs2.go | 2 +- src/runtime/traceback.go | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/runtime/internal/sys/intrinsics_common.go b/src/runtime/internal/sys/intrinsics_common.go index 709ec23f9debc7..1461551dda6e73 100644 --- a/src/runtime/internal/sys/intrinsics_common.go +++ b/src/runtime/internal/sys/intrinsics_common.go @@ -24,7 +24,7 @@ const len8tab = "" + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" -// len64 returns the minimum number of bits required to represent x; the result is 0 for x == 0. +// Len64 returns the minimum number of bits required to represent x; the result is 0 for x == 0. // // nosplit because this is used in src/runtime/histogram.go, which make run in sensitive contexts. // diff --git a/src/runtime/os_openbsd_syscall2.go b/src/runtime/os_openbsd_syscall2.go index ab6b1818285c06..2fed794d7ae5cc 100644 --- a/src/runtime/os_openbsd_syscall2.go +++ b/src/runtime/os_openbsd_syscall2.go @@ -38,7 +38,7 @@ func usleep_no_g(usec uint32) { usleep(usec) } -// write calls the write system call. +// write1 calls the write system call. // It returns a non-negative number of bytes written or a negative errno value. // //go:noescape diff --git a/src/runtime/stack.go b/src/runtime/stack.go index 87d8e519bdd221..546f9978816645 100644 --- a/src/runtime/stack.go +++ b/src/runtime/stack.go @@ -564,7 +564,7 @@ type adjustinfo struct { sghi uintptr } -// Adjustpointer checks whether *vpp is in the old stack described by adjinfo. +// adjustpointer checks whether *vpp is in the old stack described by adjinfo. // If so, it rewrites *vpp to point into the new stack. func adjustpointer(adjinfo *adjustinfo, vpp unsafe.Pointer) { pp := (*uintptr)(vpp) diff --git a/src/runtime/stubs2.go b/src/runtime/stubs2.go index d2ad8d4ec88ed6..c245c9c1a11eff 100644 --- a/src/runtime/stubs2.go +++ b/src/runtime/stubs2.go @@ -25,7 +25,7 @@ func usleep_no_g(usec uint32) { usleep(usec) } -// write calls the write system call. +// write1 calls the write system call. // It returns a non-negative number of bytes written or a negative errno value. // //go:noescape diff --git a/src/runtime/traceback.go b/src/runtime/traceback.go index 794ea104072f4a..37f35d5637edad 100644 --- a/src/runtime/traceback.go +++ b/src/runtime/traceback.go @@ -810,7 +810,7 @@ func printAncestorTraceback(ancestor ancestorInfo) { } } -// printAncestorTraceback prints the given function info at a given pc +// printAncestorTracebackFuncInfo prints the given function info at a given pc // within an ancestor traceback. The precision of this info is reduced // due to only have access to the pcs at the time of the caller // goroutine being created. @@ -1282,7 +1282,7 @@ type cgoSymbolizerArg struct { data uintptr } -// cgoTraceback prints a traceback of callers. +// printCgoTraceback prints a traceback of callers. func printCgoTraceback(callers *cgoCallers) { if cgoSymbolizer == nil { for _, c := range callers {