[PATCH] D17032: [X86] Add a pass to change byte and word instructions to zero-extending versions.

Kevin B. Smith via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 11 09:38:42 PST 2016


kbsmith1 marked 13 inline comments as done.
kbsmith1 added a comment.

Addressed inline comments.


================
Comment at: lib/Target/X86/X86FixupBWInsts.cpp:198
@@ +197,3 @@
+
+  return true;
+}
----------------
I think the loop in lines 217-219 already gets all the implicit ops.  I looked at the code for copyImplicitOps, which looks like this:
for (unsigned i = MI->getDesc().getNumOperands(), e = MI->getNumOperands();
     i != e; ++i) {
  const MachineOperand &MO = MI->getOperand(i);
  if ((MO.isReg() && MO.isImplicit()) || MO.isRegMask())
    addOperand(MF, MO);
}
Loop in 217-219 also ends at MI->getNumOoperands(), and is copying every single operand, so I think that loop is already getting all the implicit operands as well. Let me know if you don't think that is true.


http://reviews.llvm.org/D17032





More information about the llvm-commits mailing list