From ae0a7bc68303ce0c8721f0e981ae602601390e68 Mon Sep 17 00:00:00 2001 From: Owen Anderson Date: Wed, 13 Oct 2010 22:00:45 +0000 Subject: [PATCH] CallGraphSCC passes implicity require CallGraph analysis. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116443 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/IPO/ArgumentPromotion.cpp | 1 + lib/Transforms/IPO/FunctionAttrs.cpp | 5 ++++- lib/Transforms/IPO/InlineSimple.cpp | 5 ++++- lib/Transforms/IPO/PruneEH.cpp | 5 ++++- lib/Transforms/IPO/StructRetPromotion.cpp | 5 ++++- 5 files changed, 17 insertions(+), 4 deletions(-) diff --git a/lib/Transforms/IPO/ArgumentPromotion.cpp b/lib/Transforms/IPO/ArgumentPromotion.cpp index e1d8833e499..f14c62b136e 100644 --- a/lib/Transforms/IPO/ArgumentPromotion.cpp +++ b/lib/Transforms/IPO/ArgumentPromotion.cpp @@ -87,6 +87,7 @@ char ArgPromotion::ID = 0; INITIALIZE_PASS_BEGIN(ArgPromotion, "argpromotion", "Promote 'by reference' arguments to scalars", false, false) INITIALIZE_AG_DEPENDENCY(AliasAnalysis) +INITIALIZE_AG_DEPENDENCY(CallGraph) INITIALIZE_PASS_END(ArgPromotion, "argpromotion", "Promote 'by reference' arguments to scalars", false, false) diff --git a/lib/Transforms/IPO/FunctionAttrs.cpp b/lib/Transforms/IPO/FunctionAttrs.cpp index 0c0ca84462b..9297356e29d 100644 --- a/lib/Transforms/IPO/FunctionAttrs.cpp +++ b/lib/Transforms/IPO/FunctionAttrs.cpp @@ -69,7 +69,10 @@ namespace { } char FunctionAttrs::ID = 0; -INITIALIZE_PASS(FunctionAttrs, "functionattrs", +INITIALIZE_PASS_BEGIN(FunctionAttrs, "functionattrs", + "Deduce function attributes", false, false) +INITIALIZE_AG_DEPENDENCY(CallGraph) +INITIALIZE_PASS_END(FunctionAttrs, "functionattrs", "Deduce function attributes", false, false) Pass *llvm::createFunctionAttrsPass() { return new FunctionAttrs(); } diff --git a/lib/Transforms/IPO/InlineSimple.cpp b/lib/Transforms/IPO/InlineSimple.cpp index 57682ad130f..4a0d1a8c2fa 100644 --- a/lib/Transforms/IPO/InlineSimple.cpp +++ b/lib/Transforms/IPO/InlineSimple.cpp @@ -56,7 +56,10 @@ namespace { } char SimpleInliner::ID = 0; -INITIALIZE_PASS(SimpleInliner, "inline", +INITIALIZE_PASS_BEGIN(SimpleInliner, "inline", + "Function Integration/Inlining", false, false) +INITIALIZE_AG_DEPENDENCY(CallGraph) +INITIALIZE_PASS_END(SimpleInliner, "inline", "Function Integration/Inlining", false, false) Pass *llvm::createFunctionInliningPass() { return new SimpleInliner(); } diff --git a/lib/Transforms/IPO/PruneEH.cpp b/lib/Transforms/IPO/PruneEH.cpp index e71344b2158..9be0fcf2a92 100644 --- a/lib/Transforms/IPO/PruneEH.cpp +++ b/lib/Transforms/IPO/PruneEH.cpp @@ -48,7 +48,10 @@ namespace { } char PruneEH::ID = 0; -INITIALIZE_PASS(PruneEH, "prune-eh", +INITIALIZE_PASS_BEGIN(PruneEH, "prune-eh", + "Remove unused exception handling info", false, false) +INITIALIZE_AG_DEPENDENCY(CallGraph) +INITIALIZE_PASS_END(PruneEH, "prune-eh", "Remove unused exception handling info", false, false) Pass *llvm::createPruneEHPass() { return new PruneEH(); } diff --git a/lib/Transforms/IPO/StructRetPromotion.cpp b/lib/Transforms/IPO/StructRetPromotion.cpp index f3565f6b769..8cbefc855d9 100644 --- a/lib/Transforms/IPO/StructRetPromotion.cpp +++ b/lib/Transforms/IPO/StructRetPromotion.cpp @@ -61,7 +61,10 @@ namespace { } char SRETPromotion::ID = 0; -INITIALIZE_PASS(SRETPromotion, "sretpromotion", +INITIALIZE_PASS_BEGIN(SRETPromotion, "sretpromotion", + "Promote sret arguments to multiple ret values", false, false) +INITIALIZE_AG_DEPENDENCY(CallGraph) +INITIALIZE_PASS_END(SRETPromotion, "sretpromotion", "Promote sret arguments to multiple ret values", false, false) Pass *llvm::createStructRetPromotionPass() { -- 2.34.1