[llvm-commits] CVS: llvm/lib/Target/X86/InstSelectSimple.cpp

Chris Lattner lattner at cs.uiuc.edu
Mon Sep 8 13:56:07 PDT 2003


Changes in directory llvm/lib/Target/X86:

InstSelectSimple.cpp updated: 1.124 -> 1.125

---
Log message:

Add support for the unwind instruction



---
Diffs of the changes:

Index: llvm/lib/Target/X86/InstSelectSimple.cpp
diff -u llvm/lib/Target/X86/InstSelectSimple.cpp:1.124 llvm/lib/Target/X86/InstSelectSimple.cpp:1.125
--- llvm/lib/Target/X86/InstSelectSimple.cpp:1.124	Thu Aug 28 16:23:43 2003
+++ llvm/lib/Target/X86/InstSelectSimple.cpp	Mon Sep  8 13:54:52 2003
@@ -132,6 +132,7 @@
 		const std::vector<ValueRecord> &Args);
     void visitCallInst(CallInst &I);
     void visitInvokeInst(InvokeInst &II);
+    void visitUnwindInst(UnwindInst &UI);
     void visitIntrinsicCall(LLVMIntrinsic::ID ID, CallInst &I);
 
     // Arithmetic operators
@@ -1020,6 +1021,10 @@
     BuildMI(BB, X86::JMP, 1).addPCDisp(II.getNormalDest());
 }
 
+void ISel::visitUnwindInst(UnwindInst &UI) {
+  // unwind is not supported yet!  Just abort when the unwind inst is executed!
+  BuildMI(BB, X86::CALLpcrel32, 1).addExternalSymbol("abort", true); 
+}
 
 void ISel::visitIntrinsicCall(LLVMIntrinsic::ID ID, CallInst &CI) {
   unsigned TmpReg1, TmpReg2;





More information about the llvm-commits mailing list