[llvm] r267641 - [MachineInstrBundle] Actually set the PartialDeadDef flag only when the register

Quentin Colombet via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 26 17:16:29 PDT 2016


Author: qcolombet
Date: Tue Apr 26 19:16:29 2016
New Revision: 267641

URL: http://llvm.org/viewvc/llvm-project?rev=267641&view=rev
Log:
[MachineInstrBundle] Actually set the PartialDeadDef flag only when the register
is defined!

The users were checking the proper thing (Defined + PartialDeadDef), but the
information may have been wrong for other use cases, so fix that.

Modified:
    llvm/trunk/lib/CodeGen/MachineInstrBundle.cpp

Modified: llvm/trunk/lib/CodeGen/MachineInstrBundle.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/MachineInstrBundle.cpp?rev=267641&r1=267640&r2=267641&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/MachineInstrBundle.cpp (original)
+++ llvm/trunk/lib/CodeGen/MachineInstrBundle.cpp Tue Apr 26 19:16:29 2016
@@ -335,7 +335,7 @@ MachineOperandIteratorBase::analyzePhysR
   if (AllDefsDead) {
     if (PRI.FullyDefined || PRI.Clobbered)
       PRI.DeadDef = true;
-    else
+    else if (PRI.Defined)
       PRI.PartialDeadDef = true;
   }
 




More information about the llvm-commits mailing list