[PATCH] D19861: Pass LiveIntervals to foldMemoryOperandImpl(), to enable checking of liveness of preg (flag reg).

Matthias Braun via llvm-commits llvm-commits at lists.llvm.org
Tue May 3 11:24:12 PDT 2016


MatzeB added a comment.

Looks good in principle, but I am pretty sure you did not even compile this. (Invalid call as below, no target except SystemZ adapted).


================
Comment at: lib/CodeGen/InlineSpiller.cpp:764-765
@@ -763,4 +763,4 @@
   MachineInstr *FoldMI =
                 LoadMI ? TII.foldMemoryOperand(MI, FoldOps, LoadMI)
-                       : TII.foldMemoryOperand(MI, FoldOps, StackSlot);
+                       : TII.foldMemoryOperand(MI, FoldOps, StackSlot, LIS);
   if (!FoldMI)
----------------
huh, does this compile with 3 arguments to the first foldMemoryOperand() call?

================
Comment at: lib/Target/SystemZ/SystemZInstrInfo.cpp:864-865
@@ +863,4 @@
+      // def of CC.
+      LiveRange &CCLiveRange =
+        LIS.getRegUnit(*MCRegUnitIterator(SystemZ::CC, TRI));
+      SlotIndex MISlot = LIS.getSlotIndexes()->getInstructionIndex(*MI);
----------------
You should add an assert here that SystemZ::CC does indeed only have a single register unit.


http://reviews.llvm.org/D19861





More information about the llvm-commits mailing list