Hello Anurag Mantripragada, Vihang Karajgaonkar, Impala Public Jenkins, I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/15157 to look at the new patch set (#2). Change subject: IMPALA-9358: Query slowdown with inline views and hundreds of columns ...................................................................... IMPALA-9358: Query slowdown with inline views and hundreds of columns IMPALA-8386 introduced an expensive precondition check using the function ExprSubstitutionMap.checkComposedFrom(). This check has significant performance impact on statements that contain inline views with hundreds of columns. Most of the cost is in the get() calls used to find expressions in the local substitution map. The fix is to add a get_hint() call that uses the current loop index as a starting point to search for expressions. This leverages the fact that expressions have identical positions in both substitution maps in most common cases. A more generic approach would be to accelerate expression equality search using hash functions but that would be a much riskier fix and Impala currently lacks the infrasturucture to so. Testing: Performance testing with a query with 1000 expressions of the following form: with a as (select c1 c1, c1 c2, c1 c3, ... from t) select c1, c2, c3, ... from a; Change-Id: I77423d9c10e1edbb505cb210b5c072281b5d7cfc --- M fe/src/main/java/org/apache/impala/analysis/ExprSubstitutionMap.java 1 file changed, 16 insertions(+), 2 deletions(-) git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/57/15157/2 -- To view, visit http://gerrit.cloudera.org:8080/15157 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: newpatchset Gerrit-Change-Id: I77423d9c10e1edbb505cb210b5c072281b5d7cfc Gerrit-Change-Number: 15157 Gerrit-PatchSet: 2 Gerrit-Owner: Kurt Deschler <kdesc...@cloudera.com> Gerrit-Reviewer: Anurag Mantripragada <anu...@cloudera.com> Gerrit-Reviewer: Impala Public Jenkins <impala-public-jenk...@cloudera.com> Gerrit-Reviewer: Kurt Deschler <kdesc...@cloudera.com> Gerrit-Reviewer: Vihang Karajgaonkar <vih...@cloudera.com>