mrhhsg commented on code in PR #68113: URL: https://github.com/apache/doris/pull/68113#discussion_r4033852489
########## regression-test/data/query_p0/sql_functions/window_functions/test_window_float_sliding_frame.out: ########## @@ -0,0 +1,66 @@ +-- This file is automatically generated. You should know what you did if you want to edit this +-- !avg_double_preceding_1 -- +1 1.8014398509481984e+16 1.8014398509481984e+16 +2 1 9007199254740992 +3 1 1 +4 1 1 + +-- !sum_double_preceding_1 -- +1 1.8014398509481984e+16 1.8014398509481984e+16 +2 1 1.8014398509481984e+16 +3 1 2 +4 1 2 + +-- !avg_sum_float_preceding_1 -- +1 1.6777216E7 16777216 16777216 +2 1.0 8388608.5 16777217 +3 1.0 1 2 +4 1.0 1 2 + +-- !avg_sum_double_sign_flip -- +5 1.8014398509481984e+16 1.8014398509481984e+16 1.8014398509481984e+16 +6 1 9007199254740992 1.8014398509481984e+16 +7 -1.8014398509481984e+16 0 0 Review Comment: Agreed, and the same grouping dependence also affected the UNBOUNDED row with frame [2^54, 1, 1, 1] (2^54 vs 2^54 + 4 depending on association). Fixed in b4cabf56238: the small value is now 0.5 (up to three of them stay below half an ulp of 2^54, so every grouping rounds the frame sum back to 2^54 while incremental removal would still leave the wrong small sum), the sign-flip query uses 1 PRECEDING so mixed-sign frames have two operands only, and the FLOAT rows use 2^54 so the double accumulator actually rounds. Expected output regenerated and re-run locally. -- 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]
