forked from mirror/glob
test parallel
This commit is contained in:
parent
de3f4464d6
commit
eb46c5146c
|
@ -75,8 +75,9 @@ func BenchmarkMatchBTree(b *testing.B) {
|
||||||
|
|
||||||
bt := NewBTree(v, l, r)
|
bt := NewBTree(v, l, r)
|
||||||
|
|
||||||
b.SetParallelism(1)
|
b.RunParallel(func(pb *testing.PB) {
|
||||||
for i := 0; i < b.N; i++ {
|
for pb.Next() {
|
||||||
bt.Match(fixture)
|
bt.Match(fixture)
|
||||||
}
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue