diff options
Diffstat (limited to 'llvm/lib/MC/MCParser')
| -rw-r--r-- | llvm/lib/MC/MCParser/DarwinAsmParser.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/llvm/lib/MC/MCParser/DarwinAsmParser.cpp b/llvm/lib/MC/MCParser/DarwinAsmParser.cpp index 82741f80128..e6fc1fac81b 100644 --- a/llvm/lib/MC/MCParser/DarwinAsmParser.cpp +++ b/llvm/lib/MC/MCParser/DarwinAsmParser.cpp @@ -888,6 +888,7 @@ bool DarwinAsmParser::parseDirectiveZerofill(StringRef, SMLoc) { Lex(); StringRef Section; + SMLoc SectionLoc = getLexer().getLoc(); if (getParser().parseIdentifier(Section)) return TokError("expected section name after comma in '.zerofill' " "directive"); @@ -896,9 +897,10 @@ bool DarwinAsmParser::parseDirectiveZerofill(StringRef, SMLoc) { // the section but with no symbol. if (getLexer().is(AsmToken::EndOfStatement)) { // Create the zerofill section but no symbol - getStreamer().EmitZerofill(getContext().getMachOSection( - Segment, Section, MachO::S_ZEROFILL, - 0, SectionKind::getBSS())); + getStreamer().EmitZerofill( + getContext().getMachOSection(Segment, Section, MachO::S_ZEROFILL, 0, + SectionKind::getBSS()), + /*Symbol=*/nullptr, /*Size=*/0, /*ByteAlignment=*/0, SectionLoc); return false; } @@ -957,7 +959,7 @@ bool DarwinAsmParser::parseDirectiveZerofill(StringRef, SMLoc) { getStreamer().EmitZerofill(getContext().getMachOSection( Segment, Section, MachO::S_ZEROFILL, 0, SectionKind::getBSS()), - Sym, Size, 1 << Pow2Alignment); + Sym, Size, 1 << Pow2Alignment, SectionLoc); return false; } |

