ding-young commented on PR #15589:
URL: https://github.com/apache/datafusion/pull/15589#issuecomment-2782347240

   I wrote a simple criterion bench 
(https://github.com/ding-young/datafusion/blob/simplify-trivial-eq-bench/datafusion/core/benches/simplify_trivial_eq.rs)
 and the result is as follows. 
   It showed performance improvement, especially for comparing long strings. 
   ```
   select_f32_eq_f32       time:   [366.19 µs 366.42 µs 366.69 µs]
                           change: [-79.571% -79.180% -78.787%] (p = 0.00 < 
0.05)
                           Performance has improved.
   Found 8 outliers among 100 measurements (8.00%)
     2 (2.00%) high mild
     6 (6.00%) high severe
   
   select_str_eq_str       time:   [372.53 µs 373.02 µs 373.61 µs]
                           change: [-85.333% -85.117% -84.884%] (p = 0.00 < 
0.05)
                           Performance has improved.
   Found 10 outliers among 100 measurements (10.00%)
     4 (4.00%) high mild
     6 (6.00%) high severe
   
   select_str_eq_str_long  time:   [372.49 µs 372.85 µs 373.25 µs]
                           change: [-98.351% -98.316% -98.280%] (p = 0.00 < 
0.05)
                           Performance has improved.
   Found 9 outliers among 100 measurements (9.00%)
     3 (3.00%) high mild
     6 (6.00%) high severe
   ```
   
   Plus, since `x IS NOT NULL OR NULL` is slightly better than `CASE`, I'll 
leave the pr as is :)  
   ```
   select_CASE_str_eq_str_long
                           time:   [396.36 µs 396.73 µs 397.15 µs]
   Found 10 outliers among 100 measurements (10.00%)
     2 (2.00%) high mild
     8 (8.00%) high severe
   ```
   Thanks for the review! Trying out the bench was also a great experience for 
me.


-- 
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: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to