diff options
author | Tor Egge <Tor.Egge@yahooinc.com> | 2022-11-09 13:25:39 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-09 13:25:39 +0100 |
commit | 3e22b115a7b8a3f5422063daf35ae9a80ddcd086 (patch) | |
tree | 4a1a88ce005b971d081811c97823a374bf49d952 /vespalib | |
parent | 57e3af042c60211d8dae92595700b5f95931f558 (diff) | |
parent | 917d7261d0df2cfca45564a8c6ddd78f3e860837 (diff) |
Merge pull request #24803 from vespa-engine/toregge/add-hnsw-simple-node
Add HnswSimpleNode.
Diffstat (limited to 'vespalib')
-rw-r--r-- | vespalib/src/vespa/vespalib/datastore/array_store.h | 3 | ||||
-rw-r--r-- | vespalib/src/vespa/vespalib/datastore/array_store.hpp | 7 |
2 files changed, 10 insertions, 0 deletions
diff --git a/vespalib/src/vespa/vespalib/datastore/array_store.h b/vespalib/src/vespa/vespalib/datastore/array_store.h index b847f3a5985..4c7f15d78e4 100644 --- a/vespalib/src/vespa/vespalib/datastore/array_store.h +++ b/vespalib/src/vespa/vespalib/datastore/array_store.h @@ -107,6 +107,9 @@ public: void remove(EntryRef ref); EntryRef move_on_compact(EntryRef ref) override; ICompactionContext::UP compactWorst(CompactionSpec compaction_spec, const CompactionStrategy& compaction_strategy); + // Use this if references to array store is not an array of AtomicEntryRef + std::unique_ptr<CompactingBuffers> start_compact_worst_buffers(CompactionSpec compaction_spec, const CompactionStrategy &compaction_strategy); + vespalib::MemoryUsage getMemoryUsage() const { return _store.getMemoryUsage(); } /** diff --git a/vespalib/src/vespa/vespalib/datastore/array_store.hpp b/vespalib/src/vespa/vespalib/datastore/array_store.hpp index 95f4a3c4155..cf158686f01 100644 --- a/vespalib/src/vespa/vespalib/datastore/array_store.hpp +++ b/vespalib/src/vespa/vespalib/datastore/array_store.hpp @@ -162,6 +162,13 @@ ArrayStore<EntryT, RefT, TypeMapperT>::compactWorst(CompactionSpec compaction_sp } template <typename EntryT, typename RefT, typename TypeMapperT> +std::unique_ptr<CompactingBuffers> +ArrayStore<EntryT, RefT, TypeMapperT>::start_compact_worst_buffers(CompactionSpec compaction_spec, const CompactionStrategy &compaction_strategy) +{ + return _store.start_compact_worst_buffers(compaction_spec, compaction_strategy); +} + +template <typename EntryT, typename RefT, typename TypeMapperT> vespalib::AddressSpace ArrayStore<EntryT, RefT, TypeMapperT>::addressSpaceUsage() const { |