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

UDF fails when subexpression elimination is used in interpreted mode #803

Open
chris-twiner opened this issue Mar 14, 2024 · 1 comment
Open

Comments

@chris-twiner
Copy link
Contributor

As UDF expects compilation always this fails when a child cannot compile, such as ExpressionProxy.

If, in interpreted mode, a child is deemed an identical subexpression (as occurs in the UdfTests."multiple two argument udf" test) spark is able to swap the contents as an optimisation to reduce re-calculation.

In the case where the analyser deems compilation the correct approach this isn't an issue. Targeted fix as part of #800.

Known to occur on Databricks 11.3 and other lower runtimes, fixed as part of 3.4 in SPARK-41991 .

chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 14, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 14, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 14, 2024
@chris-twiner
Copy link
Contributor Author

changing title to represent the wider issue (not fixed in b16067). The above fixes subexpression elimination used in interpreted mode.

This problem exists for all such code, and any could be added. In order to properly fix it needs an eval mode as well.

chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 20, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 20, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 20, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
chris-twiner added a commit to chris-twiner/frameless that referenced this issue Mar 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant