Lines Matching refs:Asm
109 static uint64_t symbolValue(const MCAssembler &Asm, const MCSymbol &Sym);
110 static bool isInSymtab(const MCAssembler &Asm, const MCSymbolELF &Symbol,
167 void writeHeader(const MCAssembler &Asm);
169 void writeSymbol(const MCAssembler &Asm, SymbolTableWriter &Writer,
179 void computeSymbolTable(MCAssembler &Asm, const RevGroupMapTy &RevGroupMap);
186 void writeSectionHeader(const MCAssembler &Asm);
188 void writeSectionData(const MCAssembler &Asm, MCSection &Sec);
195 void writeRelocations(const MCAssembler &Asm, const MCSectionELF &Sec);
197 uint64_t writeObject(MCAssembler &Asm);
271 void ELFWriter::writeHeader(const MCAssembler &Asm) { in writeHeader() argument
332 uint64_t ELFWriter::symbolValue(const MCAssembler &Asm, const MCSymbol &Sym) { in symbolValue() argument
337 if (!Asm.getSymbolOffset(Sym, Res)) in symbolValue()
340 if (Asm.isThumbFunc(&Sym)) in symbolValue()
394 void ELFWriter::writeSymbol(const MCAssembler &Asm, SymbolTableWriter &Writer, in writeSymbol() argument
398 cast_or_null<MCSymbolELF>(Asm.getBaseSymbol(Symbol)); in writeSymbol()
419 uint64_t Value = symbolValue(Asm, *MSD.Symbol); in writeSymbol()
446 if (!ESize->evaluateKnownAbsolute(Res, Asm)) in writeSymbol()
456 bool ELFWriter::isInSymtab(const MCAssembler &Asm, const MCSymbolELF &Symbol, in isInSymtab() argument
478 Asm.getBaseSymbol(Symbol); in isInSymtab()
491 void ELFWriter::computeSymbolTable(MCAssembler &Asm, in computeSymbolTable() argument
493 MCContext &Ctx = Asm.getContext(); in computeSymbolTable()
517 for (auto It : llvm::enumerate(Asm.symbols())) { in computeSymbolTable()
523 if (!isInSymtab(Asm, Symbol, Used || WeakrefUsed || isSignature, in computeSymbolTable()
633 writeSymbol(Asm, Writer, StringIndex, MSD); in computeSymbolTable()
648 writeSymbol(Asm, Writer, StringIndex, MSD); in computeSymbolTable()
733 void ELFWriter::writeSectionData(const MCAssembler &Asm, MCSection &Sec) { in writeSectionData() argument
736 auto &Ctx = Asm.getContext(); in writeSectionData()
742 Asm.writeSectionData(W.OS, &Section); in writeSectionData()
748 Asm.writeSectionData(VecOS, &Section); in writeSectionData()
806 void ELFWriter::writeRelocations(const MCAssembler &Asm, in writeRelocations() argument
809 const MCTargetOptions *TO = Asm.getContext().getTargetOptions(); in writeRelocations()
813 OWriter.TargetObjectWriter->sortRelocs(Asm, Relocs); in writeRelocations()
931 void ELFWriter::writeSectionHeader(const MCAssembler &Asm) { in writeSectionHeader() argument
950 Size = Asm.getSectionAddressSize(*Section); in writeSectionHeader()
958 uint64_t ELFWriter::writeObject(MCAssembler &Asm) { in writeObject() argument
961 MCContext &Ctx = Asm.getContext(); in writeObject()
969 writeHeader(Asm); in writeObject()
976 for (MCSection &Sec : Asm) { in writeObject()
987 writeSectionData(Asm, Section); in writeObject()
1049 computeSymbolTable(Asm, RevGroupMap); in writeObject()
1055 writeRelocations(Asm, in writeObject()
1079 writeSectionHeader(Asm); in writeObject()
1131 void ELFObjectWriter::executePostLayoutBinding(MCAssembler &Asm) { in executePostLayoutBinding() argument
1147 cast<MCSymbolELF>(Asm.getContext().getOrCreateSymbol(Prefix + Tail)); in executePostLayoutBinding()
1148 Asm.registerSymbol(*Alias); in executePostLayoutBinding()
1149 const MCExpr *Value = MCSymbolRefExpr::create(&Symbol, Asm.getContext()); in executePostLayoutBinding()
1163 Asm.getContext().reportError(S.Loc, "default version symbol " + in executePostLayoutBinding()
1169 Asm.getContext().reportError(S.Loc, Twine("multiple versions for ") + in executePostLayoutBinding()
1189 bool ELFObjectWriter::shouldRelocateWithSymbol(const MCAssembler &Asm, in shouldRelocateWithSymbol() argument
1310 if (Asm.isThumbFunc(Sym)) in shouldRelocateWithSymbol()
1334 void ELFObjectWriter::recordRelocation(MCAssembler &Asm, in recordRelocation() argument
1338 MCAsmBackend &Backend = Asm.getBackend(); in recordRelocation()
1343 uint64_t FixupOffset = Asm.getFragmentOffset(*Fragment) + Fixup.getOffset(); in recordRelocation()
1344 MCContext &Ctx = Asm.getContext(); in recordRelocation()
1366 C += FixupOffset - Asm.getSymbolOffset(SymB); in recordRelocation()
1394 shouldRelocateWithSymbol(Asm, Target, SymA, C, Type) || in recordRelocation()
1399 ? C + Asm.getSymbolOffset(*SymA) in recordRelocation()
1438 const MCAssembler &Asm, const MCSymbol &SA, const MCFragment &FB, in isSymbolRefDifferenceFullyResolvedImpl() argument
1450 uint64_t ELFObjectWriter::writeObject(MCAssembler &Asm) { in writeObject() argument
1454 .writeObject(Asm); in writeObject()
1457 .writeObject(Asm); in writeObject()