Inspired by D111968, provide a isNegatedPowerOf2() wrapper instead of obfuscating code with (-Value).isPowerOf2() patterns, which I'm sure are likely avenues for typos.....
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
Improved the implementation - we're looking for a shifted mask in the top bits of a non-zero value.
Converted some additional uses of the (-Value).isPowerOf2() pattern