Skip to content

Instantly share code, notes, and snippets.

diff --git a/src/cmd/go/build.go b/src/cmd/go/build.go
index f2a2a60..53c962c 100644
--- a/src/cmd/go/build.go
+++ b/src/cmd/go/build.go
@@ -694,6 +694,8 @@ type builder struct {
exec sync.Mutex
readySema chan bool
ready actionQueue
+
+ tasks chan func()
diff --git a/src/cmd/go/build.go b/src/cmd/go/build.go
index 5327fb9..ac92970 100644
--- a/src/cmd/go/build.go
+++ b/src/cmd/go/build.go
@@ -700,6 +700,8 @@ type builder struct {
exec sync.Mutex
readySema chan bool
ready actionQueue
+
+ tasks chan func()
@petermattis
petermattis / main.go
Last active April 5, 2019 19:37
bucket drain / fill simulation
package main
import (
"context"
"fmt"
"math/rand"
"runtime"
"sync"
"sync/atomic"
"time"
func TestBadStats(t *testing.T) {
defer leaktest.AfterTest(t)()
stopper := stop.NewStopper()
defer stopper.Stop(context.TODO())
e := NewInMem(roachpb.Attributes{}, 1<<20)
stopper.AddCloser(e)
func() {
b := e.NewBatch()
defer b.Close()
diff --git a/github.com/cockroachdb/pebble/compaction_picker.go b/github.com/cockroachdb/pebble/compaction_picker.go
index 186e16ca5..20012461e 100644
--- a/github.com/cockroachdb/pebble/compaction_picker.go
+++ b/github.com/cockroachdb/pebble/compaction_picker.go
@@ -119,6 +119,11 @@ type compactionPickerByScore struct {
// levelMaxBytes holds the dynamically adjusted max bytes setting for each
// level.
levelMaxBytes [numLevels]int64
+
+ // The ratio of the bytes in level to the previous higher level. For Lbase,