maropu commented on a change in pull request #25827: [SPARK-29128][SQL] Split 
predicate code in OR expressions
URL: https://github.com/apache/spark/pull/25827#discussion_r325487146
 
 

 ##########
 File path: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/Expression.scala
 ##########
 @@ -156,6 +156,12 @@ abstract class Expression extends TreeNode[Expression] {
 
   private def reduceCodeSize(ctx: CodegenContext, eval: ExprCode): Unit = {
     // TODO: support whole stage codegen too
+    //
+    // NOTE: We could use `CodeGenerator.defineIndependentFunction` here for 
the code path
+    // of the whole stage codegen. But, we don't do so now because the 
performance changes that
+    // we don't expect might occur in many queries. Therefore, we currently 
apply
+    // this split function to specific performance-sensitive places only,
+    // e.g., common subexpression elimination for the whole stage codegen and 
OR expressions.
 
 Review comment:
   Aha, I see.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

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

Reply via email to