This is an automated email from the ASF dual-hosted git repository.
philo pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-gluten.git
The following commit(s) were added to refs/heads/main by this push:
new dafb3715e [VL] Remove a workaround fix for ignoreNulls of lead/lag
function (#5084)
dafb3715e is described below
commit dafb3715ec1b71d22d60830b5e963729443e6ec8
Author: Xiduo You <[email protected]>
AuthorDate: Fri Mar 22 22:53:26 2024 +0800
[VL] Remove a workaround fix for ignoreNulls of lead/lag function (#5084)
---
.../io/glutenproject/backendsapi/SparkPlanExecApi.scala | 12 +-----------
1 file changed, 1 insertion(+), 11 deletions(-)
diff --git
a/gluten-core/src/main/scala/io/glutenproject/backendsapi/SparkPlanExecApi.scala
b/gluten-core/src/main/scala/io/glutenproject/backendsapi/SparkPlanExecApi.scala
index 4166c4a68..1b892ff59 100644
---
a/gluten-core/src/main/scala/io/glutenproject/backendsapi/SparkPlanExecApi.scala
+++
b/gluten-core/src/main/scala/io/glutenproject/backendsapi/SparkPlanExecApi.scala
@@ -555,16 +555,6 @@ trait SparkPlanExecApi {
attributeSeq = originalInputAttributes)
.doTransform(args))
}
- val ignoreNulls = if (offset == 0) {
- // This is a workaround for Velox backend, because velox has bug
if the
- // ignoreNulls is true and offset is 0.
- // Logically, if offset is 0 the ignoreNulls is always
meaningless, so
- // this workaround is safe.
- // TODO, remove this once Velox has fixed it
- false
- } else {
- offsetWf.ignoreNulls
- }
val windowFunctionNode = ExpressionBuilder.makeWindowFunction(
WindowFunctionsBuilder.create(args, offsetWf).toInt,
childrenNodeList,
@@ -573,7 +563,7 @@ trait SparkPlanExecApi {
WindowExecTransformer.getFrameBound(frame.upper),
WindowExecTransformer.getFrameBound(frame.lower),
frame.frameType.sql,
- ignoreNulls
+ offsetWf.ignoreNulls
)
windowExpressionNodes.add(windowFunctionNode)
case wf @ NthValue(input, offset: Literal, ignoreNulls: Boolean) =>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]