Lines Matching refs:TM
352 TM->getFunctionSections() ? Name->getString() : StringRef()); in emitModuleMetadata()
405 const GlobalValue *GV, const TargetMachine &TM, in getCFIPersonalitySymbol() argument
410 TM.getSymbol(GV)->getName()); in getCFIPersonalitySymbol()
412 return TM.getSymbol(GV); in getCFIPersonalitySymbol()
439 const GlobalValue *GV, unsigned Encoding, const TargetMachine &TM, in getTTypeGlobalReference() argument
444 MCSymbol *SSym = getSymbolWithGlobalValueBase(GV, ".DW.stub", TM); in getTTypeGlobalReference()
450 MCSymbol *Sym = TM.getSymbol(GV); in getTTypeGlobalReference()
459 return TargetLoweringObjectFile::getTTypeGlobalReference(GV, Encoding, TM, in getTTypeGlobalReference()
580 const TargetMachine &TM) { in getLinkedToSymbol() argument
587 return OtherGV ? dyn_cast<MCSymbolELF>(TM.getSymbol(OtherGV)) : nullptr; in getLinkedToSymbol()
636 Mangler &Mang, const TargetMachine &TM, in getELFSectionNameForGlobal() argument
652 Name = getSectionPrefixForGlobal(Kind, TM.isLargeGlobalValue(GO)); in getELFSectionNameForGlobal()
665 TM.getNameWithPrefix(Name, GO, Mang, /*MayAlwaysUsePrivate*/true); in getELFSectionNameForGlobal()
689 SectionKind Kind, const TargetMachine &TM, in calcUniqueIDUpdateFlagsAndSize() argument
708 if (TM.getTargetTriple().isOSSolaris()) in calcUniqueIDUpdateFlagsAndSize()
751 getELFSectionNameForGlobal(GO, Kind, Mang, TM, EntrySize, false); in calcUniqueIDUpdateFlagsAndSize()
763 getGlobalObjectInfo(const GlobalObject *GO, const TargetMachine &TM) { in getGlobalObjectInfo() argument
772 if (TM.isLargeGlobalValue(GO)) in getGlobalObjectInfo()
778 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM, in selectExplicitSectionGlobal() argument
808 auto [Group, IsComdat, ExtraFlags] = getGlobalObjectInfo(GO, TM); in selectExplicitSectionGlobal()
813 GO, SectionName, Kind, TM, Ctx, Mang, Flags, EntrySize, NextUniqueID, in selectExplicitSectionGlobal()
816 const MCSymbolELF *LinkedToSym = getLinkedToSymbol(GO, TM); in selectExplicitSectionGlobal()
846 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in getExplicitSectionGlobal()
847 return selectExplicitSectionGlobal(GO, Kind, TM, getContext(), getMangler(), in getExplicitSectionGlobal()
854 const TargetMachine &TM, bool EmitUniqueSection, unsigned Flags, in selectELFSectionForGlobal() argument
857 auto [Group, IsComdat, ExtraFlags] = getGlobalObjectInfo(GO, TM); in selectELFSectionForGlobal()
866 if (TM.getUniqueSectionNames()) { in selectELFSectionForGlobal()
874 GO, Kind, Mang, TM, EntrySize, UniqueSectionName); in selectELFSectionForGlobal()
886 const TargetMachine &TM, bool Retain, bool EmitUniqueSection, in selectELFSectionForGlobal() argument
888 const MCSymbolELF *LinkedToSym = getLinkedToSymbol(GO, TM); in selectELFSectionForGlobal()
894 if (TM.getTargetTriple().isOSSolaris()) { in selectELFSectionForGlobal()
905 Ctx, GO, Kind, Mang, TM, EmitUniqueSection, Flags, in selectELFSectionForGlobal()
912 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in SelectSectionForGlobal()
920 EmitUniqueSection = TM.getFunctionSections(); in SelectSectionForGlobal()
922 EmitUniqueSection = TM.getDataSections(); in SelectSectionForGlobal()
925 return selectELFSectionForGlobal(getContext(), GO, Kind, getMangler(), TM, in SelectSectionForGlobal()
931 const Function &F, const TargetMachine &TM) const { in getUniqueSectionForFunction()
938 &F, Kind, TM, getContext(), getMangler(), NextUniqueID, in getUniqueSectionForFunction()
942 getContext(), &F, Kind, getMangler(), TM, Used.count(&F), in getUniqueSectionForFunction()
947 const Function &F, const TargetMachine &TM) const { in getSectionForJumpTable()
951 bool EmitUniqueSection = TM.getFunctionSections() || C; in getSectionForJumpTable()
956 getMangler(), TM, EmitUniqueSection, in getSectionForJumpTable()
962 const Function &F, const MCSymbol &FnSym, const TargetMachine &TM) const { in getSectionForLSDA()
965 if (!LSDASection || (!F.hasComdat() && !TM.getFunctionSections())) in getSectionForLSDA()
980 if (TM.getFunctionSections() && in getSectionForLSDA()
990 (TM.getUniqueSectionNames() ? LSDA->getName() + "." + F.getName() in getSectionForLSDA()
1026 const TargetMachine &TM) const { in getSectionForMachineBasicBlock()
1049 if (TM.getUniqueBasicBlockSectionNames()) { in getSectionForMachineBasicBlock()
1127 const TargetMachine &TM) const { in lowerRelativeReference()
1140 MCSymbolRefExpr::create(TM.getSymbol(LHS), PLTRelativeVariantKind, in lowerRelativeReference()
1142 MCSymbolRefExpr::create(TM.getSymbol(RHS), getContext()), getContext()); in lowerRelativeReference()
1146 const DSOLocalEquivalent *Equiv, const TargetMachine &TM) const { in lowerDSOLocalEquivalent()
1153 return MCSymbolRefExpr::create(TM.getSymbol(GV), getContext()); in lowerDSOLocalEquivalent()
1155 return MCSymbolRefExpr::create(TM.getSymbol(GV), PLTRelativeVariantKind, in lowerDSOLocalEquivalent()
1195 const TargetMachine &TM) { in Initialize() argument
1196 TargetLoweringObjectFile::Initialize(Ctx, TM); in Initialize()
1197 if (TM.getRelocationModel() == Reloc::Static) { in Initialize()
1282 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in getExplicitSectionGlobal()
1343 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in SelectSectionForGlobal()
1435 const GlobalValue *GV, unsigned Encoding, const TargetMachine &TM, in getTTypeGlobalReference() argument
1443 MCSymbol *SSym = getSymbolWithGlobalValueBase(GV, "$non_lazy_ptr", TM); in getTTypeGlobalReference()
1449 MCSymbol *Sym = TM.getSymbol(GV); in getTTypeGlobalReference()
1458 return TargetLoweringObjectFile::getTTypeGlobalReference(GV, Encoding, TM, in getTTypeGlobalReference()
1463 const GlobalValue *GV, const TargetMachine &TM, in getCFIPersonalitySymbol() argument
1469 MCSymbol *SSym = getSymbolWithGlobalValueBase(GV, "$non_lazy_ptr", TM); in getCFIPersonalitySymbol()
1475 MCSymbol *Sym = TM.getSymbol(GV); in getCFIPersonalitySymbol()
1573 const TargetMachine &TM) const { in getNameWithPrefix()
1576 SectionKind GOKind = TargetLoweringObjectFile::getKindForGlobal(GO, TM); in getNameWithPrefix()
1577 const MCSection *TheSection = SectionForGlobal(GO, GOKind, TM); in getNameWithPrefix()
1579 !canUsePrivateLabel(*TM.getMCAsmInfo(), *TheSection); in getNameWithPrefix()
1589 getCOFFSectionFlags(SectionKind K, const TargetMachine &TM) { in getCOFFSectionFlags() argument
1591 bool isThumb = TM.getTargetTriple().getArch() == Triple::thumb; in getCOFFSectionFlags()
1671 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in getExplicitSectionGlobal()
1683 unsigned Characteristics = getCOFFSectionFlags(Kind, TM); in getExplicitSectionGlobal()
1694 MCSymbol *Sym = TM.getSymbol(ComdatGV); in getExplicitSectionGlobal()
1719 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in SelectSectionForGlobal()
1724 EmitUniquedSection = TM.getFunctionSections(); in SelectSectionForGlobal()
1726 EmitUniquedSection = TM.getDataSections(); in SelectSectionForGlobal()
1731 unsigned Characteristics = getCOFFSectionFlags(Kind, TM); in SelectSectionForGlobal()
1748 MCSymbol *Sym = TM.getSymbol(ComdatGV); in SelectSectionForGlobal()
1791 const TargetMachine &TM) const { in getNameWithPrefix()
1794 ((isa<Function>(GV) && TM.getFunctionSections()) || in getNameWithPrefix()
1795 (isa<GlobalVariable>(GV) && TM.getDataSections()))) in getNameWithPrefix()
1802 const Function &F, const TargetMachine &TM) const { in getSectionForJumpTable()
1806 bool EmitUniqueSection = TM.getFunctionSections() || C; in getSectionForJumpTable()
1814 MCSymbol *Sym = TM.getSymbol(&F); in getSectionForJumpTable()
1819 unsigned Characteristics = getCOFFSectionFlags(Kind, TM); in getSectionForJumpTable()
1830 if (TM->getTargetTriple().getArch() == Triple::x86_64) { in shouldPutJumpTableInFunctionSection()
1928 const TargetMachine &TM) { in Initialize() argument
1929 TargetLoweringObjectFile::Initialize(Ctx, TM); in Initialize()
1930 this->TM = &TM; in Initialize()
1931 const Triple &T = TM.getTargetTriple(); in Initialize()
2020 const TargetMachine &TM) const { in lowerRelativeReference()
2021 const Triple &T = TM.getTargetTriple(); in lowerRelativeReference()
2044 return MCSymbolRefExpr::create(TM.getSymbol(LHS), in lowerRelativeReference()
2159 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in getExplicitSectionGlobal()
2163 return SelectSectionForGlobal(GO, Kind, TM); in getExplicitSectionGlobal()
2190 const TargetMachine &TM, bool EmitUniqueSection, unsigned *NextUniqueID) { in selectWasmSectionForGlobal() argument
2196 bool UniqueSectionNames = TM.getUniqueSectionNames(); in selectWasmSectionForGlobal()
2207 TM.getNameWithPrefix(Name, GO, Mang, true); in selectWasmSectionForGlobal()
2220 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in SelectSectionForGlobal()
2229 EmitUniqueSection = TM.getFunctionSections(); in SelectSectionForGlobal()
2231 EmitUniqueSection = TM.getDataSections(); in SelectSectionForGlobal()
2234 return selectWasmSectionForGlobal(getContext(), GO, Kind, getMangler(), TM, in SelectSectionForGlobal()
2247 const TargetMachine &TM) const { in lowerRelativeReference()
2260 MCSymbolRefExpr::create(TM.getSymbol(LHS), MCSymbolRefExpr::VK_None, in lowerRelativeReference()
2262 MCSymbolRefExpr::create(TM.getSymbol(RHS), getContext()), getContext()); in lowerRelativeReference()
2329 const TargetMachine &TM) const { in getTargetSymbol()
2340 return cast<MCSectionXCOFF>(getSectionForExternalReference(GO, TM)) in getTargetSymbol()
2346 SectionForGlobal(GVar, SectionKind::getData(), TM)) in getTargetSymbol()
2349 SectionKind GOKind = getKindForGlobal(GO, TM); in getTargetSymbol()
2352 getSectionForFunctionDescriptor(cast<Function>(GO), TM)) in getTargetSymbol()
2354 if ((TM.getDataSections() && !GO->hasSection()) || GO->hasCommonLinkage() || in getTargetSymbol()
2356 return cast<MCSectionXCOFF>(SectionForGlobal(GO, GOKind, TM)) in getTargetSymbol()
2365 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in getExplicitSectionGlobal()
2386 TM.Options.XCOFFReadOnlyPointers ? XCOFF::XMC_RO : XCOFF::XMC_RW; in getExplicitSectionGlobal()
2398 const GlobalObject *GO, const TargetMachine &TM) const { in getSectionForExternalReference()
2403 getNameWithPrefix(Name, GO, TM); in getSectionForExternalReference()
2421 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in SelectSectionForGlobal()
2426 getNameWithPrefix(Name, GO, TM); in SelectSectionForGlobal()
2438 getNameWithPrefix(Name, GO, TM); in SelectSectionForGlobal()
2447 if (TM.getFunctionSections()) { in SelectSectionForGlobal()
2448 return cast<MCSymbolXCOFF>(getFunctionEntryPointSymbol(GO, TM)) in SelectSectionForGlobal()
2454 if (TM.Options.XCOFFReadOnlyPointers && Kind.isReadOnlyWithRel()) { in SelectSectionForGlobal()
2455 if (!TM.getDataSections()) in SelectSectionForGlobal()
2460 getNameWithPrefix(Name, GO, TM); in SelectSectionForGlobal()
2471 if (TM.getDataSections()) { in SelectSectionForGlobal()
2473 getNameWithPrefix(Name, GO, TM); in SelectSectionForGlobal()
2482 if (TM.getDataSections()) { in SelectSectionForGlobal()
2484 getNameWithPrefix(Name, GO, TM); in SelectSectionForGlobal()
2497 if (TM.getDataSections()) { in SelectSectionForGlobal()
2499 getNameWithPrefix(Name, GO, TM); in SelectSectionForGlobal()
2510 const Function &F, const TargetMachine &TM) const { in getSectionForJumpTable()
2513 if (!TM.getFunctionSections()) in getSectionForJumpTable()
2519 getNameWithPrefix(NameStr, &F, TM); in getSectionForJumpTable()
2583 const TargetMachine &TM) const { in lowerRelativeReference()
2614 const GlobalValue *Func, const TargetMachine &TM) const { in getFunctionEntryPointSymbol()
2624 getNameWithPrefix(NameStr, Func, TM); in getFunctionEntryPointSymbol()
2630 if (((TM.getFunctionSections() && !Func->hasSection()) || in getFunctionEntryPointSymbol()
2646 const Function *F, const TargetMachine &TM) const { in getSectionForFunctionDescriptor()
2648 getNameWithPrefix(NameStr, F, TM); in getSectionForFunctionDescriptor()
2655 const MCSymbol *Sym, const TargetMachine &TM) const { in getSectionForTOCEntry()
2662 XCOFF::CsectProperties((TM.getCodeModel() == CodeModel::Large || in getSectionForTOCEntry()
2670 const Function &F, const MCSymbol &FnSym, const TargetMachine &TM) const { in getSectionForLSDA()
2672 if (TM.getFunctionSections()) { in getSectionForLSDA()
2689 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in getExplicitSectionGlobal()
2690 return SelectSectionForGlobal(GO, Kind, TM); in getExplicitSectionGlobal()
2694 const Function &F, const MCSymbol &FnSym, const TargetMachine &TM) const { in getSectionForLSDA()
2701 const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { in SelectSectionForGlobal()
2702 auto *Symbol = TM.getSymbol(GO); in SelectSectionForGlobal()