The real fix for post-r284255 failures
authorKrzysztof Parzyszek <kparzysz@codeaurora.org>
Fri, 14 Oct 2016 19:06:25 +0000 (19:06 +0000)
committerKrzysztof Parzyszek <kparzysz@codeaurora.org>
Fri, 14 Oct 2016 19:06:25 +0000 (19:06 +0000)
llvm-svn: 284264

llvm/lib/Target/Hexagon/HexagonRDFOpt.cpp
llvm/lib/Target/Hexagon/RDFGraph.cpp

index 197315335566be61c728ff73b6421080eb9b750e..1e42d648d7e990435fdc541cb1be3b6b6801879d 100644 (file)
@@ -102,7 +102,6 @@ bool HexagonCP::interpretAsCopy(const MachineInstr *MI, EqualityMap &EM) {
   unsigned Opc = MI->getOpcode();
   switch (Opc) {
     case Hexagon::A2_combinew: {
-      break; // FIXME
       const MachineOperand &DstOp = MI->getOperand(0);
       const MachineOperand &HiOp = MI->getOperand(1);
       const MachineOperand &LoOp = MI->getOperand(2);
index 746a55ef9334c859750cff73de62bcd2ba852189..f25fcf72065b3dc94953aeb6aa1a411d0503613d 100644 (file)
@@ -1046,8 +1046,8 @@ void DataFlowGraph::build(unsigned Options) {
 
 RegisterRef DataFlowGraph::makeRegRef(unsigned Reg, unsigned Sub) const {
   assert(TargetRegisterInfo::isPhysicalRegister(Reg));
-  assert(Sub == 0 && "Not expecting subregisters");
-  // TODO handle subregisters just to see if LMI would work with it.
+  if (Sub != 0)
+    Reg = TRI.getSubReg(Reg, Sub);
   return RegisterRef(Reg);
 }