[llvm-branch-commits] [llvm-branch] r82475 - in /llvm/branches/Apple/Bender-SWB/lib: CodeGen/AsmPrinter/DwarfWriter.cpp CodeGen/MachineModuleInfo.cpp Transforms/Utils/InlineFunction.cpp

Bill Wendling isanbard at gmail.com
Mon Sep 21 13:12:17 PDT 2009


Author: void
Date: Mon Sep 21 15:12:16 2009
New Revision: 82475

URL: http://llvm.org/viewvc/llvm-project?rev=82475&view=rev
Log:
Revert EH candidate patch.

Modified:
    llvm/branches/Apple/Bender-SWB/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
    llvm/branches/Apple/Bender-SWB/lib/CodeGen/MachineModuleInfo.cpp
    llvm/branches/Apple/Bender-SWB/lib/Transforms/Utils/InlineFunction.cpp

Modified: llvm/branches/Apple/Bender-SWB/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Bender-SWB/lib/CodeGen/AsmPrinter/DwarfWriter.cpp?rev=82475&r1=82474&r2=82475&view=diff

==============================================================================
--- llvm/branches/Apple/Bender-SWB/lib/CodeGen/AsmPrinter/DwarfWriter.cpp (original)
+++ llvm/branches/Apple/Bender-SWB/lib/CodeGen/AsmPrinter/DwarfWriter.cpp Mon Sep 21 15:12:16 2009
@@ -3977,7 +3977,7 @@
 
       // If there is a personality and landing pads then point to the language
       // specific data area in the exception table.
-      if (MMI->getPersonalities()[0] != NULL) {
+      if (EHFrameInfo.PersonalityIndex) {
         Asm->EmitULEB128Bytes(4);
         Asm->EOL("Augmentation size");
 

Modified: llvm/branches/Apple/Bender-SWB/lib/CodeGen/MachineModuleInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Bender-SWB/lib/CodeGen/MachineModuleInfo.cpp?rev=82475&r1=82474&r2=82475&view=diff

==============================================================================
--- llvm/branches/Apple/Bender-SWB/lib/CodeGen/MachineModuleInfo.cpp (original)
+++ llvm/branches/Apple/Bender-SWB/lib/CodeGen/MachineModuleInfo.cpp Mon Sep 21 15:12:16 2009
@@ -44,7 +44,7 @@
 , CallsUnwindInit(0)
 , DbgInfoAvailable(false)
 {
-  // Always emit some info, by default "no personality" info.
+  // Always emit "no personality" info
   Personalities.push_back(NULL);
 }
 MachineModuleInfo::~MachineModuleInfo() {
@@ -149,12 +149,7 @@
     if (Personalities[i] == Personality)
       return;
   
-  // If this is the first personality we're adding go ahead and add it at the
-  // beginning.
-  if (Personalities[0] == NULL)
-    Personalities[0] = Personality;
-  else
-    Personalities.push_back(Personality);
+  Personalities.push_back(Personality);
 }
 
 /// addCatchTypeInfo - Provide the catch typeinfo for a landing pad.
@@ -278,7 +273,7 @@
 }
 
 /// getPersonalityIndex - Return unique index for current personality
-/// function. NULL/first personality function should always get zero index.
+/// function. NULL personality function should always get zero index.
 unsigned MachineModuleInfo::getPersonalityIndex() const {
   const Function* Personality = NULL;
   
@@ -294,7 +289,8 @@
       return i;
   }
 
-  // This will happen if the current personality function is in the zero index.
+  // This should never happen
+  assert(0 && "Personality function should be set!");
   return 0;
 }
 

Modified: llvm/branches/Apple/Bender-SWB/lib/Transforms/Utils/InlineFunction.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Bender-SWB/lib/Transforms/Utils/InlineFunction.cpp?rev=82475&r1=82474&r2=82475&view=diff

==============================================================================
--- llvm/branches/Apple/Bender-SWB/lib/Transforms/Utils/InlineFunction.cpp (original)
+++ llvm/branches/Apple/Bender-SWB/lib/Transforms/Utils/InlineFunction.cpp Mon Sep 21 15:12:16 2009
@@ -270,12 +270,6 @@
       return false;
   }
 
-  // FIXME: When we get inlining across invokes and eh information
-  // better coordinated, turn this back on.
-  if (isa<InvokeInst>(TheCall) && !MarkNoUnwind
-      && !CalledFunc->hasFnAttr(Attribute::AlwaysInline))
-    return false;
-
   // Get an iterator to the last basic block in the function, which will have
   // the new function inlined after it.
   //





More information about the llvm-branch-commits mailing list