assert(0 && "Unexpected scope info");
unsigned Src = GetOrCreateSourceID(Dir, Fn);
- unsigned ID = MMI->NextLabelID();
- Lines.push_back(SrcLineInfo(Line, Col, Src, ID));
+ MCSymbol *Label = getDWLabel("label", MMI->NextLabelID());
+ Lines.push_back(SrcLineInfo(Line, Col, Src, Label));
if (TimePassesIsEnabled)
DebugTimer->stopTimer();
- MCSymbol *Label = getDWLabel("label", ID);
Asm->OutStreamer.EmitLabel(Label);
return Label;
}
// Construct rows of the address, source, line, column matrix.
for (unsigned i = 0, N = LineInfos.size(); i < N; ++i) {
const SrcLineInfo &LineInfo = LineInfos[i];
- unsigned LabelID = LineInfo.getLabelID();
- MCSymbol *Label = getDWLabel("label", LabelID);
+ MCSymbol *Label = LineInfo.getLabel();
if (!Label->isDefined()) continue; // Not emitted, in dead code.
if (LineInfo.getLine() == 0) continue;
unsigned Line; // Source line number.
unsigned Column; // Source column.
unsigned SourceID; // Source ID number.
- unsigned LabelID; // Label in code ID number.
+ MCSymbol *Label; // Label in code ID number.
public:
- SrcLineInfo(unsigned L, unsigned C, unsigned S, unsigned I)
- : Line(L), Column(C), SourceID(S), LabelID(I) {}
+ SrcLineInfo(unsigned L, unsigned C, unsigned S, MCSymbol *label)
+ : Line(L), Column(C), SourceID(S), Label(label) {}
// Accessors
unsigned getLine() const { return Line; }
unsigned getColumn() const { return Column; }
unsigned getSourceID() const { return SourceID; }
- unsigned getLabelID() const { return LabelID; }
+ MCSymbol *getLabel() const { return Label; }
};
class DwarfDebug : public DwarfPrinter {