Remove the isTwoAddress property from the CodeGenInstruction class.  It should
not be used for anything other than backwards compat constraint handling.

Add support for a new DisableEncoding property which contains a list of
registers that should not be encoded by the generated code emitter.  Convert
the codeemitter generator to use this, fixing some PPC JIT regressions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31769 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/utils/TableGen/AsmWriterEmitter.cpp b/utils/TableGen/AsmWriterEmitter.cpp
index 6466b5f..c8af097 100644
--- a/utils/TableGen/AsmWriterEmitter.cpp
+++ b/utils/TableGen/AsmWriterEmitter.cpp
@@ -220,16 +220,11 @@
         unsigned OpNo = CGI.getOperandNamed(VarName);
         CodeGenInstruction::OperandInfo OpInfo = CGI.OperandList[OpNo];
 
-        // If this is a two-address instruction, verify the second operand isn't
-        // used.
-        unsigned MIOp = OpInfo.MIOperandNo;
-        if (CGI.isTwoAddress && MIOp == 1)
-          throw "Should refer to operand #0 instead of #1 for two-address"
-                " instruction '" + CGI.TheDef->getName() + "'!";
-        
-        if (CurVariant == Variant || CurVariant == ~0U) 
+        if (CurVariant == Variant || CurVariant == ~0U) {
+          unsigned MIOp = OpInfo.MIOperandNo;
           Operands.push_back(AsmWriterOperand(OpInfo.PrinterMethodName, MIOp,
                                               Modifier));
+        }
       }
       LastEmitted = VarEnd;
     }