-
Notifications
You must be signed in to change notification settings - Fork 332
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
feat(flow): add eval_batch
for ScalarExpr
#4551
Conversation
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configuration File (
|
992a299
to
dd26aa4
Compare
eval_batch
for ScalarExpr
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4551 +/- ##
==========================================
- Coverage 84.94% 84.50% -0.44%
==========================================
Files 1090 1093 +3
Lines 194325 195994 +1669
==========================================
+ Hits 165069 165625 +556
- Misses 29256 30369 +1113 |
@discord9 Good job, could you show us the performance analysis comparison before and after this PR to clearly see the optimization effect? |
It would still require some more change of code to make MapFilterProject Operator to use batching process, which I'm working on adding it, will include performance analysis in later PR |
CI failed, cc @discord9 |
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.
LGTM
2e920b4
to
396d808
Compare
* refactor: better perf flow * feat(WIP): batching proc * feat: UnaryFunc::eval_batch untested * feat: BinaryFunc::eval_batch untested * feat: VariadicFunc::eval_batch un tested * feat: literal eval_batch * refactor: move DfScalarFunc to separate file * chore: remove unused imports * feat: eval_batch df func&ifthen * chore: remove unused file * refactor: use Batch type * chore: remove unused * chore: remove a done TODO * refactor: per review * chore: import * refactor: eval_batch if then * chore: typo
I hereby agree to the terms of the GreptimeDB CLA.
Refer to a related PR or issue link (optional)
What's changed and what's your intention?
add
eval_batch
for flow'sScalarExpr
, which can be use later to optimize performance for flow and reduce small object alloc/dealloc(which is found to be a very large cost on cpu time when profiling flow tasks).The major change of logic happens in the following files:
src/flow/src/expr/func.rs
include threeeval_batch
functionsrc/flow/src/expr/scalar.rs
'sScalarExpr::eval_batch
functionsrc/flow/src/expr/df_func.rs
'seval_batch
functionand other changes are just moving file around and remove unused imports
Checklist