Next round of earlyclobber handling. Approach the
[oota-llvm.git] / lib / CodeGen / SimpleRegisterCoalescing.cpp
index 05e0505f0ba5669c53f9aa7e8fe5e7cb2d4439ec..bdc37b16b6a05a93d5e96e75b47c223cf846bf5a 100644 (file)
@@ -1206,14 +1206,6 @@ bool SimpleRegisterCoalescing::JoinCopy(CopyRec &TheCopy, bool &Again) {
   DOUT << " and "; DstInt.print(DOUT, tri_);
   DOUT << ": ";
 
-  // If one interval is earlyclobber and the other is overlaps-earlyclobber,
-  // we cannot coalesce them.
-  if ((SrcInt.isEarlyClobber && DstInt.overlapsEarlyClobber) ||
-      (DstInt.isEarlyClobber && SrcInt.overlapsEarlyClobber)) {
-    DOUT << "\t\tCannot join due to earlyclobber.";
-    return false;
-  }
-
   // Check if it is necessary to propagate "isDead" property.
   if (!isExtSubReg && !isInsSubReg) {
     MachineOperand *mopd = CopyMI->findRegisterDefOperand(DstReg, false);
@@ -1374,10 +1366,6 @@ bool SimpleRegisterCoalescing::JoinCopy(CopyRec &TheCopy, bool &Again) {
   if (TargetRegisterInfo::isVirtualRegister(DstReg))
     RemoveUnnecessaryKills(DstReg, *ResDstInt);
 
-  // Merge the earlyclobber bits.
-  ResDstInt->isEarlyClobber |= ResSrcInt->isEarlyClobber;
-  ResDstInt->overlapsEarlyClobber |= ResSrcInt->overlapsEarlyClobber;
-
   if (isInsSubReg)
     // Avoid:
     // r1024 = op