aboutsummaryrefslogtreecommitdiff
path: root/src/runtime
diff options
context:
space:
mode:
authorJes Cok <xigua67damn@gmail.com>2023-06-23 07:47:48 +0000
committerGopher Robot <gobot@golang.org>2023-07-18 19:55:29 +0000
commit5d481abc87643146a3a3ee9f005ca01c7715772a (patch)
tree5ef76e1e6f1bff286751198ea8ebf6b40ebb4bf0 /src/runtime
parent88a545d84438803714fa91f2c93057a3246bd58c (diff)
downloadgo-5d481abc87643146a3a3ee9f005ca01c7715772a.tar.xz
all: fix typos
Change-Id: I510b0a4bf3472d937393800dd57472c30beef329 GitHub-Last-Rev: 8d289b73a37bd86080936423d981d21e152aaa33 GitHub-Pull-Request: golang/go#60960 Reviewed-on: https://go-review.googlesource.com/c/go/+/505398 Auto-Submit: Robert Findley <rfindley@google.com> Reviewed-by: Robert Findley <rfindley@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Robert Findley <rfindley@google.com> Reviewed-by: Ian Lance Taylor <iant@google.com>
Diffstat (limited to 'src/runtime')
-rw-r--r--src/runtime/cgocall.go2
-rw-r--r--src/runtime/coverage/emit.go2
-rw-r--r--src/runtime/mgcmark.go2
-rw-r--r--src/runtime/race/testdata/chan_test.go2
4 files changed, 4 insertions, 4 deletions
diff --git a/src/runtime/cgocall.go b/src/runtime/cgocall.go
index 1da7249abc..f6e2f63813 100644
--- a/src/runtime/cgocall.go
+++ b/src/runtime/cgocall.go
@@ -168,7 +168,7 @@ func cgocall(fn, arg unsafe.Pointer) int32 {
// any C on the call stack, which there will be after this point. If
// there isn't, we can use frame pointer unwinding to collect call
// stacks efficiently. This will be the case for the first Go-to-C call
- // on a stack, so it's prefereable to update it here, after we emit a
+ // on a stack, so it's preferable to update it here, after we emit a
// trace event in entersyscall above.
mp.ncgo++
diff --git a/src/runtime/coverage/emit.go b/src/runtime/coverage/emit.go
index d18e69053d..6fe04daea8 100644
--- a/src/runtime/coverage/emit.go
+++ b/src/runtime/coverage/emit.go
@@ -575,7 +575,7 @@ func (s *emitState) emitCounterDataFile(finalHash [16]byte, w io.Writer) error {
}
// markProfileEmitted signals the runtime/coverage machinery that
-// coverate data output files have already been written out, and there
+// coverage data output files have already been written out, and there
// is no need to take any additional action at exit time. This
// function is called (via linknamed reference) from the
// coverage-related boilerplate code in _testmain.go emitted for go
diff --git a/src/runtime/mgcmark.go b/src/runtime/mgcmark.go
index 2ed411ae61..c49eba0302 100644
--- a/src/runtime/mgcmark.go
+++ b/src/runtime/mgcmark.go
@@ -537,7 +537,7 @@ func gcAssistAlloc1(gp *g, scanWork int64) {
// The gcBlackenEnabled check in malloc races with the
// store that clears it but an atomic check in every malloc
// would be a performance hit.
- // Instead we recheck it here on the non-preemptable system
+ // Instead we recheck it here on the non-preemptible system
// stack to determine if we should perform an assist.
// GC is done, so ignore any remaining debt.
diff --git a/src/runtime/race/testdata/chan_test.go b/src/runtime/race/testdata/chan_test.go
index e39ad4f99c..d592de9771 100644
--- a/src/runtime/race/testdata/chan_test.go
+++ b/src/runtime/race/testdata/chan_test.go
@@ -766,7 +766,7 @@ func TestNoRaceCloseHappensBeforeRead(t *testing.T) {
// Test that we call the proper race detector function when c.elemsize==0.
// See https://github.com/golang/go/issues/42598
-func TestNoRaceElemetSize0(t *testing.T) {
+func TestNoRaceElemSize0(t *testing.T) {
var x, y int
var c = make(chan struct{}, 2)
c <- struct{}{}