Undefined value in reg 0 may need a marker to identify end of source range.
authorDevang Patel <dpatel@apple.com>
Mon, 6 Dec 2010 22:48:22 +0000 (22:48 +0000)
committerDevang Patel <dpatel@apple.com>
Mon, 6 Dec 2010 22:48:22 +0000 (22:48 +0000)
This will be used to truncate live range of DBG_VALUE instruction by register allocator and friends.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121061 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/AsmPrinter/DwarfDebug.cpp

index f2c7238f5fa782033f6bd2adfb27a80273a8b954..f43055054e4c3262474b1fab295a706b5f299941 100644 (file)
@@ -2783,16 +2783,14 @@ void DwarfDebug::beginFunction(const MachineFunction *MF) {
         DIVariable DV(MI->getOperand(MI->getNumOperands() - 1).getMetadata());
         if (!DV.Verify()) continue;
         // If DBG_VALUE is for a local variable then it needs a label.
-        if (DV.getTag() != dwarf::DW_TAG_arg_variable
-            && isDbgValueInUndefinedReg(MI) == false)
+        if (DV.getTag() != dwarf::DW_TAG_arg_variable)
           InsnNeedsLabel.insert(MI);
         // DBG_VALUE for inlined functions argument needs a label.
         else if (!DISubprogram(getDISubprogram(DV.getContext())).
                  describes(MF->getFunction()))
           InsnNeedsLabel.insert(MI);
         // DBG_VALUE indicating argument location change needs a label.
-        else if (isDbgValueInUndefinedReg(MI) == false
-                 && !ProcessedArgs.insert(DV))
+        else if (!ProcessedArgs.insert(DV))
           InsnNeedsLabel.insert(MI);
       } else {
         // If location is unknown then instruction needs a location only if