From 2a64b89bdbc8fec645dd688bd0322f45c067f295 Mon Sep 17 00:00:00 2001 From: Matt Joiner Date: Fri, 4 Sep 2020 15:44:51 +1000 Subject: Add custom VarValue and const for sleep backoff --- bench_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'bench_test.go') diff --git a/bench_test.go b/bench_test.go index 08faa96..da2bf97 100644 --- a/bench_test.go +++ b/bench_test.go @@ -199,9 +199,9 @@ func BenchmarkThunderingHerdCondVar(b *testing.B) { func BenchmarkThunderingHerd(b *testing.B) { for i := 0; i < b.N; i++ { - done := NewVar(false) - tokens := NewVar(0) - pending := NewVar(0) + done := NewBuiltinEqVar(false) + tokens := NewBuiltinEqVar(0) + pending := NewBuiltinEqVar(0) for range iter.N(1000) { Atomically(VoidOperation(func(tx *Tx) { tx.Set(pending, tx.Get(pending).(int)+1) -- cgit v1.2.3