Skip to content
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

[C++][Gandiva] Exported functions are registered multiple times in gandiva #37751

Closed
niyue opened this issue Sep 16, 2023 · 1 comment · Fixed by #37752
Closed

[C++][Gandiva] Exported functions are registered multiple times in gandiva #37751

niyue opened this issue Sep 16, 2023 · 1 comment · Fixed by #37752

Comments

@niyue
Copy link
Contributor

niyue commented Sep 16, 2023

Describe the bug, including details regarding any error messages, version, and platform.

The exported functions defined in gandiva are registered multiple times unnecessarily.

Currently, in gandiva, exported functions are registered to the function registry in exported_funcs.h by using a macro REGISTER_EXPORTED_FUNCS, which internally defines a static variable to call the registration. Since this header file (exported_funcs.h) is included in multiple times in different files (7 different files more specifically), this makes the registration happens 7 times for the same set of functions, which is not necessary. It makes the initialization slower, additionally, it makes the registration to contain duplicated functions (although it still works so far).

Component(s)

C++ - Gandiva

pitrou pushed a commit that referenced this issue Oct 16, 2023
…e times in gandiva (#37752)

### 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

Authored-by: Yue Ni <niyue.com@gmail.com>
Signed-off-by: Antoine Pitrou <antoine@python.org>
@pitrou pitrou added this to the 15.0.0 milestone Oct 16, 2023
@pitrou
Copy link
Member

pitrou commented Oct 16, 2023

Issue resolved by pull request 37752
#37752

@kou kou changed the title [C++] [Gandiva] Exported functions are registered multiple times in gandiva [C++][Gandiva] Exported functions are registered multiple times in gandiva Oct 16, 2023
JerAguilon pushed a commit to JerAguilon/arrow that referenced this issue Oct 23, 2023
…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 <niyue.com@gmail.com>
Signed-off-by: Antoine Pitrou <antoine@python.org>
loicalleyne pushed a commit to loicalleyne/arrow that referenced this issue Nov 13, 2023
…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 <niyue.com@gmail.com>
Signed-off-by: Antoine Pitrou <antoine@python.org>
dgreiss pushed a commit to dgreiss/arrow that referenced this issue Feb 19, 2024
…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 <niyue.com@gmail.com>
Signed-off-by: Antoine Pitrou <antoine@python.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants