Skip to content

Commit

Permalink
bench 10
Browse files Browse the repository at this point in the history
  • Loading branch information
aliszka committed Oct 24, 2024
1 parent 53f2603 commit 8ac4168
Showing 1 changed file with 18 additions and 7 deletions.
25 changes: 18 additions & 7 deletions bitmap_conc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ package sroar
// var subsets []*Bitmap

// func init() {
// // randSeed := int64(1724861525311)
// randSeed := time.Now().UnixNano()
// randSeed := int64(1724861525311)
// // randSeed := time.Now().UnixNano()
// countSubsets := 10
// countElements := 56
// countElements := 1234567

// // max element is 3x bigger than capacity of single bm's container
// maxX := (int(math.MaxUint16) + 1) * 3
Expand Down Expand Up @@ -55,19 +55,30 @@ package sroar
// }
// }

// // go test -v -bench Benchmark_And_Buf -benchmem -run ^$ github.com/weaviate/sroar -cpuprofile cpu.prof
// func Benchmark_And_Buf(b *testing.B) {
// // go test -v -bench Benchmark_And_Buf1 -benchmem -run ^$ github.com/weaviate/sroar -cpuprofile cpu.prof
// func Benchmark_And_Buf1(b *testing.B) {
// for i := 0; i < b.N; i++ {
// bm := superset.Clone()
// buf := make([]uint16, maxContainerSize)
// for j, l := 0, len(subsets); j < l; j++ {
// buf := make([]uint16, maxContainerSize)
// bm.AndBuf(subsets[j], buf)
// }
// }
// }

// // go test -v -bench Benchmark_And_Buf -benchmem -run ^$ github.com/weaviate/sroar -cpuprofile cpu.prof
// // go test -v -bench Benchmark_And_Buf2 -benchmem -run ^$ github.com/weaviate/sroar -cpuprofile cpu.prof
// func Benchmark_And_Buf2(b *testing.B) {
// for i := 0; i < b.N; i++ {
// bm := superset.Clone()
// buf := make([]uint16, maxContainerSize)
// for j, l := 0, len(subsets); j < l; j++ {
// bm.AndBuf(subsets[j], buf)
// }
// }
// }

// // go test -v -bench Benchmark_And_Buf2 -benchmem -run ^$ github.com/weaviate/sroar -cpuprofile cpu.prof
// func Benchmark_And_Buf3(b *testing.B) {
// buf := make([]uint16, maxContainerSize)
// for i := 0; i < b.N; i++ {
// bm := superset.Clone()
Expand Down

0 comments on commit 8ac4168

Please sign in to comment.