From 9eb525d4f9f12f266e18bf659c876bda59738807 Mon Sep 17 00:00:00 2001 From: Devang Patel Date: Fri, 26 Sep 2008 23:51:19 +0000 Subject: Implement function notes as function attributes. llvm-svn: 56716 --- llvm/lib/Transforms/Scalar/LoopUnswitch.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/lib/Transforms/Scalar/LoopUnswitch.cpp') diff --git a/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp b/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp index 15eaa786bea..fbfe2977278 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(Attribute::OptimizeForSize)) + if (!F->isDeclaration() && F->hasFnAttr(Attribute::OptimizeForSize)) return false; // Check to see if it would be profitable to unswitch current loop. -- cgit v1.2.3