[llvm-commits] [llvm] r127952 - /llvm/trunk/lib/CodeGen/Analysis.cpp

Evan Cheng evan.cheng at apple.com
Sat Mar 19 10:03:16 PDT 2011


Author: evancheng
Date: Sat Mar 19 12:03:16 2011
New Revision: 127952

URL: http://llvm.org/viewvc/llvm-project?rev=127952&view=rev
Log:
Minor code re-structuring.

Modified:
    llvm/trunk/lib/CodeGen/Analysis.cpp

Modified: llvm/trunk/lib/CodeGen/Analysis.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/Analysis.cpp?rev=127952&r1=127951&r2=127952&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/Analysis.cpp (original)
+++ llvm/trunk/lib/CodeGen/Analysis.cpp Sat Mar 19 12:03:16 2011
@@ -211,7 +211,6 @@
   const BasicBlock *ExitBB = I->getParent();
   const TerminatorInst *Term = ExitBB->getTerminator();
   const ReturnInst *Ret = dyn_cast<ReturnInst>(Term);
-  const Function *F = ExitBB->getParent();
 
   // The block must end in a return statement or unreachable.
   //
@@ -250,6 +249,7 @@
 
   // Conservatively require the attributes of the call to match those of
   // the return. Ignore noalias because it doesn't affect the call sequence.
+  const Function *F = ExitBB->getParent();
   unsigned CallerRetAttr = F->getAttributes().getRetAttributes();
   if ((CalleeRetAttr ^ CallerRetAttr) & ~Attribute::NoAlias)
     return false;





More information about the llvm-commits mailing list