andygrove opened a new pull request, #4678: URL: https://github.com/apache/datafusion-comet/pull/4678
## Which issue does this PR close? Part of #4673. ## Rationale for this change The serde framework intends that an expression declares whether it can be accelerated through `getSupportLevel`, with the central dispatcher in `QueryPlanSerde` translating `Incompatible`/`Unsupported` into the appropriate fallback. Several aggregate serdes instead made these decisions inside `convert` by calling `withFallbackReason` directly, even though the decisions are statically determinable from the expression. ## What changes are included in this PR? Move static support decisions out of `convert` and into `getSupportLevel` for the aggregate expressions: - `Min`, `Max`: unsupported data type and the strict-floating-point gate, via a shared `AggSerde.minMaxSupportLevel` helper. - `Average`, `Sum`, `BitAndAgg`, `BitOrAgg`, `BitXorAgg`: unsupported data type. - `BloomFilterAggregate`: unsupported child data type (the static type filter that was embedded in the convert guard). This is behavior-preserving: every case that previously fell back to Spark continues to fall back. The remaining `withFallbackReason` calls in this file are child-reason rollups, including the `serializeDataType` rollups gated on `dataType.isEmpty`, which are the intended use inside `convert`. ## How are these changes tested? Covered by existing tests in `CometAggregateSuite` (80 tests covering min/max/sum/avg/bit aggregates and decimal/float paths) and the `bloom_filter_agg` test in `CometExecSuite`, which exercise both the supported and fallback paths. -- 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]
