-
Notifications
You must be signed in to change notification settings - Fork 168
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Getting rid of some glue code #7748
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, just small comments..
src/realm/array_direct.hpp
Outdated
result |= second_word << first_word_size; | ||
// note: above shifts in zeroes below the bits we want | ||
} | ||
_bump(num_bits); | ||
return result; | ||
} | ||
uint64_t get_with_unsafe_prefetch(size_t num_bits) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are now fetching and moving the iterator in this method, probably we should rename it? Even though, I don't expect anybody to use the iterator. Although, it can be useful if we want to access the data directly.
src/realm/array_direct.hpp
Outdated
@@ -710,11 +593,9 @@ size_t parallel_subword_find(VectorCompare vector_compare, const uint64_t* data, | |||
while (total_bit_count_left >= fast_scan_limit) { | |||
// unrolling 2x | |||
const auto word0 = it.get_with_unsafe_prefetch(bit_count_pr_iteration); | |||
it.bump(bit_count_pr_iteration); | |||
const auto word1 = it.get_with_unsafe_prefetch(bit_count_pr_iteration); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think renaming the method will make it clear that it has been moved by bit_count_pr_iterations
bits.
Pull Request Test Coverage Report for Build jorgen.edelbo_277Details
💛 - Coveralls |
What, How & Why?
☑️ ToDos
bindgen/spec.yml
, if public C++ API changed