-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
GH-34529: [C++][Compute] Replace explicit checking with DCHECK for invariants in row segmenter #44236
Conversation
|
I found a remaining trivial enhancement request regarding to row segmenter, hence filing this trivial PR. @pitrou Mind to take a look? Thanks. |
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.
So they would not get error in these scenrio?
@@ -448,17 +431,6 @@ struct AnyKeysSegmenter : public BaseRowSegmenter { | |||
group_id_t save_group_id_; | |||
}; | |||
|
|||
Status CheckAndCapLengthForConsume(int64_t batch_length, int64_t& consume_offset, |
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.
Moved down into the next anonymous namespace enclosing Grouper
because this function is for Grouper
to use.
The errors touched in this PR are all internal invariants, that are not breakable by user inputs. In other words, these errors can only occur on bad implementation, so As a comparison, some checking, e.g. arrow/cpp/src/arrow/compute/row/grouper.cc Lines 65 to 68 in 80622fa
can be triggered by user's (invalid) input, so it is kept as is. |
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.
+1
After merging your PR, Conbench analyzed the 4 benchmarking runs that have been run so far on merge-commit ac6d7e8. There were no benchmark performance regressions. 🎉 The full Conbench report has more details. It also includes information about 10 possible false positives for unstable benchmarks that are known to sometimes produce them. |
Rationale for this change
As #34529 described.
What changes are included in this PR?
Change the
if
checking for invariants in row segmenter toDCHECK
.Are these changes tested?
No need.
Are there any user-facing changes?
None.