]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: fix a few typos in comments
authorJerrin Shaji George <jerrinsg@gmail.com>
Thu, 22 Feb 2018 23:51:10 +0000 (15:51 -0800)
committerBrad Fitzpatrick <bradfitz@golang.org>
Fri, 23 Feb 2018 00:17:20 +0000 (00:17 +0000)
Change-Id: I07a1eb02ffc621c5696b49491181300bf411f822
Reviewed-on: https://go-review.googlesource.com/96475
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/runtime/mfixalloc.go
src/runtime/mgclarge.go
src/runtime/mgcmark.go
src/runtime/mheap.go
src/runtime/symtab.go

index 7496671fbec151808497a43b8b87af8bfb99d9f9..1febe782bb6e48f2c70a9e17e4d4ae55dd1f3ac6 100644 (file)
@@ -11,7 +11,7 @@ package runtime
 import "unsafe"
 
 // FixAlloc is a simple free-list allocator for fixed size objects.
-// Malloc uses a FixAlloc wrapped around sysAlloc to manages its
+// Malloc uses a FixAlloc wrapped around sysAlloc to manage its
 // MCache and MSpan objects.
 //
 // Memory returned by fixalloc.alloc is zeroed by default, but the
index fe437bf5e84d7448ecc94d09da0b7c33df8520eb..cf9f80c2fa13af90f035c1f8c1cb7b951ec1376d 100644 (file)
@@ -43,7 +43,7 @@ type treapNode struct {
        parent    *treapNode // direct parent of this node, nil if root
        npagesKey uintptr    // number of pages in spanKey, used as primary sort key
        spanKey   *mspan     // span of size npagesKey, used as secondary sort key
-       priority  uint32     // random number used by treap algorithm keep tree probablistically balanced
+       priority  uint32     // random number used by treap algorithm to keep tree probabilistically balanced
 }
 
 func (t *treapNode) init() {
index 46c92d19830e69ad3b4b46727263051647490ae5..270fa6cd32c8fb7794f982c0427646a9464e2d1a 100644 (file)
@@ -530,7 +530,7 @@ func gcAssistAlloc1(gp *g, scanWork int64) {
                // 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
-               // stack to determine if we should preform an assist.
+               // stack to determine if we should perform an assist.
 
                // GC is done, so ignore any remaining debt.
                gp.gcAssistBytes = 0
index 7bfb6f856fa12b0542c839cea7f4794d73b25833..b529f086f4390c8a4ab08da51814307a7c2a3f4e 100644 (file)
@@ -561,7 +561,7 @@ retry:
                        goto retry
                }
                if s.sweepgen == sg-1 {
-                       // the span is being sweept by background sweeper, skip
+                       // the span is being swept by background sweeper, skip
                        continue
                }
                // already swept empty span,
@@ -751,7 +751,7 @@ func (h *mheap) allocManual(npage uintptr, stat *uint64) *mspan {
                s.nelems = 0
                s.elemsize = 0
                s.limit = s.base() + s.npages<<_PageShift
-               // Manually manged memory doesn't count toward heap_sys.
+               // Manually managed memory doesn't count toward heap_sys.
                memstats.heap_sys -= uint64(s.npages << _PageShift)
        }
 
index 23d2232db56fbb954ef3e466e45a213754a1f798..7d7c363b5bc9cf639bac60ded3665a9af978ff15 100644 (file)
@@ -339,7 +339,7 @@ func (f *Func) funcInfo() funcInfo {
 
 // PCDATA and FUNCDATA table indexes.
 //
-// See funcdata.h and ../cmd/internal/obj/funcdata.go.
+// See funcdata.h and ../cmd/internal/objabi/funcdata.go.
 const (
        _PCDATA_StackMapIndex       = 0
        _PCDATA_InlTreeIndex        = 1