Optimize OffsetRangeQuery
- Lenguaje dominante
- Rust
- Estrellas
- 42
- Forks
- 6
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
The Query implementation for OffsetRangeQuery is currently obviously correct, but less than optimal.
```rust
fn containing(&self, mut offset: u64, index: &LeafIndex, res: &mut [bool]) {
let range = offset..offset + index.keys.count();
// shortcut test
if !&self.0.intersects(&range) {
res.clear();
} else {
for i in 0..(index.keys.len()).min(res.len()) {
if res[i] {
res[i] = self.0.contains(&offset);
}
offset += 1;
}
}
}
```
Obviously this can be done more efficiently than checking every single offset.
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Evaluación
Este issue todavía no se ha evaluado.