Allow target intrinsics that return multiple values, i.e., struct types,
[oota-llvm.git] / lib / CodeGen / SimpleRegisterCoalescing.cpp
index 72ed22b06cf713359e8aec251a510093d3a11d47..2478612d00605f8bbd89b6588fa1cbc5f8905aad 100644 (file)
@@ -619,7 +619,7 @@ bool SimpleRegisterCoalescing::ReMaterializeTrivialDef(LiveInterval &SrcInt,
     // Make sure the copy destination register class fits the instruction
     // definition register class. The mismatch can happen as a result of earlier
     // extract_subreg, insert_subreg, subreg_to_reg coalescing.
-    const TargetRegisterClass *RC = getInstrOperandRegClass(tri_, TID, 0);
+    const TargetRegisterClass *RC = TID.OpInfo[0].getRegClass(tri_);
     if (TargetRegisterInfo::isVirtualRegister(DstReg)) {
       if (mri_->getRegClass(DstReg) != RC)
         return false;
@@ -1308,6 +1308,7 @@ bool SimpleRegisterCoalescing::JoinCopy(CopyRec &TheCopy, bool &Again) {
       DEBUG(errs() << "\tIncompatible source regclass: "
             << tri_->getName(DstSubReg) << " not in " << SrcSubRC->getName()
             << ".\n");
+      (void)DstSubReg;
       return false;             // Not coalescable.
     }
   }