Aman Sinha has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/20009 )

Change subject: IMPALA-12183: Fix cardinality clamping across aggregation phases
......................................................................


Patch Set 5: Code-Review+1

(1 comment)

LGTM.  Will bump the vote once the tests are completed and also give other 
reviewers some time to review.

http://gerrit.cloudera.org:8080/#/c/20009/4/testdata/workloads/functional-planner/queries/PlannerTest/tpcds-processing-cost.test
File 
testdata/workloads/functional-planner/queries/PlannerTest/tpcds-processing-cost.test:

http://gerrit.cloudera.org:8080/#/c/20009/4/testdata/workloads/functional-planner/queries/PlannerTest/tpcds-processing-cost.test@322
PS4, Line 322: 3373800
> I put some debugging logs and these are the num group estimates and the cap
Sounds good.  Just expanding a bit on the overall processing cost of this 
operator so we have a common understanding of this:
 - The UNION below the AGGREGATE #127 produces 276K rows.
 - AGGREGATE #127 has 5 agg classes - each class will internally process all 
276K rows but due to the group-by each class produces <= 276K rows and the 
total output cardinality of AGGREGATE #127 is 562K rows.  This corresponds to 
the processing cost of 8308890.  i.e processing 276K * 5 = 1380K rows costs 
8308890
 - AGGREGATE #215 is consuming the already grouped output per-class.  Class 0 
consumes Class 0 coming from #127 etc. so applying the per class cardinality 
you get total cost 3373800 which is 40% of the cost of #127.



--
To view, visit http://gerrit.cloudera.org:8080/20009
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I1d414fe56b027f887c7f901d8a6799a388b16b95
Gerrit-Change-Number: 20009
Gerrit-PatchSet: 5
Gerrit-Owner: Riza Suminto <[email protected]>
Gerrit-Reviewer: Abhishek Rawat <[email protected]>
Gerrit-Reviewer: Aman Sinha <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Kurt Deschler <[email protected]>
Gerrit-Reviewer: Riza Suminto <[email protected]>
Gerrit-Comment-Date: Wed, 07 Jun 2023 18:03:15 +0000
Gerrit-HasComments: Yes

Reply via email to