[llvm] MathExtras: rewrite some methods to never overflow (PR #95556)
Ramkumar Ramachandra via llvm-commits
llvm-commits at lists.llvm.org
Sat Jun 15 01:26:02 PDT 2024
================
@@ -385,6 +385,8 @@ inline uint64_t PowerOf2Ceil(uint64_t A) {
/// alignTo(~0LL, 8) = 0
/// alignTo(321, 255) = 510
/// \endcode
+///
+/// May overflow.
----------------
artagnon wrote:
Is it okay if I tackle this problem in the next patch (see #95426), since the numbers I need to test with in the current implementation are going to be very big and ugly?
https://github.com/llvm/llvm-project/pull/95556
More information about the llvm-commits
mailing list