Github user a10y commented on a diff in the pull request:
https://github.com/apache/spark/pull/18931#discussion_r144025706
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/execution/WholeStageCodegenExec.scala
---
@@ -175,6 +175,25 @@ trait CodegenSupport extends SparkPlan {
}
/**
+ * In Java, a method descriptor is valid only if it represents method
parameters with a total
+ * length of 255 or less. `this` contributes one unit and a parameter of
type long or double
+ * contributes two units. Besides, for nullable parameters, we also need
to pass a boolean
+ * for the null status.
+ */
+ private def isValidParamLength(ctx: CodegenContext): Boolean = {
+ var paramLength = 1 // for `this` parameter.
+ output.foreach { attr =>
--- End diff --
(nit: This could be written as a `foldLeft` and then you can eliminate the
`var`)
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]