0lai0 commented on code in PR #4167:
URL: https://github.com/apache/datafusion-comet/pull/4167#discussion_r3175957033
##########
spark/src/test/scala/org/apache/comet/exec/CometNativeShuffleSuite.scala:
##########
@@ -281,6 +281,61 @@ class CometNativeShuffleSuite extends CometTestBase with
AdaptiveSparkPlanHelper
}
}
+ test("range partitioning on floating-point falls back when
strictFloatingPoint=true") {
+ withSQLConf(
+ CometConf.COMET_EXEC_SHUFFLE_WITH_RANGE_PARTITIONING_ENABLED.key ->
"true",
+ CometConf.COMET_EXEC_STRICT_FLOATING_POINT.key -> "true",
+ // Bypass the CometSortOrder-level Incompatible check so that only
+ // supportedRangePartitioningDataType is exercised as the guard.
+ CometConf.getExprAllowIncompatConfigKey("SortOrder") -> "true") {
+ val data = (0 until 100).map { i =>
+ val doubleValue = i % 4 match {
+ case 0 => Double.NaN
+ case 1 => -0.0d
+ case 2 => 0.0d
+ case _ => i.toDouble
+ }
+ (doubleValue, i)
+ }
Review Comment:
The PR has been updated.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]