[llvm] 7629493 - [Scalar] Remove CallSiteSplittingLegacyPass
Kazu Hirata via llvm-commits
llvm-commits at lists.llvm.org
Sat Jun 10 15:20:48 PDT 2023
Author: Kazu Hirata
Date: 2023-06-10T15:20:40-07:00
New Revision: 76294935d3164176b25d14d2cfc777567c0153c2
URL: https://github.com/llvm/llvm-project/commit/76294935d3164176b25d14d2cfc777567c0153c2
DIFF: https://github.com/llvm/llvm-project/commit/76294935d3164176b25d14d2cfc777567c0153c2.diff
LOG: [Scalar] Remove CallSiteSplittingLegacyPass
The last use was removed by:
commit fd48d0a0adaa5fcdd24d02a58ba8a6210adafc28
Author: Kazu Hirata <kazu at google.com>
Date: Sat Jun 10 13:51:37 2023 -0700
Differential Revision: https://reviews.llvm.org/D152635
Added:
Modified:
llvm/include/llvm/InitializePasses.h
llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp
llvm/lib/Transforms/Scalar/Scalar.cpp
Removed:
################################################################################
diff --git a/llvm/include/llvm/InitializePasses.h b/llvm/include/llvm/InitializePasses.h
index a65bd4ef025b9..51953cdccea01 100644
--- a/llvm/include/llvm/InitializePasses.h
+++ b/llvm/include/llvm/InitializePasses.h
@@ -83,7 +83,6 @@ void initializeCallGraphDOTPrinterPass(PassRegistry&);
void initializeCallGraphPrinterLegacyPassPass(PassRegistry&);
void initializeCallGraphViewerPass(PassRegistry&);
void initializeCallGraphWrapperPassPass(PassRegistry&);
-void initializeCallSiteSplittingLegacyPassPass(PassRegistry&);
void initializeCheckDebugMachineModulePass(PassRegistry &);
void initializeCodeGenPreparePass(PassRegistry&);
void initializeComplexDeinterleavingLegacyPassPass(PassRegistry&);
diff --git a/llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp b/llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp
index 5f9528613e993..aeb7c5d461f08 100644
--- a/llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp
+++ b/llvm/lib/Transforms/Scalar/CallSiteSplitting.cpp
@@ -535,42 +535,6 @@ static bool doCallSiteSplitting(Function &F, TargetLibraryInfo &TLI,
return Changed;
}
-namespace {
-struct CallSiteSplittingLegacyPass : public FunctionPass {
- static char ID;
- CallSiteSplittingLegacyPass() : FunctionPass(ID) {
- initializeCallSiteSplittingLegacyPassPass(*PassRegistry::getPassRegistry());
- }
-
- void getAnalysisUsage(AnalysisUsage &AU) const override {
- AU.addRequired<TargetLibraryInfoWrapperPass>();
- AU.addRequired<TargetTransformInfoWrapperPass>();
- AU.addRequired<DominatorTreeWrapperPass>();
- AU.addPreserved<DominatorTreeWrapperPass>();
- FunctionPass::getAnalysisUsage(AU);
- }
-
- bool runOnFunction(Function &F) override {
- if (skipFunction(F))
- return false;
-
- auto &TLI = getAnalysis<TargetLibraryInfoWrapperPass>().getTLI(F);
- auto &TTI = getAnalysis<TargetTransformInfoWrapperPass>().getTTI(F);
- auto &DT = getAnalysis<DominatorTreeWrapperPass>().getDomTree();
- return doCallSiteSplitting(F, TLI, TTI, DT);
- }
-};
-} // namespace
-
-char CallSiteSplittingLegacyPass::ID = 0;
-INITIALIZE_PASS_BEGIN(CallSiteSplittingLegacyPass, "callsite-splitting",
- "Call-site splitting", false, false)
-INITIALIZE_PASS_DEPENDENCY(TargetLibraryInfoWrapperPass)
-INITIALIZE_PASS_DEPENDENCY(TargetTransformInfoWrapperPass)
-INITIALIZE_PASS_DEPENDENCY(DominatorTreeWrapperPass)
-INITIALIZE_PASS_END(CallSiteSplittingLegacyPass, "callsite-splitting",
- "Call-site splitting", false, false)
-
PreservedAnalyses CallSiteSplittingPass::run(Function &F,
FunctionAnalysisManager &AM) {
auto &TLI = AM.getResult<TargetLibraryAnalysis>(F);
diff --git a/llvm/lib/Transforms/Scalar/Scalar.cpp b/llvm/lib/Transforms/Scalar/Scalar.cpp
index fc717e48188b9..1125f6a450d2c 100644
--- a/llvm/lib/Transforms/Scalar/Scalar.cpp
+++ b/llvm/lib/Transforms/Scalar/Scalar.cpp
@@ -19,7 +19,6 @@ using namespace llvm;
/// initializeScalarOptsPasses - Initialize all passes linked into the
/// ScalarOpts library.
void llvm::initializeScalarOpts(PassRegistry &Registry) {
- initializeCallSiteSplittingLegacyPassPass(Registry);
initializeConstantHoistingLegacyPassPass(Registry);
initializeDCELegacyPassPass(Registry);
initializeScalarizerLegacyPassPass(Registry);
More information about the llvm-commits
mailing list