extract the pruning strategy from HGraph#373
Conversation
| GraphInterfacePtr graph, | ||
| const FlattenInterfacePtr flatten, | ||
| MutexStrategyPtr neighbors_mutexs, | ||
| Allocator* allocator); |
There was a problem hiding this comment.
The is_update parameter has been removed (currently, there are no uses where it would be set to true)
Codecov ReportAttention: Patch coverage is @@ Coverage Diff @@
## main #373 +/- ##
==========================================
+ Coverage 91.28% 91.31% +0.03%
==========================================
Files 140 143 +3
Lines 8968 8997 +29
==========================================
+ Hits 8186 8216 +30
+ Misses 782 781 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report in Codecov by Sentry.
|
37474da to
7311f86
Compare
|
|
||
| void | ||
| PointsMutex::Unlock(uint32_t i) { | ||
| neighbors_mutex_[i].unlock_shared(); |
There was a problem hiding this comment.
neighbors_mutex_[i].unlock() ?
704cf9e to
d2f280a
Compare
|
|
||
| void | ||
| PointsMutex::Resize(uint32_t new_element_num) { | ||
| neighbors_mutex_.resize(new_element_num); |
There was a problem hiding this comment.
the Resize is not thread-safe implement ?
There was a problem hiding this comment.
The control for thread-safety will be handled externally
| void | ||
| HGraph::resize(uint64_t new_size) { | ||
| auto cur_size = this->neighbors_mutex_.size(); | ||
| auto cur_size = this->labels_.size(); |
There was a problem hiding this comment.
auto cur_size = this->neighbors_mutex_ ? this->neighbors_mutex_->Size() : 0; ?
There was a problem hiding this comment.
Here, the size represents the capacity, and it has been switched to use max_capacity_ to record it.
|
|
||
| private: | ||
| Vector<std::shared_ptr<std::shared_mutex>> neighbors_mutex_; | ||
| Allocator* allocator_{nullptr}; |
64b396a to
c3c1e8f
Compare
Signed-off-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com>
c3c1e8f to
97a611d
Compare
Signed-off-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com> Co-authored-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com>
Signed-off-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com> Co-authored-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com>
Signed-off-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com> Co-authored-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com> Signed-off-by: LHT129 <tianlan.lht@antgroup.com>
Signed-off-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com> Co-authored-by: jinjiabao.jjb <jinjiabao.jjb@antgroup.com> Signed-off-by: Sia Sheerland <x1075956441x@163.com> Signed-off-by: Sia Sheerland <x1075956441x@163.com>
No description provided.