morrySnow commented on code in PR #51127:
URL: https://github.com/apache/doris/pull/51127#discussion_r2101777618


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/cost/CostModelV1.java:
##########
@@ -559,9 +559,13 @@ public Cost visitPhysicalNestedLoopJoin(
         Preconditions.checkState(context.arity() == 2);
         Statistics leftStatistics = context.getChildStatistics(0);
         Statistics rightStatistics = context.getChildStatistics(1);
+        double nljPenalty = 1.0;
+        if (leftStatistics.getRowCount() < 10 * rightStatistics.getRowCount()) 
{
+            nljPenalty = Math.min(leftStatistics.getRowCount(), 
rightStatistics.getRowCount());
+        }

Review Comment:
   add comment to explain the effect of the penalty



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to