Keep the _many primitives for equal-sized operands, fold only ragged ones

This commit is contained in:
dualfroz committed 2026-09-23 06:12:58 +02:00
1 parent 4b1c980512
commit 666c48ccf8
4 files changed
+87 -50

No files matched your search

+19
View File
@@ -130,6 +130,25 @@ func BenchmarkMany(b *testing.B) {
run(b, "and4-batch", func(index Bitmap) {
index.And(other, other, other, other)
})
run(b, "or4-batch", func(index Bitmap) {
index.Or(other, other, other, other)
})
run(b, "xor4-batch", func(index Bitmap) {
index.Xor(other, other, other, other)
})
shorter := make(Bitmap, 1000000/64/2)
shorter.Set(1000000 / 2)
run(b, "or4-batch-ragged", func(index Bitmap) {
index.Or(other, other, shorter, other)
})
run(b, "xor4-batch-ragged", func(index Bitmap) {
index.Xor(other, other, shorter, other)
})
}
func TestSetRemove(t *testing.T) {