[llvm-commits] [llvm] r47933 - /llvm/trunk/lib/Target/X86/X86CodeEmitter.cpp
Evan Cheng
evan.cheng at apple.com
Tue Mar 4 18:08:04 PST 2008
Author: evancheng
Date: Tue Mar 4 20:08:03 2008
New Revision: 47933
URL: http://llvm.org/viewvc/llvm-project?rev=47933&view=rev
Log:
Rather than asserting. Dump out the MI that we are not able to encode and abort.
Modified:
llvm/trunk/lib/Target/X86/X86CodeEmitter.cpp
Modified: llvm/trunk/lib/Target/X86/X86CodeEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86CodeEmitter.cpp?rev=47933&r1=47932&r2=47933&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86CodeEmitter.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86CodeEmitter.cpp Tue Mar 4 20:08:03 2008
@@ -807,5 +807,10 @@
break;
}
- assert((Desc->isVariadic() || CurOp == NumOps) && "Unknown encoding!");
+ if (!Desc->isVariadic() && CurOp != NumOps) {
+ cerr << "Cannot encode: ";
+ MI.dump();
+ cerr << '\n';
+ abort();
+ }
}
More information about the llvm-commits
mailing list