You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[SPARK-48771][SQL] Speed up LogicalPlanIntegrity.validateExprIdUniqueness for large query plans
### What changes were proposed in this pull request?
This PR rewrites `LogicalPlanIntegrity.hasUniqueExprIdsForOutput` to only traverse the query plan once and avoids expensive Scala collections operations like `.flatten`, `.groupBy`, and `.distinct`.
### Why are the changes needed?
Speeds up query compilation when plan validation is enabled.
### Does this PR introduce _any_ user-facing change?
No.
### How was this patch tested?
Made sure existing UTs pass.
### Was this patch authored or co-authored using generative AI tooling?
No.
Closes#47170 from kelvinjian-db/SPARK-48771-speed-up.
Authored-by: Kelvin Jiang <kelvin.jiang@databricks.com>
Signed-off-by: Wenchen Fan <wenchen@databricks.com>
0 commit comments