From 75e46c63288747a3a5e991951ffa868e1bb51a38 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sat, 7 Nov 2020 20:18:47 -0800 Subject: [PATCH] [Mem2Reg] Use llvm::count instead of std::count (NFC) --- llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp b/llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp index 36f3787..a59e8ec 100644 --- a/llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp +++ b/llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp @@ -907,7 +907,7 @@ NextIteration: // operands so far. Remember this count. unsigned NewPHINumOperands = APN->getNumOperands(); - unsigned NumEdges = std::count(succ_begin(Pred), succ_end(Pred), BB); + unsigned NumEdges = llvm::count(successors(Pred), BB); assert(NumEdges && "Must be at least one edge from Pred to BB!"); // Add entries for all the phis. -- 2.7.4