Github user viirya commented on a diff in the pull request:
https://github.com/apache/spark/pull/19767#discussion_r152436838
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/conditionalExpressions.scala
---
@@ -64,52 +64,22 @@ case class If(predicate: Expression, trueValue:
Expression, falseValue: Expressi
val trueEval = trueValue.genCode(ctx)
val falseEval = falseValue.genCode(ctx)
- // place generated code of condition, true value and false value in
separate methods if
- // their code combined is large
- val combinedLength = condEval.code.length + trueEval.code.length +
falseEval.code.length
--- End diff --
Two problems I think for this. One is even the two childs' code don't
exceed the threshold individually, a method not over 64k but over 8k is still
big and bad for JIT. One is we estimate it with code length, I'm not sure if
two 1000 length childs won't definitely generate 64k method in the end.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]