Alexey Serbin has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/20288 )

Change subject: [common] minor optimization on ComputeHashBuckets
......................................................................


Patch Set 1:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/20288/1/src/kudu/common/partition_pruner.cc
File src/kudu/common/partition_pruner.cc:

http://gerrit.cloudera.org:8080/#/c/20288/1/src/kudu/common/partition_pruner.cc@225
PS1, Line 225: if (std::all_of(hash_bucket_bitset->begin(),
             :                   hash_bucket_bitset->end(),
             :                   [](bool b) { return b; })) {
             :     return;
             :   }
> Both are right.
Yes, that's right: std::all_of() is implemented a smart way and returns right 
away if it finds any element where the predicate evaluates to 'false'.   Also, 
it returns 'true' if the container is empty.  With that, the new code does 
what's necessary.



--
To view, visit http://gerrit.cloudera.org:8080/20288
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iecd9a739f408646c0dab74727f919e4f6ce3ce7e
Gerrit-Change-Number: 20288
Gerrit-PatchSet: 1
Gerrit-Owner: Alexey Serbin <[email protected]>
Gerrit-Reviewer: Abhishek Chennaka <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Mahesh Reddy <[email protected]>
Gerrit-Reviewer: Yifan Zhang <[email protected]>
Gerrit-Reviewer: Yingchun Lai <[email protected]>
Gerrit-Reviewer: Yuqi Du <[email protected]>
Gerrit-Comment-Date: Tue, 01 Aug 2023 14:17:29 +0000
Gerrit-HasComments: Yes

Reply via email to