-
-
Notifications
You must be signed in to change notification settings - Fork 65
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
Dynamic dispatch for block codecs #579
Conversation
f1d5888
to
7a94fb4
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #579 +/- ##
==========================================
+ Coverage 93.27% 93.86% +0.58%
==========================================
Files 89 80 -9
Lines 4448 3881 -567
==========================================
- Hits 4149 3643 -506
+ Misses 299 238 -61 ☔ View full report in Codecov by Sentry. |
Benchmarking on MS-Marco v2 passages with BM25: main
this
|
In other words, it looks to have no performance penalty? Seems kind of weird but I'll take it. We should double check that we're doing what we think we're doing I guess... |
I tested stream_vbyte as well with MaxScore k=10, found no regressions.
Edit: "main" is not really main, it's just |
@amallia FYI we did some testing here regarding dynamic dispatch for block codecs. Seems no performance regression. I think we'll have to go for it. This will simplify the code, make the compilation faster, and so on. I'm planning to work on porting all the code to the new type-erased block codec as part of this PR. Let me know if you have any comment regarding the general idea; I'll let you both know when it's ready for review. |
f20581b
to
173c74f
Compare
a19c652
to
9c5438e
Compare
6de9e8b
to
06a74cc
Compare
ed97d5e
to
6178ca5
Compare
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.
Sorry this took so long, Michal. It all looks great, and I think it is worth the very minor performance hit.
@JMMackenzie Thanks! Before merging, I'll clean up the git history here. I might just squash all of it, but at least I want it clean and have some important info in it, including some performance disclaimers. |
Use dynamic dispatch for block codecs. The old class template
block_freq_index
is replaced by theBlockInvertedIndex
class. This classcontains a shared pointer to a
BlockCodec
object, which is a superclass ofall block codec implementations.
Changelog-changed:
BlockInvertedIndex
replacesblock_freq_index
Changelog-performance: Expect a slight performance drop of all block codecs