Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SPARK-35146][SQL] Migrate to transformWithPruning or resolveWithPrun…
…ing for rules in finishAnalysis.scala ### What changes were proposed in this pull request? Added the following TreePattern enums: - BOOL_AGG - COUNT_IF - CURRENT_LIKE - RUNTIME_REPLACEABLE Added tree traversal pruning to the following rules: - ReplaceExpressions - RewriteNonCorrelatedExists - ComputeCurrentTime - GetCurrentDatabaseAndCatalog ### Why are the changes needed? Reduce the number of tree traversals and hence improve the query compilation latency. Performance improvement (org.apache.spark.sql.TPCDSQuerySuite): Rule name | Total Time (baseline) | Total Time (experiment) | experiment/baseline ReplaceExpressions | 27546369 | 19753804 | 0.72 RewriteNonCorrelatedExists | 17304883 | 2086194 | 0.12 ComputeCurrentTime | 35751301 | 19984477 | 0.56 GetCurrentDatabaseAndCatalog | 37230787 | 18874013 | 0.51 ### How was this patch tested? Existing tests. Closes #32461 from sigmod/finish_analysis. Authored-by: Yingyi Bu <yingyi.bu@databricks.com> Signed-off-by: Gengliang Wang <ltnwgl@gmail.com>
- Loading branch information
1 parent
c4ca232
commit 7c9a9ec
Showing
7 changed files
with
28 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters