function. Emitting another label after the prologue messes up the debugging. We
are doing that because the first DebugLoc object it sees is different from the
previous, which was nothing. Check for this situation, and don't emit one if
it's the first.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@65180
91177308-0d34-0410-b5e6-
96231b3b80d8
<< " if (!CurDL.isUnknown()) {\n"
<< " static DebugLocTuple PrevDLT(~0U, ~0U, ~0U);\n"
<< " DebugLocTuple CurDLT = MF->getDebugLocTuple(CurDL);\n\n"
- << " if (PrevDLT != CurDLT) {\n"
+ << " if (PrevDLT.Src != ~0U && PrevDLT != CurDLT)\n"
<< " printLabel(DW->RecordSourceLine(CurDLT.Line, CurDLT.Col,\n"
- << " CurDLT.Src));\n"
- << " PrevDLT = CurDLT;\n"
- << " }\n"
+ << " CurDLT.Src));\n\n"
+ << " PrevDLT = CurDLT;\n"
<< " }\n"
<< " }\n\n";