summaryrefslogtreecommitdiff
path: root/clang/lib/CodeGen/CGExprCXX.cpp
diff options
context:
space:
mode:
authorKazu Hirata <kazu@google.com>2023-01-28 09:06:31 -0800
committerKazu Hirata <kazu@google.com>2023-01-28 09:06:31 -0800
commitf20b5071f3ab69bef389f550d5b93129e135d9f9 (patch)
tree842fd9cb77d8b45744eaae1ae0b001e2fd426d66 /clang/lib/CodeGen/CGExprCXX.cpp
parent75153adeda1a60317a835a1453bcef491d104ff8 (diff)
[llvm] Use llvm::bit_floor instead of llvm::PowerOf2Floor (NFC)
Diffstat (limited to 'clang/lib/CodeGen/CGExprCXX.cpp')
-rw-r--r--clang/lib/CodeGen/CGExprCXX.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGExprCXX.cpp b/clang/lib/CodeGen/CGExprCXX.cpp
index b889a4e05ee1..90beb957be49 100644
--- a/clang/lib/CodeGen/CGExprCXX.cpp
+++ b/clang/lib/CodeGen/CGExprCXX.cpp
@@ -1654,7 +1654,7 @@ llvm::Value *CodeGenFunction::EmitCXXNewExpr(const CXXNewExpr *E) {
CharUnits allocationAlign = allocAlign;
if (!E->passAlignment() &&
allocator->isReplaceableGlobalAllocationFunction()) {
- unsigned AllocatorAlign = llvm::PowerOf2Floor(std::min<uint64_t>(
+ unsigned AllocatorAlign = llvm::bit_floor(std::min<uint64_t>(
Target.getNewAlign(), getContext().getTypeSize(allocType)));
allocationAlign = std::max(
allocationAlign, getContext().toCharUnitsFromBits(AllocatorAlign));