sunchao commented on PR #5558: URL: https://github.com/apache/datafusion-comet/pull/5558#issuecomment-5534196629
**I’d ask for it in this PR, at medium priority (P2).** The current implementation is correct, but the improvement is a small predicate/branch swap with reproducible savings and no added abstraction. Its importance depends on the query: - **Two arguments or a constant non-null replacement:** unaffected; these calls already avoid the guard. - **A replacement column containing mixed nulls:** meaningful savings. We measured about 29% less expression time for short arrays at 50% null replacements. - **Large arrays with mostly null replacements:** potentially substantial. The current guard copies considerable data that it immediately discards. The whole-query benefit remains unmeasured. A 97.5% reduction in this expression’s time does **not** imply a similar query speedup. The strongest reason to take it now is the favorable tradeoff: **a tiny change removes avoidable work while preserving the existing design and tested error behavior.** The evidence supports that small fix; it does not justify a larger custom implementation. -- 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]
