-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Extend early dictionary assessment to all stripes #10131
Conversation
This pull request was exported from Phabricator. Differential Revision: D58396478 |
✅ Deploy Preview for meta-velox canceled.
|
This pull request was exported from Phabricator. Differential Revision: D58396478 |
828d8a5
to
c978fa0
Compare
…10131) Summary: Pull Request resolved: facebookincubator#10131 Follow up diff to allow assessing dictionary early for all stripes. Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops. Differential Revision: D58396478
This pull request was exported from Phabricator. Differential Revision: D58396478 |
…10131) Summary: Pull Request resolved: facebookincubator#10131 Follow up diff to allow assessing dictionary early for all stripes. Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops. Differential Revision: D58396478
c978fa0
to
dfb4a0e
Compare
This pull request was exported from Phabricator. Differential Revision: D58396478 |
…10131) Summary: Pull Request resolved: facebookincubator#10131 Follow up diff to allow assessing dictionary early for all stripes. Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops. Differential Revision: D58396478
dfb4a0e
to
ae53ba4
Compare
This pull request was exported from Phabricator. Differential Revision: D58396478 |
…10131) Summary: Pull Request resolved: facebookincubator#10131 Follow up diff to allow assessing dictionary early for all stripes. Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops. Differential Revision: D58396478
ae53ba4
to
9a745b0
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.
@HuamengJiang LGTM. Thanks!
void DefaultFlushPolicy::setNextDictionaryCheckThreshold( | ||
uint64_t stripeSizeEstimate) { | ||
const auto increment = | ||
stripeSizeThreshold_ / kNumDictionaryAssessmentsPerStripe; |
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.
Can you add a member say dictionaryCheckIncrement_? And
add VELOX_CHECK_GT(dictionaryCheckIncrement_, 0);
return FlushDecision::EVALUATE_DICTIONARY; | ||
if (stripeIndex_ < stripeProgress.stripeIndex) { | ||
dictionaryCheckThreshold_ = 0; | ||
setNextDictionaryCheckThreshold(); |
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.
SCOPE_EXIT{ setNextDictionaryCheckThreshold(stripeProgress.stripeSizeEstimate); };
if (stripeIndex_ < stripeProgress.stripeIndex) {
setNextDictionaryCheckThreshold();
}
if (stripeProgress.stripeSizeEstimate >= dictionaryCheckThreshold_) {
return FlushDecision::CHECK_DICTIONARY;
}
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.
This is more rigorous, but we only need to call it very rarely through the stripe instead of every batch written. I think of the current implementation as lazily incrementing the check threshold.
This pull request was exported from Phabricator. Differential Revision: D58396478 |
…10131) Summary: Pull Request resolved: facebookincubator#10131 Follow up diff to allow assessing dictionary early for all stripes. Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops. Reviewed By: xiaoxmeng Differential Revision: D58396478
9a745b0
to
029a9a1
Compare
This pull request was exported from Phabricator. Differential Revision: D58396478 |
…10131) Summary: Pull Request resolved: facebookincubator#10131 Follow up diff to allow assessing dictionary early for all stripes. Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops. Reviewed By: xiaoxmeng Differential Revision: D58396478
029a9a1
to
439e86f
Compare
This pull request was exported from Phabricator. Differential Revision: D58396478 |
…10131) Summary: Pull Request resolved: facebookincubator#10131 Follow up diff to allow assessing dictionary early for all stripes. Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops. Reviewed By: xiaoxmeng Differential Revision: D58396478
439e86f
to
fcbbe64
Compare
…10131) Summary: Pull Request resolved: facebookincubator#10131 Follow up diff to allow assessing dictionary early for all stripes. Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops. Reviewed By: xiaoxmeng Differential Revision: D58396478
This pull request was exported from Phabricator. Differential Revision: D58396478 |
fcbbe64
to
31a7586
Compare
This pull request has been automatically marked as stale because it has not had recent activity. If you'd still like this PR merged, please comment on the PR, make sure you've addressed reviewer comments, and rebase on the latest main. Thank you for your contributions! |
Summary:
Follow up diff to allow assessing dictionary early for all stripes.
Currently, this will cause continual invocation of abandonDictionaries for later stripes that are no-ops.
Differential Revision: D58396478