-
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-37751: [C++][Gandiva] Avoid registering exported functions multiple times in gandiva #37752
Conversation
Thanks for opening a pull request! If this is not a minor PR. Could you open an issue for this pull request on GitHub? https://github.com/apache/arrow/issues/new/choose Opening GitHub issues ahead of time contributes to the Openness of the Apache Arrow project. Then could you also rename the pull request title in the following format?
or
In the case of PARQUET issues on JIRA the title also supports:
See also: |
cpp/src/gandiva/exported_funcs.cc
Outdated
REGISTER_EXPORTED_FUNCS(ExportedTimeFunctions); | ||
REGISTER_EXPORTED_FUNCS(ExportedDecimalFunctions); | ||
REGISTER_EXPORTED_FUNCS(ExportedStringFunctions); | ||
REGISTER_EXPORTED_FUNCS(ExportedHashFunctions); |
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.
All the REGISTER_EXPORTED_FUNCS
are moved into a exported_funcs.cc
file, which makes the registration API to be called from 7 * 6 times down to 6 times.
bc2c673
to
5eaf0f8
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.
Some minor nits. Can you also add a unit test to make sure each function is only registered once?
Can you also fix the lint issue in CI? |
9ebb6b4
to
92fbf55
Compare
Sure. I fixed the lint issue in CI in the new commit. |
@js8544 I tried to do that, but currently the UPDATE: |
5482a47
to
af90fa2
Compare
@js8544 this PR is ready for review. There is still one check failing, but it seemed irrelevant with my change (may be caused by CI network issue as far as I can tell). Any comment is appreciated. Thanks. |
af90fa2
to
3cf1766
Compare
@js8544 I've resolved the remaining issues and rebased to the latest commit, could you please take a look again? Thanks. |
@github-actions crossbow submit -g cpp |
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, just a simple nit.
Revision: 3925cad Submitted crossbow builds: ursacomputing/crossbow @ actions-0aa03adfc8 |
@github-actions crossbow submit -g python |
Revision: 9e7ebb5 Submitted crossbow builds: ursacomputing/crossbow @ actions-d691ca469b |
… of testing and use pointers as returned value for consistent with coding convention.
9e7ebb5
to
49ea793
Compare
Thanks! LGTM now. Will need @pitrou's approval to merge. |
After merging your PR, Conbench analyzed the 6 benchmarking runs that have been run so far on merge-commit 47314e8. There were no benchmark performance regressions. 🎉 The full Conbench report has more details. |
…ultiple times in gandiva (apache#37752) ### Rationale for this change Try to fix apache#37751 ### What changes are included in this PR? The exported functions defined in gandiva are registered multiple times unnecessarily. This PR tries to address this issue. ### Are these changes tested? Yes. ### Are there any user-facing changes? No Authored-by: Yue Ni <[email protected]> Signed-off-by: Antoine Pitrou <[email protected]>
…ultiple times in gandiva (apache#37752) ### Rationale for this change Try to fix apache#37751 ### What changes are included in this PR? The exported functions defined in gandiva are registered multiple times unnecessarily. This PR tries to address this issue. ### Are these changes tested? Yes. ### Are there any user-facing changes? No Authored-by: Yue Ni <[email protected]> Signed-off-by: Antoine Pitrou <[email protected]>
…ultiple times in gandiva (apache#37752) ### Rationale for this change Try to fix apache#37751 ### What changes are included in this PR? The exported functions defined in gandiva are registered multiple times unnecessarily. This PR tries to address this issue. ### Are these changes tested? Yes. ### Are there any user-facing changes? No Authored-by: Yue Ni <[email protected]> Signed-off-by: Antoine Pitrou <[email protected]>
Rationale for this change
Try to fix #37751
What changes are included in this PR?
The exported functions defined in gandiva are registered multiple times unnecessarily. This PR tries to address this issue.
Are these changes tested?
Yes.
Are there any user-facing changes?
No