need to be MCized, but the last debug info thing are LEB and
cygwin specific (which the MC api doesn't support yet) and
one specific form of EmitReference which I'll tackle next.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98116
91177308-0d34-0410-b5e6-
96231b3b80d8
// Isolate current sections line info.
const std::vector<SrcLineInfo> &LineInfos = SectionSourceLines[j];
// Isolate current sections line info.
const std::vector<SrcLineInfo> &LineInfos = SectionSourceLines[j];
- /*if (Asm->isVerbose()) {
- const MCSection *S = SectionMap[j + 1];
- O << '\t' << MAI->getCommentString() << " Section"
- << S->getName() << '\n';
- }*/
-
// Dwarf assumes we start with first line of first source file.
unsigned Source = 1;
unsigned Line = 1;
// Dwarf assumes we start with first line of first source file.
unsigned Source = 1;
unsigned Line = 1;
if (LineInfo.getLine() == 0) continue;
if (Asm->isVerbose()) {
if (LineInfo.getLine() == 0) continue;
if (Asm->isVerbose()) {
- std::pair<unsigned, unsigned> SourceID =
+ std::pair<unsigned, unsigned> SrcID =
getSourceDirectoryAndFileIds(LineInfo.getSourceID());
getSourceDirectoryAndFileIds(LineInfo.getSourceID());
- O << '\t' << MAI->getCommentString() << ' '
- << getSourceDirectoryName(SourceID.first) << '/'
- << getSourceFileName(SourceID.second)
- << ':' << utostr_32(LineInfo.getLine()) << '\n';
+ Asm->OutStreamer.AddComment(Twine(getSourceDirectoryName(SrcID.first)) +
+ ":" + Twine(LineInfo.getLine()));
}
// Define the line address.
}
// Define the line address.
Asm->OutStreamer.EmitSymbolAttribute(EHFrameInfo.FunctionEHSym,
MCSA_NoDeadStrip);
}
Asm->OutStreamer.EmitSymbolAttribute(EHFrameInfo.FunctionEHSym,
MCSA_NoDeadStrip);
}
+ Asm->OutStreamer.AddBlankLine();
}
/// SharedTypeIds - How many leading type ids two landing pads have in common.
}
/// SharedTypeIds - How many leading type ids two landing pads have in common.
Asm->OutStreamer.AddComment(Desc);
if (MAI->hasLEB128()) {
Asm->OutStreamer.AddComment(Desc);
if (MAI->hasLEB128()) {
O << "\t.sleb128\t" << Value;
Asm->OutStreamer.AddBlankLine();
return;
O << "\t.sleb128\t" << Value;
Asm->OutStreamer.AddBlankLine();
return;
Asm->OutStreamer.AddComment(Desc);
if (MAI->hasLEB128() && PadTo == 0) {
Asm->OutStreamer.AddComment(Desc);
if (MAI->hasLEB128() && PadTo == 0) {
O << "\t.uleb128\t" << Value;
Asm->OutStreamer.AddBlankLine();
return;
O << "\t.uleb128\t" << Value;
Asm->OutStreamer.AddBlankLine();
return;
}
// FIXME: Need an MCExpr for ".".
}
// FIXME: Need an MCExpr for ".".
if (Force32Bit || TD->getPointerSize() == sizeof(int32_t))
O << MAI->getData32bitsDirective();
else
if (Force32Bit || TD->getPointerSize() == sizeof(int32_t))
O << MAI->getData32bitsDirective();
else
// On COFF targets, we have to emit the weird .secrel32 directive.
if (const char *SecOffDir = MAI->getDwarfSectionOffsetDirective())
// On COFF targets, we have to emit the weird .secrel32 directive.
if (const char *SecOffDir = MAI->getDwarfSectionOffsetDirective())
- O << SecOffDir << Label->getName();
+ // FIXME: MCize.
+ Asm->O << SecOffDir << Label->getName();
else {
unsigned Size = IsSmall ? 4 : TD->getPointerSize();
Asm->OutStreamer.EmitSymbolValue(Label, Size, 0/*AddrSpace*/);
else {
unsigned Size = IsSmall ? 4 : TD->getPointerSize();
Asm->OutStreamer.EmitSymbolValue(Label, Size, 0/*AddrSpace*/);