memgraph/tests/benchmark
Matej Ferencevic 4d2eda398f Improve property store performance
Summary:
This diff improves the performance of `PropertyStore` with two main
techniques:

First:
`PropertyValue` has a very expensive constructor and destructor. The
`PropertyValue` was previously passed as a return value from many functions
wrapped in a `std::optional`. That caused the `PropertyValue`
constructor/destructor to be called for each intermediary value that was passed
between functions. This diff changes the functions to return a `bool` value
that imitates the `std::optional` "emptyness" flag and the `PropertyValue` is
modified using a pointer to it so that its constructor/destructor is called
only once.

Second:
The `PropertyStore` buffer was previously iterated through at least twice.
First to determine the exact position of the encoded property and then to
actually decode the property. This diff combines the two passes into a single
pass so that the property is immediately loaded if it is found.

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D2766
2020-05-05 10:55:00 +02:00
..
data_structures Stop building storage v1 2020-01-13 14:18:12 +01:00
query Remove old storage types 2020-01-23 14:32:33 +01:00
CMakeLists.txt Improve property store performance 2020-05-05 10:55:00 +02:00
expansion.cpp Migrate tests to storage v2 part 1 2019-11-21 19:00:32 +01:00
rpc.cpp Move RPC to root source directory 2020-01-27 11:50:24 +01:00
skip_list_common.hpp Implement new SkipList 2019-01-14 13:01:15 +01:00
skip_list_random.cpp Implement new SkipList 2019-01-14 13:01:15 +01:00
skip_list_real_world.cpp Implement new SkipList 2019-01-14 13:01:15 +01:00
skip_list_same_item.cpp Implement new SkipList 2019-01-14 13:01:15 +01:00
skip_list_vs_stl.cpp Add PoolResource benchmarking in execution and skiplist 2019-08-27 09:32:01 +02:00
storage_v2_gc.cpp Make storage v2 config hierarchical 2019-09-23 16:03:53 +02:00
storage_v2_property_store.cpp Improve property store performance 2020-05-05 10:55:00 +02:00