adriangb commented on PR #9511:
URL: https://github.com/apache/arrow-rs/pull/9511#issuecomment-4057469543

   @alamb this is the point:
   
   ```
   true_count(all_true, 65536)          1.00    228.0±0.13ns        ? ?/sec
   vs
   has_true(all_true, 65536)            1.00     13.7±0.03ns        ? ?/sec
   ```
   
   and
   
   ````
   true_count(all_false, 65536)         1.00    227.8±0.19ns        ? ?/sec
   vs
   has_false(all_false, 65536)          1.00     13.6±0.03ns        ? ?/sec
   ```
   
   By stopping early we get huge wins.
   
   At the same time we the worst case is not any slower:
   
   ```
   true_count(all_true, 65536)          1.00    228.0±0.13ns        ? ?/sec
   vs.
   has_false(all_true, 65536)           1.00    123.1±0.63ns        ? ?/sec
   ```
   
   (in fact a bit faster because it's a cheaper operation)
   
   I had to do some chunked vectorization to be able to achieve both of these 
goals.


-- 
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]

Reply via email to