scorch introducer uses the roaring.Or(x, y) API
Instead of cloning an input bitmap, the roaring.Or(x, y) implementation fills a brand new result bitmap, which should be allow for more efficient packing and memory utilization.
This commit is contained in:
parent
67986d41bf
commit
398dcb19b3
|
@ -49,8 +49,7 @@ func (s *Scorch) mainLoop() {
|
|||
if s.root.segment[i].deleted == nil {
|
||||
newSnapshot.segment[i].deleted = delta
|
||||
} else {
|
||||
newSnapshot.segment[i].deleted = s.root.segment[i].deleted.Clone()
|
||||
newSnapshot.segment[i].deleted.Or(delta)
|
||||
newSnapshot.segment[i].deleted = roaring.Or(s.root.segment[i].deleted, delta)
|
||||
}
|
||||
|
||||
newSnapshot.offsets[i] = running
|
||||
|
|
Loading…
Reference in New Issue
Block a user