[llvm] f827ee6 - [Scalar][NFC] Minor cleanups in CallSiteSplitting.cpp
Alexander Shaposhnikov via llvm-commits
llvm-commits at lists.llvm.org
Fri May 6 16:04:59 PDT 2022
Author: Alexander Shaposhnikov
Date: 2022-05-06T23:03:49Z
New Revision: f827ee671f5440a7514d071abbfec0556119a34f
URL: https://github.com/llvm/llvm-project/commit/f827ee671f5440a7514d071abbfec0556119a34f
DIFF: https://github.com/llvm/llvm-project/commit/f827ee671f5440a7514d071abbfec0556119a34f.diff
LOG: [Scalar][NFC] Minor cleanups in CallSiteSplitting.cpp
Added:
Modified:
llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp b/llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp
index b6b087a39bbc..cc12033fb677 100644
--- a/llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp
+++ b/llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp
@@ -123,8 +123,8 @@ static bool isCondRelevantToAnyCallArgument(ICmpInst *Cmp, CallBase &CB) {
return false;
}
-typedef std::pair<ICmpInst *, unsigned> ConditionTy;
-typedef SmallVector<ConditionTy, 2> ConditionsTy;
+using ConditionTy = std::pair<ICmpInst *, unsigned>;
+using ConditionsTy = SmallVector<ConditionTy, 2>;
/// If From has a conditional jump to To, add the condition to Conditions,
/// if it is relevant to any argument at CB.
@@ -301,10 +301,9 @@ static void copyMustTailReturn(BasicBlock *SplitBB, Instruction *CI,
/// Note that in case any arguments at the call-site are constrained by its
/// predecessors, new call-sites with more constrained arguments will be
/// created in createCallSitesOnPredicatedArgument().
-static void splitCallSite(
- CallBase &CB,
- const SmallVectorImpl<std::pair<BasicBlock *, ConditionsTy>> &Preds,
- DomTreeUpdater &DTU) {
+static void splitCallSite(CallBase &CB,
+ ArrayRef<std::pair<BasicBlock *, ConditionsTy>> Preds,
+ DomTreeUpdater &DTU) {
BasicBlock *TailBB = CB.getParent();
bool IsMustTailCall = CB.isMustTailCall();
More information about the llvm-commits
mailing list