diff options
-rw-r--r-- | utils/TableGen/CodeEmitterGen.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/utils/TableGen/CodeEmitterGen.cpp b/utils/TableGen/CodeEmitterGen.cpp index f0a02872ce..3dcaea4300 100644 --- a/utils/TableGen/CodeEmitterGen.cpp +++ b/utils/TableGen/CodeEmitterGen.cpp @@ -161,6 +161,11 @@ void CodeEmitterGen::run(std::ostream &o) { + utostr(op++) + "));\n"; gotOp = true; + + // If this is a two-address instruction and we just got the dest + // op, skip the src op. + if (op == 1 && Target.getInstruction(InstName).isTwoAddress) + ++op; } unsigned opMask = (1 << N) - 1; |