Lines Matching refs:BC
120 BinaryContext &BC; member in __anon00ef77ed0111::BinaryEmitter
123 BinaryEmitter(MCStreamer &Streamer, BinaryContext &BC) in BinaryEmitter() argument
124 : Streamer(Streamer), BC(BC) {} in BinaryEmitter()
187 Streamer.initSections(false, *BC.STI); in emitAll()
189 if (opts::UpdateDebugSections && BC.isELF()) { in emitAll()
196 static_cast<MCSectionELF *>(BC.MOFI->getDwarfLineSection()); in emitAll()
200 if (RuntimeLibrary *RtLibrary = BC.getRuntimeLibrary()) in emitAll()
201 RtLibrary->emitBinary(BC, Streamer); in emitAll()
203 BC.getTextSection()->setAlignment(Align(opts::AlignText)); in emitAll()
209 DwarfLineTable::emit(BC, Streamer); in emitAll()
214 Streamer.emitLabel(BC.Ctx->getOrCreateSymbol("_end")); in emitAll()
219 const bool HasProfile = BC.NumProfiledFuncs > 0; in emitFunctions()
222 if (!BC.shouldEmit(*Function)) in emitFunctions()
252 Streamer.switchSection(BC.getTextSection()); in emitFunctions()
253 Streamer.emitLabel(BC.getHotTextStartSymbol()); in emitFunctions()
257 std::vector<BinaryFunction *> SortedFunctions = BC.getSortedFunctions(); in emitFunctions()
261 emit(BC.getInjectedBinaryFunctions()); in emitFunctions()
265 Streamer.switchSection(BC.getTextSection()); in emitFunctions()
266 Streamer.emitLabel(BC.getHotTextEndSymbol()); in emitFunctions()
278 BC.getCodeSection(EmitColdPart ? Function.getColdCodeSectionName() in emitFunction()
282 BC.Ctx->addGenDwarfSection(Section); in emitFunction()
284 if (BC.HasRelocations) { in emitFunction()
291 Streamer.emitCodeAlignment(BinaryFunction::MinAlign, &*BC.STI); in emitFunction()
295 Streamer.emitCodeAlignment(Function.getAlignment(), &*BC.STI, in emitFunction()
298 Streamer.emitCodeAlignment(Function.getAlignment(), &*BC.STI); in emitFunction()
328 Streamer.emitCFILsda(LSDASymbol, BC.LSDAEncoding); in emitFunction()
365 Streamer.emitIntValue(BC.MIB->getTrapFillValue(), 1); in emitFunction()
407 Streamer.emitCodeAlignment(BB->getAlignment(), &*BC.STI, in emitFunctionBody()
432 if (EmitCodeOnly && BC.MIB->isPseudo(Instr)) in emitFunctionBody()
436 if (BC.MIB->isEHLabel(Instr)) { in emitFunctionBody()
437 const MCSymbol *Label = BC.MIB->getTargetSymbol(Instr); in emitFunctionBody()
443 if (BC.MIB->isCFI(Instr)) { in emitFunctionBody()
466 BC.MIB->getOffset(Instr)) { in emitFunctionBody()
467 const uint32_t Offset = *BC.MIB->getOffset(Instr); in emitFunctionBody()
468 MCSymbol *LocSym = BC.Ctx->createTempSymbol(); in emitFunctionBody()
473 Streamer.emitInstruction(Instr, *BC.STI); in emitFunctionBody()
474 LastIsPrefix = BC.MIB->isPrefix(Instr); in emitFunctionBody()
496 Streamer.emitCodeAlignment(Alignment, &*BC.STI); in emitConstantIslands()
656 CurrentLineTable = BC.DwCtx->getLineTableForUnit( in emitLineInfo()
657 BC.DwCtx->getCompileUnitForOffset(CurrentUnitIndex)); in emitLineInfo()
659 CurrentFilenum = BC.addDebugFilenameToUnit( in emitLineInfo()
678 BC.Ctx->setCurrentDwarfLoc(CurrentFilenum, CurrentRow.Line, CurrentRow.Column, in emitLineInfo()
680 const MCDwarfLoc &DwarfLoc = BC.Ctx->getCurrentDwarfLoc(); in emitLineInfo()
681 BC.Ctx->clearDwarfLocSeen(); in emitLineInfo()
683 MCSymbol *LineSym = BC.Ctx->createTempSymbol(); in emitLineInfo()
686 BC.getDwarfLineTable(FunctionUnitIndex) in emitLineInfo()
698 BC.Ctx->setCurrentDwarfLoc(0, 0, 0, DWARF2_FLAG_END_SEQUENCE, 0, 0); in emitLineInfoEnd()
699 const MCDwarfLoc &DwarfLoc = BC.Ctx->getCurrentDwarfLoc(); in emitLineInfoEnd()
700 BC.Ctx->clearDwarfLocSeen(); in emitLineInfoEnd()
701 BC.getDwarfLineTable(FunctionCU->getOffset()) in emitLineInfoEnd()
708 MCSection *ReadOnlySection = BC.MOFI->getReadOnlySection(); in emitJumpTables()
709 MCSection *ReadOnlyColdSection = BC.MOFI->getContext().getELFSection( in emitJumpTables()
723 BC.HasRelocations) { in emitJumpTables()
734 BC.registerOrUpdateSection(Name, ELF::SHT_PROGBITS, ELF::SHF_ALLOC); in emitJumpTables()
737 HotSection = BC.getDataSection(Name); in emitJumpTables()
878 Streamer.switchSection(BC.MOFI->getLSDASection()); in emitLSDA()
880 const unsigned TTypeEncoding = BC.TTypeEncoding; in emitLSDA()
881 const unsigned TTypeEncodingSize = BC.getDWARFEncodingSize(TTypeEncoding); in emitLSDA()
917 if (BC.HasFixedLoadAddress) { in emitLSDA()
1010 BC.getOrCreateGlobalSymbol(TypeAddress, "TI", 0, TTypeAlignment); in emitLSDA()
1011 MCSymbol *DotSymbol = BC.Ctx->createNamedTempSymbol(); in emitLSDA()
1014 MCSymbolRefExpr::create(TypeSymbol, *BC.Ctx), in emitLSDA()
1015 MCSymbolRefExpr::create(DotSymbol, *BC.Ctx), *BC.Ctx); in emitLSDA()
1032 for (auto &It : BC.getBinaryFunctions()) { in emitDebugLineInfoForOriginalFunctions()
1066 BC.getDwarfLineTable(Function.getDWARFUnit()->getOffset()) in emitDebugLineInfoForOriginalFunctions()
1080 StmtListOffsets.reserve(BC.DwCtx->getNumCompileUnits()); in emitDebugLineInfoForUnprocessedCUs()
1081 for (const std::unique_ptr<DWARFUnit> &CU : BC.DwCtx->compile_units()) { in emitDebugLineInfoForUnprocessedCUs()
1092 for (const std::unique_ptr<DWARFUnit> &CU : BC.DwCtx->compile_units()) { in emitDebugLineInfoForUnprocessedCUs()
1093 if (BC.ProcessedCUs.count(CU.get())) in emitDebugLineInfoForUnprocessedCUs()
1111 BC.getDwarfLineTable(CU->getOffset()) in emitDebugLineInfoForUnprocessedCUs()
1117 for (BinarySection &Section : BC.sections()) { in emitDataSections()
1133 void emitBinaryContext(MCStreamer &Streamer, BinaryContext &BC, in emitBinaryContext() argument
1135 BinaryEmitter(Streamer, BC).emitAll(OrgSecPrefix); in emitBinaryContext()