This matches APInt's versions of these functions, and there is no need for these to be size_t.
(as well as __builtin_clzll())
| Paths 
 |  Differential  D60823  
[Support] make countLeadingZeros() countTrailingZeros() countLeadingOnes() and countTrailingOnes() return unsigned ClosedPublic Authored by shawnl on Apr 17 2019, 6:51 AM. 
Details Summary This matches APInt's versions of these functions, and there is no need for these to be size_t. (as well as __builtin_clzll()) 
Diff Detail Event Timelineshawnl retitled this revision from [Support] make countLeadingZeros() and countTrailingZeros() return unsigned to [Support] make countLeadingZeros() countTrailingZeros() countLeadingOnes() and countTrailingOnes() return unsigned.Comment Actions bugs This revision is now accepted and ready to land.Apr 19 2019, 9:57 AM shawnl added a child revision: D61151: [SimpligyCFG] NFC, remove GCD that was only used for powers of two.Apr 28 2019, 1:22 AM shawnl mentioned this in D61151: [SimpligyCFG] NFC, remove GCD that was only used for powers of two. 
Revision Contents 
Diff 195564 include/llvm/Support/MathExtras.h
 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||