[llvm] 3c65190 - [Support] Remove deprecated CTLog2 from MathExtras.h (#218274)

via llvm-commits llvm-commits at lists.llvm.org
Sun Aug 23 23:34:34 PDT 2026


Author: Marc Auberer
Date: 2026-08-24T08:34:29+02:00
New Revision: 3c6519006af45003813933136037c376a23a1338

URL: https://github.com/llvm/llvm-project/commit/3c6519006af45003813933136037c376a23a1338
DIFF: https://github.com/llvm/llvm-project/commit/3c6519006af45003813933136037c376a23a1338.diff

LOG: [Support] Remove deprecated CTLog2 from MathExtras.h (#218274)

CTLog2 was deprecated in favor of ConstantLog2 and has no remaining
in-tree users, so drop it.

Co-authored-by: Claude <noreply at anthropic.com>

Added: 
    

Modified: 
    llvm/include/llvm/Support/MathExtras.h

Removed: 
    


################################################################################
diff  --git a/llvm/include/llvm/Support/MathExtras.h b/llvm/include/llvm/Support/MathExtras.h
index d429f63520616..2324565852815 100644
--- a/llvm/include/llvm/Support/MathExtras.h
+++ b/llvm/include/llvm/Support/MathExtras.h
@@ -320,12 +320,6 @@ template <size_t kValue> constexpr size_t ConstantLog2() {
   return llvm::countr_zero_constexpr(kValue);
 }
 
-template <size_t kValue>
-LLVM_DEPRECATED("Use ConstantLog2 instead", "ConstantLog2")
-constexpr size_t CTLog2() {
-  return ConstantLog2<kValue>();
-}
-
 /// Return the floor log base 2 of the specified value, -1 if the value is zero.
 /// (32 bit edition.)
 /// Ex. Log2_32(32) == 5, Log2_32(1) == 0, Log2_32(0) == -1, Log2_32(6) == 2


        


More information about the llvm-commits mailing list