Fix PR5087, patch by Jakub Staszak!
authorChris Lattner <sabre@nondot.org>
Mon, 12 Oct 2009 04:22:44 +0000 (04:22 +0000)
committerChris Lattner <sabre@nondot.org>
Mon, 12 Oct 2009 04:22:44 +0000 (04:22 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83822 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/MachineFunctionAnalysis.cpp
lib/Target/X86/X86CodeEmitter.cpp

index ae9d5a99c04df9af24801c3857b68a42f819af8f..56294d90398f7fe869283555a361f5d912f7774e 100644 (file)
@@ -30,6 +30,7 @@ MachineFunctionAnalysis::MachineFunctionAnalysis(TargetMachine &tm,
 }
 
 MachineFunctionAnalysis::~MachineFunctionAnalysis() {
+  releaseMemory();
   assert(!MF && "MachineFunctionAnalysis left initialized!");
 }
 
index 6527dd70d925ce700f866f883b02276caee63fc6..f942f3f85107070e8f429a35b14e29885e83e1cd 100644 (file)
@@ -587,8 +587,8 @@ void Emitter<CodeEmitter>::emitInstruction(const MachineInstr &MI,
     case TargetInstrInfo::INLINEASM:
       // We allow inline assembler nodes with empty bodies - they can
       // implicitly define registers, which is ok for JIT.
-      assert(MI.getOperand(0).getSymbolName()[0] == 0 && 
-             "JIT does not support inline asm!");
+      if (MI.getOperand(0).getSymbolName()[0])
+        llvm_report_error("JIT does not support inline asm!");
       break;
     case TargetInstrInfo::DBG_LABEL:
     case TargetInstrInfo::EH_LABEL: