summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2008-09-24 00:06:15 +0000
committerDevang Patel <dpatel@apple.com>2008-09-24 00:06:15 +0000
commite15607b7bb9ebbf9d0847188f18ee809587f31e2 (patch)
tree22f32e47be4e1434c558cd1fb100190b461dfb35 /llvm/lib/Transforms
parente0add20c1b9e05b4d9ffdfa333d9a4448ff198f0 (diff)
downloadbcm5719-llvm-e15607b7bb9ebbf9d0847188f18ee809587f31e2.tar.gz
bcm5719-llvm-e15607b7bb9ebbf9d0847188f18ee809587f31e2.zip
Put FN_NOTE_AlwaysInline and others in FnAttr namespace.
llvm-svn: 56527
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r--llvm/lib/Transforms/IPO/InlineAlways.cpp2
-rw-r--r--llvm/lib/Transforms/IPO/InlineSimple.cpp2
-rw-r--r--llvm/lib/Transforms/IPO/Inliner.cpp2
-rw-r--r--llvm/lib/Transforms/Scalar/LoopUnswitch.cpp2
-rw-r--r--llvm/lib/Transforms/Utils/InlineCost.cpp2
5 files changed, 5 insertions, 5 deletions
diff --git a/llvm/lib/Transforms/IPO/InlineAlways.cpp b/llvm/lib/Transforms/IPO/InlineAlways.cpp
index ddcc79cf59b..6d95ffd2d52 100644
--- a/llvm/lib/Transforms/IPO/InlineAlways.cpp
+++ b/llvm/lib/Transforms/IPO/InlineAlways.cpp
@@ -63,7 +63,7 @@ bool AlwaysInliner::doInitialization(CallGraph &CG) {
for (Module::iterator I = M.begin(), E = M.end();
I != E; ++I)
- if (!I->isDeclaration() && !I->hasNote(FN_NOTE_AlwaysInline))
+ if (!I->isDeclaration() && !I->hasNote(FnAttr::AlwaysInline))
NeverInline.insert(I);
return false;
diff --git a/llvm/lib/Transforms/IPO/InlineSimple.cpp b/llvm/lib/Transforms/IPO/InlineSimple.cpp
index 42897676418..1cf6c9ec6c5 100644
--- a/llvm/lib/Transforms/IPO/InlineSimple.cpp
+++ b/llvm/lib/Transforms/IPO/InlineSimple.cpp
@@ -65,7 +65,7 @@ bool SimpleInliner::doInitialization(CallGraph &CG) {
for (Module::iterator I = M.begin(), E = M.end();
I != E; ++I)
- if (!I->isDeclaration() && I->hasNote(FN_NOTE_NoInline))
+ if (!I->isDeclaration() && I->hasNote(FnAttr::NoInline))
NeverInline.insert(I);
// Get llvm.noinline
diff --git a/llvm/lib/Transforms/IPO/Inliner.cpp b/llvm/lib/Transforms/IPO/Inliner.cpp
index 7922d6e7a94..57188359956 100644
--- a/llvm/lib/Transforms/IPO/Inliner.cpp
+++ b/llvm/lib/Transforms/IPO/Inliner.cpp
@@ -141,7 +141,7 @@ bool Inliner::runOnSCC(const std::vector<CallGraphNode*> &SCC) {
int CurrentThreshold = InlineThreshold;
Function *Fn = CS.getCaller();
- if (Fn && !Fn->isDeclaration() && Fn->hasNote(FN_NOTE_OptimizeForSize)
+ if (Fn && !Fn->isDeclaration() && Fn->hasNote(FnAttr::OptimizeForSize)
&& InlineThreshold != 50) {
CurrentThreshold = 50;
}
diff --git a/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp b/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp
index 4fd3d031a1a..a6f6bd73a58 100644
--- a/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp
+++ b/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp
@@ -430,7 +430,7 @@ bool LoopUnswitch::UnswitchIfProfitable(Value *LoopCond, Constant *Val){
Function *F = loopHeader->getParent();
// Do not unswitch if the function is optimized for size.
- if (!F->isDeclaration() && F->hasNote(FN_NOTE_OptimizeForSize))
+ if (!F->isDeclaration() && F->hasNote(FnAttr::OptimizeForSize))
return false;
// Check to see if it would be profitable to unswitch current loop.
diff --git a/llvm/lib/Transforms/Utils/InlineCost.cpp b/llvm/lib/Transforms/Utils/InlineCost.cpp
index 6ecd0609912..c35af251b24 100644
--- a/llvm/lib/Transforms/Utils/InlineCost.cpp
+++ b/llvm/lib/Transforms/Utils/InlineCost.cpp
@@ -222,7 +222,7 @@ int InlineCostAnalyzer::getInlineCost(CallSite CS,
if (CalleeFI.NeverInline)
return 2000000000;
- if (!Callee->isDeclaration() && Callee->hasNote(FN_NOTE_AlwaysInline))
+ if (!Callee->isDeclaration() && Callee->hasNote(FnAttr::AlwaysInline))
return -2000000000;
// Add to the inline quality for properties that make the call valuable to
OpenPOWER on IntegriCloud