LLVM  16.0.0git
MCObjectFileInfo.cpp
Go to the documentation of this file.
1 //===-- MCObjectFileInfo.cpp - Object File Information --------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
10 #include "llvm/ADT/StringExtras.h"
11 #include "llvm/ADT/Triple.h"
12 #include "llvm/BinaryFormat/COFF.h"
13 #include "llvm/BinaryFormat/ELF.h"
14 #include "llvm/BinaryFormat/Wasm.h"
15 #include "llvm/MC/MCAsmInfo.h"
16 #include "llvm/MC/MCContext.h"
17 #include "llvm/MC/MCSection.h"
18 #include "llvm/MC/MCSectionCOFF.h"
20 #include "llvm/MC/MCSectionELF.h"
21 #include "llvm/MC/MCSectionGOFF.h"
22 #include "llvm/MC/MCSectionMachO.h"
23 #include "llvm/MC/MCSectionSPIRV.h"
24 #include "llvm/MC/MCSectionWasm.h"
25 #include "llvm/MC/MCSectionXCOFF.h"
26 #include "llvm/Support/Casting.h"
27 
28 using namespace llvm;
29 
30 static bool useCompactUnwind(const Triple &T) {
31  // Only on darwin.
32  if (!T.isOSDarwin())
33  return false;
34 
35  // aarch64 always has it.
36  if (T.getArch() == Triple::aarch64 || T.getArch() == Triple::aarch64_32)
37  return true;
38 
39  // armv7k always has it.
40  if (T.isWatchABI())
41  return true;
42 
43  // Use it on newer version of OS X.
44  if (T.isMacOSX() && !T.isMacOSXVersionLT(10, 6))
45  return true;
46 
47  // And the iOS simulator.
48  if (T.isiOS() && T.isX86())
49  return true;
50 
51  return false;
52 }
53 
54 void MCObjectFileInfo::initMachOMCObjectFileInfo(const Triple &T) {
55  // MachO
57 
59  "__TEXT", "__eh_frame",
63 
64  if (T.isOSDarwin() &&
65  (T.getArch() == Triple::aarch64 || T.getArch() == Triple::aarch64_32))
67 
68  switch (Ctx->emitDwarfUnwindInfo()) {
71  break;
74  break;
77  T.isWatchABI() || SupportsCompactUnwindWithoutEHFrame;
78  break;
79  }
80 
82 
83  TextSection // .text
84  = Ctx->getMachOSection("__TEXT", "__text",
87  DataSection // .data
88  = Ctx->getMachOSection("__DATA", "__data", 0, SectionKind::getData());
89 
90  // BSSSection might not be expected initialized on msvc.
91  BSSSection = nullptr;
92 
93  TLSDataSection // .tdata
94  = Ctx->getMachOSection("__DATA", "__thread_data",
97  TLSBSSSection // .tbss
98  = Ctx->getMachOSection("__DATA", "__thread_bss",
101 
102  // TODO: Verify datarel below.
103  TLSTLVSection // .tlv
104  = Ctx->getMachOSection("__DATA", "__thread_vars",
107 
109  "__DATA", "__thread_init", MachO::S_THREAD_LOCAL_INIT_FUNCTION_POINTERS,
111 
112  CStringSection // .cstring
113  = Ctx->getMachOSection("__TEXT", "__cstring",
117  = Ctx->getMachOSection("__TEXT","__ustring", 0,
119  FourByteConstantSection // .literal4
120  = Ctx->getMachOSection("__TEXT", "__literal4",
123  EightByteConstantSection // .literal8
124  = Ctx->getMachOSection("__TEXT", "__literal8",
127 
128  SixteenByteConstantSection // .literal16
129  = Ctx->getMachOSection("__TEXT", "__literal16",
132 
133  ReadOnlySection // .const
134  = Ctx->getMachOSection("__TEXT", "__const", 0,
136 
137  // If the target is not powerpc, map the coal sections to the non-coal
138  // sections.
139  //
140  // "__TEXT/__textcoal_nt" => section "__TEXT/__text"
141  // "__TEXT/__const_coal" => section "__TEXT/__const"
142  // "__DATA/__datacoal_nt" => section "__DATA/__data"
143  Triple::ArchType ArchTy = T.getArch();
144 
145  ConstDataSection // .const_data
146  = Ctx->getMachOSection("__DATA", "__const", 0,
148 
149  if (ArchTy == Triple::ppc || ArchTy == Triple::ppc64) {
151  = Ctx->getMachOSection("__TEXT", "__textcoal_nt",
156  = Ctx->getMachOSection("__TEXT", "__const_coal",
160  "__DATA", "__datacoal_nt", MachO::S_COALESCED, SectionKind::getData());
162  } else {
167  }
168 
170  = Ctx->getMachOSection("__DATA","__common",
174  = Ctx->getMachOSection("__DATA","__bss", MachO::S_ZEROFILL,
176 
177 
179  = Ctx->getMachOSection("__DATA", "__la_symbol_ptr",
183  = Ctx->getMachOSection("__DATA", "__nl_symbol_ptr",
186 
188  = Ctx->getMachOSection("__DATA", "__thread_ptr",
191 
192  AddrSigSection = Ctx->getMachOSection("__DATA", "__llvm_addrsig", 0,
194 
195  // Exception Handling.
196  LSDASection = Ctx->getMachOSection("__TEXT", "__gcc_except_tab", 0,
198 
199  COFFDebugSymbolsSection = nullptr;
200  COFFDebugTypesSection = nullptr;
201  COFFGlobalTypeHashesSection = nullptr;
202 
203  if (useCompactUnwind(T)) {
205  Ctx->getMachOSection("__LD", "__compact_unwind", MachO::S_ATTR_DEBUG,
207 
208  if (T.isX86())
209  CompactUnwindDwarfEHFrameOnly = 0x04000000; // UNWIND_X86_64_MODE_DWARF
210  else if (T.getArch() == Triple::aarch64 || T.getArch() == Triple::aarch64_32)
211  CompactUnwindDwarfEHFrameOnly = 0x03000000; // UNWIND_ARM64_MODE_DWARF
212  else if (T.getArch() == Triple::arm || T.getArch() == Triple::thumb)
213  CompactUnwindDwarfEHFrameOnly = 0x04000000; // UNWIND_ARM_MODE_DWARF
214  }
215 
216  // Debug Information.
218  Ctx->getMachOSection("__DWARF", "__debug_names", MachO::S_ATTR_DEBUG,
219  SectionKind::getMetadata(), "debug_names_begin");
221  Ctx->getMachOSection("__DWARF", "__apple_names", MachO::S_ATTR_DEBUG,
222  SectionKind::getMetadata(), "names_begin");
224  Ctx->getMachOSection("__DWARF", "__apple_objc", MachO::S_ATTR_DEBUG,
225  SectionKind::getMetadata(), "objc_begin");
226  // 16 character section limit...
228  Ctx->getMachOSection("__DWARF", "__apple_namespac", MachO::S_ATTR_DEBUG,
229  SectionKind::getMetadata(), "namespac_begin");
231  Ctx->getMachOSection("__DWARF", "__apple_types", MachO::S_ATTR_DEBUG,
232  SectionKind::getMetadata(), "types_begin");
233 
235  Ctx->getMachOSection("__DWARF", "__swift_ast", MachO::S_ATTR_DEBUG,
237 
239  Ctx->getMachOSection("__DWARF", "__debug_abbrev", MachO::S_ATTR_DEBUG,
240  SectionKind::getMetadata(), "section_abbrev");
242  Ctx->getMachOSection("__DWARF", "__debug_info", MachO::S_ATTR_DEBUG,
243  SectionKind::getMetadata(), "section_info");
245  Ctx->getMachOSection("__DWARF", "__debug_line", MachO::S_ATTR_DEBUG,
246  SectionKind::getMetadata(), "section_line");
248  Ctx->getMachOSection("__DWARF", "__debug_line_str", MachO::S_ATTR_DEBUG,
249  SectionKind::getMetadata(), "section_line_str");
251  Ctx->getMachOSection("__DWARF", "__debug_frame", MachO::S_ATTR_DEBUG,
254  Ctx->getMachOSection("__DWARF", "__debug_pubnames", MachO::S_ATTR_DEBUG,
257  Ctx->getMachOSection("__DWARF", "__debug_pubtypes", MachO::S_ATTR_DEBUG,
260  Ctx->getMachOSection("__DWARF", "__debug_gnu_pubn", MachO::S_ATTR_DEBUG,
263  Ctx->getMachOSection("__DWARF", "__debug_gnu_pubt", MachO::S_ATTR_DEBUG,
266  Ctx->getMachOSection("__DWARF", "__debug_str", MachO::S_ATTR_DEBUG,
267  SectionKind::getMetadata(), "info_string");
269  Ctx->getMachOSection("__DWARF", "__debug_str_offs", MachO::S_ATTR_DEBUG,
270  SectionKind::getMetadata(), "section_str_off");
272  Ctx->getMachOSection("__DWARF", "__debug_addr", MachO::S_ATTR_DEBUG,
273  SectionKind::getMetadata(), "section_info");
275  Ctx->getMachOSection("__DWARF", "__debug_loc", MachO::S_ATTR_DEBUG,
276  SectionKind::getMetadata(), "section_debug_loc");
278  Ctx->getMachOSection("__DWARF", "__debug_loclists", MachO::S_ATTR_DEBUG,
279  SectionKind::getMetadata(), "section_debug_loc");
280 
282  Ctx->getMachOSection("__DWARF", "__debug_aranges", MachO::S_ATTR_DEBUG,
285  Ctx->getMachOSection("__DWARF", "__debug_ranges", MachO::S_ATTR_DEBUG,
286  SectionKind::getMetadata(), "debug_range");
288  Ctx->getMachOSection("__DWARF", "__debug_rnglists", MachO::S_ATTR_DEBUG,
289  SectionKind::getMetadata(), "debug_range");
291  Ctx->getMachOSection("__DWARF", "__debug_macinfo", MachO::S_ATTR_DEBUG,
292  SectionKind::getMetadata(), "debug_macinfo");
294  Ctx->getMachOSection("__DWARF", "__debug_macro", MachO::S_ATTR_DEBUG,
295  SectionKind::getMetadata(), "debug_macro");
297  Ctx->getMachOSection("__DWARF", "__debug_inlined", MachO::S_ATTR_DEBUG,
300  Ctx->getMachOSection("__DWARF", "__debug_cu_index", MachO::S_ATTR_DEBUG,
303  Ctx->getMachOSection("__DWARF", "__debug_tu_index", MachO::S_ATTR_DEBUG,
305  StackMapSection = Ctx->getMachOSection("__LLVM_STACKMAPS", "__llvm_stackmaps",
307 
308  FaultMapSection = Ctx->getMachOSection("__LLVM_FAULTMAPS", "__llvm_faultmaps",
310 
312  "__LLVM", "__remarks", MachO::S_ATTR_DEBUG, SectionKind::getMetadata());
313 
314  // The architecture of dsymutil makes it very difficult to copy the Swift
315  // reflection metadata sections into the __TEXT segment, so dsymutil creates
316  // these sections in the __DWARF segment instead.
317  if (!Ctx->getSwift5ReflectionSegmentName().empty()) {
318 #define HANDLE_SWIFT_SECTION(KIND, MACHO, ELF, COFF) \
319  Swift5ReflectionSections \
320  [llvm::binaryformat::Swift5ReflectionSectionKind::KIND] = \
321  Ctx->getMachOSection(Ctx->getSwift5ReflectionSegmentName().data(), \
322  MACHO, 0, SectionKind::getMetadata());
323 #include "llvm/BinaryFormat/Swift.def"
324  }
325 
327 }
328 
329 void MCObjectFileInfo::initELFMCObjectFileInfo(const Triple &T, bool Large) {
330  switch (T.getArch()) {
331  case Triple::mips:
332  case Triple::mipsel:
333  case Triple::mips64:
334  case Triple::mips64el:
335  // We cannot use DW_EH_PE_sdata8 for the large PositionIndependent case
336  // since there is no R_MIPS_PC64 relocation (only a 32-bit version).
337  if (PositionIndependent && !Large)
339  else
343  break;
344  case Triple::ppc64:
345  case Triple::ppc64le:
346  case Triple::aarch64:
347  case Triple::aarch64_be:
348  case Triple::x86_64:
351  break;
352  case Triple::bpfel:
353  case Triple::bpfeb:
355  break;
356  case Triple::hexagon:
358  PositionIndependent ? dwarf::DW_EH_PE_pcrel : dwarf::DW_EH_PE_absptr;
359  break;
360  default:
362  break;
363  }
364 
365  unsigned EHSectionType = T.getArch() == Triple::x86_64
368 
369  // Solaris requires different flags for .eh_frame to seemingly every other
370  // platform.
371  unsigned EHSectionFlags = ELF::SHF_ALLOC;
372  if (T.isOSSolaris() && T.getArch() != Triple::x86_64)
373  EHSectionFlags |= ELF::SHF_WRITE;
374 
375  // ELF
378 
381 
384 
387 
389  Ctx->getELFSection(".tdata", ELF::SHT_PROGBITS,
391 
394 
395  DataRelROSection = Ctx->getELFSection(".data.rel.ro", ELF::SHT_PROGBITS,
397 
399  Ctx->getELFSection(".rodata.cst4", ELF::SHT_PROGBITS,
401 
403  Ctx->getELFSection(".rodata.cst8", ELF::SHT_PROGBITS,
405 
407  Ctx->getELFSection(".rodata.cst16", ELF::SHT_PROGBITS,
409 
411  Ctx->getELFSection(".rodata.cst32", ELF::SHT_PROGBITS,
413 
414  // Exception Handling Sections.
415 
416  // FIXME: We're emitting LSDA info into a readonly section on ELF, even though
417  // it contains relocatable pointers. In PIC mode, this is probably a big
418  // runtime hit for C++ apps. Either the contents of the LSDA need to be
419  // adjusted or this should be a data section.
420  LSDASection = Ctx->getELFSection(".gcc_except_table", ELF::SHT_PROGBITS,
422 
423  COFFDebugSymbolsSection = nullptr;
424  COFFDebugTypesSection = nullptr;
425 
426  unsigned DebugSecType = ELF::SHT_PROGBITS;
427 
428  // MIPS .debug_* sections should have SHT_MIPS_DWARF section type
429  // to distinguish among sections contain DWARF and ECOFF debug formats.
430  // Sections with ECOFF debug format are obsoleted and marked by SHT_PROGBITS.
431  if (T.isMIPS())
432  DebugSecType = ELF::SHT_MIPS_DWARF;
433 
434  // Debug Info Sections.
436  Ctx->getELFSection(".debug_abbrev", DebugSecType, 0);
437  DwarfInfoSection = Ctx->getELFSection(".debug_info", DebugSecType, 0);
438  DwarfLineSection = Ctx->getELFSection(".debug_line", DebugSecType, 0);
440  Ctx->getELFSection(".debug_line_str", DebugSecType,
442  DwarfFrameSection = Ctx->getELFSection(".debug_frame", DebugSecType, 0);
444  Ctx->getELFSection(".debug_pubnames", DebugSecType, 0);
446  Ctx->getELFSection(".debug_pubtypes", DebugSecType, 0);
448  Ctx->getELFSection(".debug_gnu_pubnames", DebugSecType, 0);
450  Ctx->getELFSection(".debug_gnu_pubtypes", DebugSecType, 0);
452  Ctx->getELFSection(".debug_str", DebugSecType,
454  DwarfLocSection = Ctx->getELFSection(".debug_loc", DebugSecType, 0);
456  Ctx->getELFSection(".debug_aranges", DebugSecType, 0);
458  Ctx->getELFSection(".debug_ranges", DebugSecType, 0);
460  Ctx->getELFSection(".debug_macinfo", DebugSecType, 0);
461  DwarfMacroSection = Ctx->getELFSection(".debug_macro", DebugSecType, 0);
462 
463  // DWARF5 Experimental Debug Info
464 
465  // Accelerator Tables
467  Ctx->getELFSection(".debug_names", ELF::SHT_PROGBITS, 0);
469  Ctx->getELFSection(".apple_names", ELF::SHT_PROGBITS, 0);
471  Ctx->getELFSection(".apple_objc", ELF::SHT_PROGBITS, 0);
473  Ctx->getELFSection(".apple_namespaces", ELF::SHT_PROGBITS, 0);
475  Ctx->getELFSection(".apple_types", ELF::SHT_PROGBITS, 0);
476 
477  // String Offset and Address Sections
479  Ctx->getELFSection(".debug_str_offsets", DebugSecType, 0);
480  DwarfAddrSection = Ctx->getELFSection(".debug_addr", DebugSecType, 0);
481  DwarfRnglistsSection = Ctx->getELFSection(".debug_rnglists", DebugSecType, 0);
482  DwarfLoclistsSection = Ctx->getELFSection(".debug_loclists", DebugSecType, 0);
483 
484  // Fission Sections
486  Ctx->getELFSection(".debug_info.dwo", DebugSecType, ELF::SHF_EXCLUDE);
488  Ctx->getELFSection(".debug_types.dwo", DebugSecType, ELF::SHF_EXCLUDE);
490  Ctx->getELFSection(".debug_abbrev.dwo", DebugSecType, ELF::SHF_EXCLUDE);
492  ".debug_str.dwo", DebugSecType,
495  Ctx->getELFSection(".debug_line.dwo", DebugSecType, ELF::SHF_EXCLUDE);
497  Ctx->getELFSection(".debug_loc.dwo", DebugSecType, ELF::SHF_EXCLUDE);
498  DwarfStrOffDWOSection = Ctx->getELFSection(".debug_str_offsets.dwo",
499  DebugSecType, ELF::SHF_EXCLUDE);
501  Ctx->getELFSection(".debug_rnglists.dwo", DebugSecType, ELF::SHF_EXCLUDE);
503  Ctx->getELFSection(".debug_macinfo.dwo", DebugSecType, ELF::SHF_EXCLUDE);
505  Ctx->getELFSection(".debug_macro.dwo", DebugSecType, ELF::SHF_EXCLUDE);
506 
508  Ctx->getELFSection(".debug_loclists.dwo", DebugSecType, ELF::SHF_EXCLUDE);
509 
510  // DWP Sections
512  Ctx->getELFSection(".debug_cu_index", DebugSecType, 0);
514  Ctx->getELFSection(".debug_tu_index", DebugSecType, 0);
515 
517  Ctx->getELFSection(".llvm_stackmaps", ELF::SHT_PROGBITS, ELF::SHF_ALLOC);
518 
520  Ctx->getELFSection(".llvm_faultmaps", ELF::SHT_PROGBITS, ELF::SHF_ALLOC);
521 
523  Ctx->getELFSection(".eh_frame", EHSectionType, EHSectionFlags);
524 
525  StackSizesSection = Ctx->getELFSection(".stack_sizes", ELF::SHT_PROGBITS, 0);
526 
527  PseudoProbeSection = Ctx->getELFSection(".pseudo_probe", DebugSecType, 0);
529  Ctx->getELFSection(".pseudo_probe_desc", DebugSecType, 0);
530 
531  LLVMStatsSection = Ctx->getELFSection(".llvm_stats", ELF::SHT_PROGBITS, 0);
532 }
533 
534 void MCObjectFileInfo::initGOFFMCObjectFileInfo(const Triple &T) {
535  TextSection =
536  Ctx->getGOFFSection(".text", SectionKind::getText(), nullptr, nullptr);
537  BSSSection =
538  Ctx->getGOFFSection(".bss", SectionKind::getBSS(), nullptr, nullptr);
539  PPA1Section =
542 }
543 
544 void MCObjectFileInfo::initCOFFMCObjectFileInfo(const Triple &T) {
549 
550  // Set the `IMAGE_SCN_MEM_16BIT` flag when compiling for thumb mode. This is
551  // used to indicate to the linker that the text segment contains thumb instructions
552  // and to set the ISA selection bit for calls accordingly.
553  const bool IsThumb = T.getArch() == Triple::thumb;
554 
555  // COFF
556  BSSSection = Ctx->getCOFFSection(
561  ".text",
573 
574  if (T.getArch() == Triple::x86_64 || T.getArch() == Triple::aarch64 ||
575  T.getArch() == Triple::arm || T.getArch() == Triple::thumb) {
576  // On Windows with SEH, the LSDA is emitted into the .xdata section
577  LSDASection = nullptr;
578  } else {
579  LSDASection = Ctx->getCOFFSection(".gcc_except_table",
583  }
584 
585  // Debug info.
597  ".debug$H",
601 
603  ".debug_abbrev",
606  SectionKind::getMetadata(), "section_abbrev");
608  ".debug_info",
611  SectionKind::getMetadata(), "section_info");
613  ".debug_line",
616  SectionKind::getMetadata(), "section_line");
618  ".debug_line_str",
621  SectionKind::getMetadata(), "section_line_str");
623  ".debug_frame",
628  ".debug_pubnames",
633  ".debug_pubtypes",
638  ".debug_gnu_pubnames",
643  ".debug_gnu_pubtypes",
648  ".debug_str",
651  SectionKind::getMetadata(), "info_string");
653  ".debug_str_offsets",
656  SectionKind::getMetadata(), "section_str_off");
658  ".debug_loc",
661  SectionKind::getMetadata(), "section_debug_loc");
663  ".debug_loclists",
666  SectionKind::getMetadata(), "section_debug_loclists");
668  ".debug_aranges",
673  ".debug_ranges",
676  SectionKind::getMetadata(), "debug_range");
678  ".debug_rnglists",
681  SectionKind::getMetadata(), "debug_rnglists");
683  ".debug_macinfo",
686  SectionKind::getMetadata(), "debug_macinfo");
688  ".debug_macro",
691  SectionKind::getMetadata(), "debug_macro");
693  ".debug_macinfo.dwo",
696  SectionKind::getMetadata(), "debug_macinfo.dwo");
698  ".debug_macro.dwo",
701  SectionKind::getMetadata(), "debug_macro.dwo");
703  ".debug_info.dwo",
706  SectionKind::getMetadata(), "section_info_dwo");
708  ".debug_types.dwo",
711  SectionKind::getMetadata(), "section_types_dwo");
713  ".debug_abbrev.dwo",
716  SectionKind::getMetadata(), "section_abbrev_dwo");
718  ".debug_str.dwo",
721  SectionKind::getMetadata(), "skel_string");
723  ".debug_line.dwo",
728  ".debug_loc.dwo",
731  SectionKind::getMetadata(), "skel_loc");
733  ".debug_str_offsets.dwo",
736  SectionKind::getMetadata(), "section_str_off_dwo");
738  ".debug_addr",
741  SectionKind::getMetadata(), "addr_sec");
743  ".debug_cu_index",
748  ".debug_tu_index",
753  ".debug_names",
756  SectionKind::getMetadata(), "debug_names_begin");
758  ".apple_names",
761  SectionKind::getMetadata(), "names_begin");
763  ".apple_namespaces",
766  SectionKind::getMetadata(), "namespac_begin");
768  ".apple_types",
771  SectionKind::getMetadata(), "types_begin");
773  ".apple_objc",
776  SectionKind::getMetadata(), "objc_begin");
777 
781 
785 
789 
792 
793  GEHContSection = Ctx->getCOFFSection(".gehcont$y",
797 
798  GFIDsSection = Ctx->getCOFFSection(".gfids$y",
802 
803  GIATsSection = Ctx->getCOFFSection(".giats$y",
807 
808  GLJMPSection = Ctx->getCOFFSection(".gljmp$y",
812 
817 
818  StackMapSection = Ctx->getCOFFSection(".llvm_stackmaps",
822 }
823 
824 void MCObjectFileInfo::initSPIRVMCObjectFileInfo(const Triple &T) {
825  // Put everything in a single binary section.
826  TextSection = Ctx->getSPIRVSection();
827 }
828 
829 void MCObjectFileInfo::initWasmMCObjectFileInfo(const Triple &T) {
832 
834  Ctx->getWasmSection(".debug_line", SectionKind::getMetadata());
836  Ctx->getWasmSection(".debug_line_str", SectionKind::getMetadata(),
841  Ctx->getWasmSection(".debug_loc", SectionKind::getMetadata());
843  Ctx->getWasmSection(".debug_abbrev", SectionKind::getMetadata());
844  DwarfARangesSection = Ctx->getWasmSection(".debug_aranges", SectionKind::getMetadata());
846  Ctx->getWasmSection(".debug_ranges", SectionKind::getMetadata());
848  Ctx->getWasmSection(".debug_macinfo", SectionKind::getMetadata());
850  Ctx->getWasmSection(".debug_macro", SectionKind::getMetadata());
851  DwarfCUIndexSection = Ctx->getWasmSection(".debug_cu_index", SectionKind::getMetadata());
852  DwarfTUIndexSection = Ctx->getWasmSection(".debug_tu_index", SectionKind::getMetadata());
854  Ctx->getWasmSection(".debug_info", SectionKind::getMetadata());
856  DwarfPubNamesSection = Ctx->getWasmSection(".debug_pubnames", SectionKind::getMetadata());
857  DwarfPubTypesSection = Ctx->getWasmSection(".debug_pubtypes", SectionKind::getMetadata());
859  Ctx->getWasmSection(".debug_gnu_pubnames", SectionKind::getMetadata());
861  Ctx->getWasmSection(".debug_gnu_pubtypes", SectionKind::getMetadata());
862 
864  Ctx->getWasmSection(".debug_names", SectionKind::getMetadata());
866  Ctx->getWasmSection(".debug_str_offsets", SectionKind::getMetadata());
868  Ctx->getWasmSection(".debug_addr", SectionKind::getMetadata());
870  Ctx->getWasmSection(".debug_rnglists", SectionKind::getMetadata());
872  Ctx->getWasmSection(".debug_loclists", SectionKind::getMetadata());
873 
874  // Fission Sections
876  Ctx->getWasmSection(".debug_info.dwo", SectionKind::getMetadata());
878  Ctx->getWasmSection(".debug_types.dwo", SectionKind::getMetadata());
880  Ctx->getWasmSection(".debug_abbrev.dwo", SectionKind::getMetadata());
882  Ctx->getWasmSection(".debug_str.dwo", SectionKind::getMetadata(),
885  Ctx->getWasmSection(".debug_line.dwo", SectionKind::getMetadata());
887  Ctx->getWasmSection(".debug_loc.dwo", SectionKind::getMetadata());
889  Ctx->getWasmSection(".debug_str_offsets.dwo", SectionKind::getMetadata());
891  Ctx->getWasmSection(".debug_rnglists.dwo", SectionKind::getMetadata());
893  Ctx->getWasmSection(".debug_macinfo.dwo", SectionKind::getMetadata());
895  Ctx->getWasmSection(".debug_macro.dwo", SectionKind::getMetadata());
896 
898  Ctx->getWasmSection(".debug_loclists.dwo", SectionKind::getMetadata());
899 
900  // DWP Sections
902  Ctx->getWasmSection(".debug_cu_index", SectionKind::getMetadata());
904  Ctx->getWasmSection(".debug_tu_index", SectionKind::getMetadata());
905 
906  // Wasm use data section for LSDA.
907  // TODO Consider putting each function's exception table in a separate
908  // section, as in -function-sections, to facilitate lld's --gc-section.
909  LSDASection = Ctx->getWasmSection(".rodata.gcc_except_table",
911 
912  // TODO: Define more sections.
913 }
914 
915 void MCObjectFileInfo::initXCOFFMCObjectFileInfo(const Triple &T) {
916  // The default csect for program code. Functions without a specified section
917  // get placed into this csect. The choice of csect name is not a property of
918  // the ABI or object file format. For example, the XL compiler uses an unnamed
919  // csect for program code.
921  ".text", SectionKind::getText(),
923  /* MultiSymbolsAllowed*/ true);
924 
926  ".data", SectionKind::getData(),
928  /* MultiSymbolsAllowed*/ true);
929 
931  ".rodata", SectionKind::getReadOnly(),
933  /* MultiSymbolsAllowed*/ true);
935 
937  ".rodata.8", SectionKind::getReadOnly(),
939  /* MultiSymbolsAllowed*/ true);
941 
943  ".rodata.16", SectionKind::getReadOnly(),
945  /* MultiSymbolsAllowed*/ true);
947 
949  ".tdata", SectionKind::getThreadData(),
951  /* MultiSymbolsAllowed*/ true);
952 
954  "TOC", SectionKind::getData(),
956  XCOFF::XTY_SD));
957 
958  // The TOC-base always has 0 size, but 4 byte alignment.
960 
962  ".gcc_except_table", SectionKind::getReadOnly(),
964  XCOFF::XTY_SD));
965 
967  ".eh_info_table", SectionKind::getData(),
969  XCOFF::XTY_SD));
970 
971  // DWARF sections for XCOFF are not csects. They are special STYP_DWARF
972  // sections, and the individual DWARF sections are distinguished by their
973  // section subtype.
975  ".dwabrev", SectionKind::getMetadata(), /* CsectProperties */ None,
976  /* MultiSymbolsAllowed */ true, ".dwabrev", XCOFF::SSUBTYP_DWABREV);
977 
979  ".dwinfo", SectionKind::getMetadata(), /* CsectProperties */ None,
980  /* MultiSymbolsAllowed */ true, ".dwinfo", XCOFF::SSUBTYP_DWINFO);
981 
983  ".dwline", SectionKind::getMetadata(), /* CsectProperties */ None,
984  /* MultiSymbolsAllowed */ true, ".dwline", XCOFF::SSUBTYP_DWLINE);
985 
987  ".dwframe", SectionKind::getMetadata(), /* CsectProperties */ None,
988  /* MultiSymbolsAllowed */ true, ".dwframe", XCOFF::SSUBTYP_DWFRAME);
989 
991  ".dwpbnms", SectionKind::getMetadata(), /* CsectProperties */ None,
992  /* MultiSymbolsAllowed */ true, ".dwpbnms", XCOFF::SSUBTYP_DWPBNMS);
993 
995  ".dwpbtyp", SectionKind::getMetadata(), /* CsectProperties */ None,
996  /* MultiSymbolsAllowed */ true, ".dwpbtyp", XCOFF::SSUBTYP_DWPBTYP);
997 
999  ".dwstr", SectionKind::getMetadata(), /* CsectProperties */ None,
1000  /* MultiSymbolsAllowed */ true, ".dwstr", XCOFF::SSUBTYP_DWSTR);
1001 
1003  ".dwloc", SectionKind::getMetadata(), /* CsectProperties */ None,
1004  /* MultiSymbolsAllowed */ true, ".dwloc", XCOFF::SSUBTYP_DWLOC);
1005 
1007  ".dwarnge", SectionKind::getMetadata(), /* CsectProperties */ None,
1008  /* MultiSymbolsAllowed */ true, ".dwarnge", XCOFF::SSUBTYP_DWARNGE);
1009 
1011  ".dwrnges", SectionKind::getMetadata(), /* CsectProperties */ None,
1012  /* MultiSymbolsAllowed */ true, ".dwrnges", XCOFF::SSUBTYP_DWRNGES);
1013 
1015  ".dwmac", SectionKind::getMetadata(), /* CsectProperties */ None,
1016  /* MultiSymbolsAllowed */ true, ".dwmac", XCOFF::SSUBTYP_DWMAC);
1017 }
1018 
1019 void MCObjectFileInfo::initDXContainerObjectFileInfo(const Triple &T) {
1020  // At the moment the DXBC section should end up empty.
1022 }
1023 
1025 
1027  bool LargeCodeModel) {
1028  PositionIndependent = PIC;
1029  Ctx = &MCCtx;
1030 
1031  // Common.
1035 
1037 
1039 
1040  EHFrameSection = nullptr; // Created on demand.
1041  CompactUnwindSection = nullptr; // Used only by selected targets.
1042  DwarfAccelNamesSection = nullptr; // Used only by selected targets.
1043  DwarfAccelObjCSection = nullptr; // Used only by selected targets.
1044  DwarfAccelNamespaceSection = nullptr; // Used only by selected targets.
1045  DwarfAccelTypesSection = nullptr; // Used only by selected targets.
1046 
1047  Triple TheTriple = Ctx->getTargetTriple();
1048  switch (Ctx->getObjectFileType()) {
1049  case MCContext::IsMachO:
1050  initMachOMCObjectFileInfo(TheTriple);
1051  break;
1052  case MCContext::IsCOFF:
1053  initCOFFMCObjectFileInfo(TheTriple);
1054  break;
1055  case MCContext::IsELF:
1056  initELFMCObjectFileInfo(TheTriple, LargeCodeModel);
1057  break;
1058  case MCContext::IsGOFF:
1059  initGOFFMCObjectFileInfo(TheTriple);
1060  break;
1061  case MCContext::IsSPIRV:
1062  initSPIRVMCObjectFileInfo(TheTriple);
1063  break;
1064  case MCContext::IsWasm:
1065  initWasmMCObjectFileInfo(TheTriple);
1066  break;
1067  case MCContext::IsXCOFF:
1068  initXCOFFMCObjectFileInfo(TheTriple);
1069  break;
1071  initDXContainerObjectFileInfo(TheTriple);
1072  break;
1073  }
1074 }
1075 
1076 MCSection *MCObjectFileInfo::getDwarfComdatSection(const char *Name,
1077  uint64_t Hash) const {
1078  switch (Ctx->getTargetTriple().getObjectFormat()) {
1079  case Triple::ELF:
1080  return Ctx->getELFSection(Name, ELF::SHT_PROGBITS, ELF::SHF_GROUP, 0,
1081  utostr(Hash), /*IsComdat=*/true);
1082  case Triple::Wasm:
1083  return Ctx->getWasmSection(Name, SectionKind::getMetadata(), 0,
1084  utostr(Hash), MCContext::GenericSectionID);
1085  case Triple::MachO:
1086  case Triple::COFF:
1087  case Triple::GOFF:
1088  case Triple::SPIRV:
1089  case Triple::XCOFF:
1090  case Triple::DXContainer:
1092  report_fatal_error("Cannot get DWARF comdat section for this object file "
1093  "format: not implemented.");
1094  break;
1095  }
1096  llvm_unreachable("Unknown ObjectFormatType");
1097 }
1098 
1099 MCSection *
1101  if ((Ctx->getObjectFileType() != MCContext::IsELF) ||
1102  Ctx->getTargetTriple().isPS4())
1103  return StackSizesSection;
1104 
1105  const MCSectionELF &ElfSec = static_cast<const MCSectionELF &>(TextSec);
1106  unsigned Flags = ELF::SHF_LINK_ORDER;
1107  StringRef GroupName;
1108  if (const MCSymbol *Group = ElfSec.getGroup()) {
1109  GroupName = Group->getName();
1110  Flags |= ELF::SHF_GROUP;
1111  }
1112 
1113  return Ctx->getELFSection(".stack_sizes", ELF::SHT_PROGBITS, Flags, 0,
1114  GroupName, true, ElfSec.getUniqueID(),
1115  cast<MCSymbolELF>(TextSec.getBeginSymbol()));
1116 }
1117 
1118 MCSection *
1120  if (Ctx->getObjectFileType() != MCContext::IsELF)
1121  return nullptr;
1122 
1123  const MCSectionELF &ElfSec = static_cast<const MCSectionELF &>(TextSec);
1124  unsigned Flags = ELF::SHF_LINK_ORDER;
1125  StringRef GroupName;
1126  if (const MCSymbol *Group = ElfSec.getGroup()) {
1127  GroupName = Group->getName();
1128  Flags |= ELF::SHF_GROUP;
1129  }
1130 
1131  // Use the text section's begin symbol and unique ID to create a separate
1132  // .llvm_bb_addr_map section associated with every unique text section.
1133  return Ctx->getELFSection(".llvm_bb_addr_map", ELF::SHT_LLVM_BB_ADDR_MAP,
1134  Flags, 0, GroupName, true, ElfSec.getUniqueID(),
1135  cast<MCSymbolELF>(TextSec.getBeginSymbol()));
1136 }
1137 
1138 MCSection *
1140  if (Ctx->getObjectFileType() != MCContext::IsELF)
1141  return nullptr;
1142 
1143  const MCSectionELF &ElfSec = static_cast<const MCSectionELF &>(TextSec);
1144  unsigned Flags = ELF::SHF_LINK_ORDER | ELF::SHF_ALLOC;
1145  StringRef GroupName;
1146  if (const MCSymbol *Group = ElfSec.getGroup()) {
1147  GroupName = Group->getName();
1148  Flags |= ELF::SHF_GROUP;
1149  }
1150 
1151  return Ctx->getELFSection(".kcfi_traps", ELF::SHT_PROGBITS, Flags, 0,
1152  GroupName,
1153  /*IsComdat=*/true, ElfSec.getUniqueID(),
1154  cast<MCSymbolELF>(TextSec.getBeginSymbol()));
1155 }
1156 
1157 MCSection *
1159  if (Ctx->getObjectFileType() == MCContext::IsELF) {
1160  const auto &ElfSec = static_cast<const MCSectionELF &>(TextSec);
1161  // Create a separate section for probes that comes with a comdat function.
1162  if (const MCSymbol *Group = ElfSec.getGroup()) {
1163  auto *S = static_cast<MCSectionELF *>(PseudoProbeSection);
1164  auto Flags = S->getFlags() | ELF::SHF_GROUP;
1165  return Ctx->getELFSection(S->getName(), S->getType(), Flags,
1166  S->getEntrySize(), Group->getName(),
1167  /*IsComdat=*/true);
1168  }
1169  }
1170  return PseudoProbeSection;
1171 }
1172 
1173 MCSection *
1175  if (Ctx->getObjectFileType() == MCContext::IsELF) {
1176  // Create a separate comdat group for each function's descriptor in order
1177  // for the linker to deduplicate. The duplication, must be from different
1178  // tranlation unit, can come from:
1179  // 1. Inline functions defined in header files;
1180  // 2. ThinLTO imported funcions;
1181  // 3. Weak-linkage definitions.
1182  // Use a concatenation of the section name and the function name as the
1183  // group name so that descriptor-only groups won't be folded with groups of
1184  // code.
1185  if (Ctx->getTargetTriple().supportsCOMDAT() && !FuncName.empty()) {
1186  auto *S = static_cast<MCSectionELF *>(PseudoProbeDescSection);
1187  auto Flags = S->getFlags() | ELF::SHF_GROUP;
1188  return Ctx->getELFSection(S->getName(), S->getType(), Flags,
1189  S->getEntrySize(),
1190  S->getName() + "_" + FuncName,
1191  /*IsComdat=*/true);
1192  }
1193  }
1194  return PseudoProbeDescSection;
1195 }
1196 
1198  return LLVMStatsSection;
1199 }
1200 
1202  const MCSection *TextSec) const {
1203  if (Ctx->getObjectFileType() != MCContext::IsELF)
1204  return nullptr;
1205 
1206  // SHF_WRITE for relocations, and let user post-process data in-place.
1207  unsigned Flags = ELF::SHF_WRITE | ELF::SHF_ALLOC | ELF::SHF_LINK_ORDER;
1208 
1209  if (!TextSec)
1210  TextSec = getTextSection();
1211 
1212  StringRef GroupName;
1213  const auto &ElfSec = static_cast<const MCSectionELF &>(*TextSec);
1214  if (const MCSymbol *Group = ElfSec.getGroup()) {
1215  GroupName = Group->getName();
1216  Flags |= ELF::SHF_GROUP;
1217  }
1218  return Ctx->getELFSection(Name, ELF::SHT_PROGBITS, Flags, 0, GroupName, true,
1219  ElfSec.getUniqueID(),
1220  cast<MCSymbolELF>(TextSec->getBeginSymbol()));
1221 }
llvm::MachO::S_CSTRING_LITERALS
@ S_CSTRING_LITERALS
S_CSTRING_LITERALS - Section with literal C strings.
Definition: MachO.h:131
llvm::MCObjectFileInfo::TextCoalSection
MCSection * TextCoalSection
Definition: MCObjectFileInfo.h:203
llvm::Triple::DXContainer
@ DXContainer
Definition: Triple.h:282
llvm::MCObjectFileInfo::DwarfLineDWOSection
MCSection * DwarfLineDWOSection
Definition: MCObjectFileInfo.h:110
llvm::MCObjectFileInfo::CompactUnwindSection
MCSection * CompactUnwindSection
If exception handling is supported by the target and the target can support a compact representation ...
Definition: MCObjectFileInfo.h:74
llvm::MCObjectFileInfo::ConstTextCoalSection
MCSection * ConstTextCoalSection
Definition: MCObjectFileInfo.h:204
llvm::MCObjectFileInfo::DwarfSwiftASTSection
MCSection * DwarfSwiftASTSection
Definition: MCObjectFileInfo.h:138
llvm::MCSectionELF::getUniqueID
unsigned getUniqueID() const
Definition: MCSectionELF.h:87
llvm::Triple::Wasm
@ Wasm
Definition: Triple.h:287
llvm::MCContext::GenericSectionID
@ GenericSectionID
Pass this value as the UniqueID during section creation to get the generic section with the given nam...
Definition: MCContext.h:547
llvm::MCObjectFileInfo::~MCObjectFileInfo
virtual ~MCObjectFileInfo()
llvm::MCObjectFileInfo::CompactUnwindDwarfEHFrameOnly
unsigned CompactUnwindDwarfEHFrameOnly
Compact unwind encoding indicating that we should emit only an EH frame.
Definition: MCObjectFileInfo.h:50
llvm::SectionKind::getReadOnlyWithRel
static SectionKind getReadOnlyWithRel()
Definition: SectionKind.h:214
llvm::SectionKind::getMergeable2ByteCString
static SectionKind getMergeable2ByteCString()
Definition: SectionKind.h:196
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
llvm::MCObjectFileInfo::DwarfAbbrevDWOSection
MCSection * DwarfAbbrevDWOSection
Definition: MCObjectFileInfo.h:108
llvm::MCObjectFileInfo::XDataSection
MCSection * XDataSection
Definition: MCObjectFileInfo.h:221
llvm::XCOFF::SSUBTYP_DWARNGE
@ SSUBTYP_DWARNGE
DWARF aranges section.
Definition: XCOFF.h:146
llvm::COFF::IMAGE_SCN_CNT_UNINITIALIZED_DATA
@ IMAGE_SCN_CNT_UNINITIALIZED_DATA
Definition: COFF.h:290
llvm::MCSymbol
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
Definition: MCSymbol.h:41
llvm::MCObjectFileInfo::DwarfRnglistsDWOSection
MCSection * DwarfRnglistsDWOSection
The DWARF v5 range and location list sections for fission.
Definition: MCObjectFileInfo.h:125
llvm::ELF::SHF_EXECINSTR
@ SHF_EXECINSTR
Definition: ELF.h:1067
llvm::dwarf::DW_EH_PE_sdata4
@ DW_EH_PE_sdata4
Definition: Dwarf.h:445
llvm::Triple::bpfeb
@ bpfeb
Definition: Triple.h:57
llvm::MCObjectFileInfo::OmitDwarfIfHaveCompactUnwind
bool OmitDwarfIfHaveCompactUnwind
OmitDwarfIfHaveCompactUnwind - True if the target object file supports having some functions with com...
Definition: MCObjectFileInfo.h:41
llvm::SectionKind::getMetadata
static SectionKind getMetadata()
Definition: SectionKind.h:188
llvm::MCObjectFileInfo::EightByteConstantSection
MCSection * EightByteConstantSection
Definition: MCObjectFileInfo.h:211
llvm::Triple::isPS4
bool isPS4() const
Tests whether the target is the PS4 platform.
Definition: Triple.h:706
llvm::ELF::SHT_MIPS_DWARF
@ SHT_MIPS_DWARF
Definition: ELF.h:1044
llvm::MCObjectFileInfo::MergeableConst16Section
MCSection * MergeableConst16Section
Definition: MCObjectFileInfo.h:186
llvm::MCObjectFileInfo::ReadOnlySection
MCSection * ReadOnlySection
Section that is readonly and can contain arbitrary initialized data.
Definition: MCObjectFileInfo.h:65
T
llvm::MCContext
Context object for machine code objects.
Definition: MCContext.h:76
llvm::MCObjectFileInfo::NonLazySymbolPointerSection
MCSection * NonLazySymbolPointerSection
Definition: MCObjectFileInfo.h:214
llvm::MCObjectFileInfo::DwarfLineSection
MCSection * DwarfLineSection
Definition: MCObjectFileInfo.h:80
llvm::XCOFF::SSUBTYP_DWLOC
@ SSUBTYP_DWLOC
DWARF loc section.
Definition: XCOFF.h:150
llvm::MCContext::IsSPIRV
@ IsSPIRV
Definition: MCContext.h:87
llvm::MCObjectFileInfo::GFIDsSection
MCSection * GFIDsSection
Definition: MCObjectFileInfo.h:224
llvm::MCConstantExpr::create
static const MCConstantExpr * create(int64_t Value, MCContext &Ctx, bool PrintInHex=false, unsigned SizeInBytes=0)
Definition: MCExpr.cpp:194
llvm::MCObjectFileInfo::DwarfLocDWOSection
MCSection * DwarfLocDWOSection
Definition: MCObjectFileInfo.h:111
MCSectionELF.h
llvm::MCSection::getBeginSymbol
MCSymbol * getBeginSymbol()
Definition: MCSection.h:129
llvm::MCObjectFileInfo::SixteenByteConstantSection
MCSection * SixteenByteConstantSection
Definition: MCObjectFileInfo.h:212
llvm::MCObjectFileInfo::DwarfAddrSection
MCSection * DwarfAddrSection
Definition: MCObjectFileInfo.h:118
llvm::MCObjectFileInfo::FourByteConstantSection
MCSection * FourByteConstantSection
Definition: MCObjectFileInfo.h:210
llvm::COFF::IMAGE_SCN_MEM_DISCARDABLE
@ IMAGE_SCN_MEM_DISCARDABLE
Definition: COFF.h:316
llvm::MachO::S_ATTR_NO_TOC
@ S_ATTR_NO_TOC
S_ATTR_NO_TOC - Section contains coalesced symbols that are not to be in a ranlib table of contents.
Definition: MachO.h:195
MCSectionCOFF.h
llvm::XCOFF::SSUBTYP_DWPBTYP
@ SSUBTYP_DWPBTYP
DWARF pubtypes section.
Definition: XCOFF.h:145
llvm::XCOFF::SSUBTYP_DWLINE
@ SSUBTYP_DWLINE
DWARF line section.
Definition: XCOFF.h:143
llvm::XCOFF::XMC_PR
@ XMC_PR
Program Code.
Definition: XCOFF.h:92
llvm::MCObjectFileInfo::ThreadLocalPointerSection
MCSection * ThreadLocalPointerSection
Definition: MCObjectFileInfo.h:215
llvm::MCSectionELF::getGroup
const MCSymbolELF * getGroup() const
Definition: MCSectionELF.h:76
llvm::dwarf::DW_EH_PE_sdata8
@ DW_EH_PE_sdata8
Definition: Dwarf.h:446
llvm::MCObjectFileInfo::DataBSSSection
MCSection * DataBSSSection
Definition: MCObjectFileInfo.h:209
llvm::Triple
Triple - Helper class for working with autoconf configuration names.
Definition: Triple.h:44
COFF.h
llvm::MCObjectFileInfo::getPseudoProbeSection
MCSection * getPseudoProbeSection(const MCSection &TextSec) const
Definition: MCObjectFileInfo.cpp:1158
llvm::ELF::SHT_NOBITS
@ SHT_NOBITS
Definition: ELF.h:987
MCObjectFileInfo.h
llvm::MCObjectFileInfo::DwarfAbbrevSection
MCSection * DwarfAbbrevSection
Definition: MCObjectFileInfo.h:78
llvm::MCObjectFileInfo::AddrSigSection
MCSection * AddrSigSection
Definition: MCObjectFileInfo.h:216
llvm::Triple::x86_64
@ x86_64
Definition: Triple.h:86
llvm::MCObjectFileInfo::DwarfDebugNamesSection
MCSection * DwarfDebugNamesSection
Accelerator table sections.
Definition: MCObjectFileInfo.h:99
llvm::SectionKind::getMergeableConst16
static SectionKind getMergeableConst16()
Definition: SectionKind.h:204
llvm::ELF::SHF_MERGE
@ SHF_MERGE
Definition: ELF.h:1070
llvm::EmitDwarfUnwindType::NoCompactUnwind
@ NoCompactUnwind
PIC
PassInstrumentationCallbacks PIC
Definition: PassBuilderBindings.cpp:55
llvm::MCObjectFileInfo::DwarfTUIndexSection
MCSection * DwarfTUIndexSection
Definition: MCObjectFileInfo.h:130
llvm::Triple::SPIRV
@ SPIRV
Definition: Triple.h:286
llvm::Triple::ppc
@ ppc
Definition: Triple.h:69
llvm::MachO::S_ATTR_STRIP_STATIC_SYMS
@ S_ATTR_STRIP_STATIC_SYMS
S_ATTR_STRIP_STATIC_SYMS - Ok to strip static symbols in this section in files with the MY_DYLDLINK f...
Definition: MachO.h:198
llvm::MCAsmInfo::getCodePointerSize
unsigned getCodePointerSize() const
Get the code pointer size in bytes.
Definition: MCAsmInfo.h:548
llvm::XCOFF::SSUBTYP_DWRNGES
@ SSUBTYP_DWRNGES
DWARF ranges section.
Definition: XCOFF.h:149
llvm::Triple::hexagon
@ hexagon
Definition: Triple.h:60
llvm::Triple::XCOFF
@ XCOFF
Definition: Triple.h:288
llvm::ELF::SHT_PROGBITS
@ SHT_PROGBITS
Definition: ELF.h:980
llvm::MachO::S_ZEROFILL
@ S_ZEROFILL
S_ZEROFILL - Zero fill on demand section.
Definition: MachO.h:129
llvm::MCObjectFileInfo::ConstDataCoalSection
MCSection * ConstDataCoalSection
Definition: MCObjectFileInfo.h:207
llvm::MCObjectFileInfo::LazySymbolPointerSection
MCSection * LazySymbolPointerSection
Definition: MCObjectFileInfo.h:213
llvm::ELF::SHF_TLS
@ SHF_TLS
Definition: ELF.h:1089
llvm::MCObjectFileInfo::TLSExtraDataSection
MCSection * TLSExtraDataSection
Extra TLS Variable Data section.
Definition: MCObjectFileInfo.h:148
llvm::MCContext::IsMachO
@ IsMachO
Definition: MCContext.h:83
llvm::MCSectionELF
This represents a section on linux, lots of unix variants and some bare metal systems.
Definition: MCSectionELF.h:26
llvm::GOFF::SK_PPA1
@ SK_PPA1
Definition: GOFF.h:26
llvm::MCObjectFileInfo::DwarfPubNamesSection
MCSection * DwarfPubNamesSection
Definition: MCObjectFileInfo.h:93
llvm::MCObjectFileInfo::DwarfPubTypesSection
MCSection * DwarfPubTypesSection
Definition: MCObjectFileInfo.h:83
llvm::MachO::S_8BYTE_LITERALS
@ S_8BYTE_LITERALS
S_8BYTE_LITERALS - Section with 8 byte literals.
Definition: MachO.h:135
llvm::MCObjectFileInfo::SXDataSection
MCSection * SXDataSection
Definition: MCObjectFileInfo.h:222
llvm::Triple::aarch64_32
@ aarch64_32
Definition: Triple.h:53
llvm::XCOFF::SSUBTYP_DWMAC
@ SSUBTYP_DWMAC
DWARF macinfo section.
Definition: XCOFF.h:152
llvm::Triple::mips64
@ mips64
Definition: Triple.h:66
llvm::MCObjectFileInfo::DwarfFrameSection
MCSection * DwarfFrameSection
Definition: MCObjectFileInfo.h:82
llvm::MCObjectFileInfo::DwarfARangesSection
MCSection * DwarfARangesSection
Definition: MCObjectFileInfo.h:87
llvm::MCObjectFileInfo::DwarfStrSection
MCSection * DwarfStrSection
Definition: MCObjectFileInfo.h:85
llvm::XCOFF::CsectProperties
Definition: XCOFF.h:458
llvm::MCContext::getMachOSection
MCSectionMachO * getMachOSection(StringRef Segment, StringRef Section, unsigned TypeAndAttributes, unsigned Reserved2, SectionKind K, const char *BeginSymName=nullptr)
Return the MCSection for the specified mach-o section.
Definition: MCContext.cpp:435
llvm::MCObjectFileInfo::ReadOnly8Section
MCSection * ReadOnly8Section
Definition: MCObjectFileInfo.h:233
llvm::SectionKind::getReadOnly
static SectionKind getReadOnly()
Definition: SectionKind.h:192
llvm::MCContext::IsWasm
@ IsWasm
Definition: MCContext.h:88
llvm::EmitDwarfUnwindType::Default
@ Default
llvm::MCObjectFileInfo::LSDASection
MCSection * LSDASection
If exception handling is supported by the target, this is the section the Language Specific Data Area...
Definition: MCObjectFileInfo.h:69
llvm::COFF::IMAGE_SCN_LNK_INFO
@ IMAGE_SCN_LNK_INFO
Definition: COFF.h:292
llvm::MCContext::IsXCOFF
@ IsXCOFF
Definition: MCContext.h:89
llvm::COFF::IMAGE_SCN_CNT_INITIALIZED_DATA
@ IMAGE_SCN_CNT_INITIALIZED_DATA
Definition: COFF.h:289
llvm::MachO::S_COALESCED
@ S_COALESCED
S_COALESCED - Section contains symbols that are to be coalesced.
Definition: MachO.h:152
llvm::SectionKind::getThreadBSS
static SectionKind getThreadBSS()
Definition: SectionKind.h:206
llvm::MCContext::emitDwarfUnwindInfo
EmitDwarfUnwindType emitDwarfUnwindInfo() const
Definition: MCContext.cpp:924
ELF.h
llvm::XCOFF::XMC_RO
@ XMC_RO
Read Only Constant.
Definition: XCOFF.h:93
llvm::Triple::ArchType
ArchType
Definition: Triple.h:46
llvm::MCContext::getSPIRVSection
MCSectionSPIRV * getSPIRVSection()
Definition: MCContext.cpp:842
llvm::XCOFF::SSUBTYP_DWPBNMS
@ SSUBTYP_DWPBNMS
DWARF pubnames section.
Definition: XCOFF.h:144
llvm::COFF::IMAGE_SCN_LNK_REMOVE
@ IMAGE_SCN_LNK_REMOVE
Definition: COFF.h:293
llvm::MCObjectFileInfo::SupportsCompactUnwindWithoutEHFrame
bool SupportsCompactUnwindWithoutEHFrame
True if the target object file supports emitting a compact unwind section without an associated EH fr...
Definition: MCObjectFileInfo.h:36
llvm::MCObjectFileInfo::PPA1Section
MCSection * PPA1Section
Definition: MCObjectFileInfo.h:229
llvm::MCContext::getGOFFSection
MCSectionGOFF * getGOFFSection(StringRef Section, SectionKind Kind, MCSection *Parent, const MCExpr *SubsectionId)
Definition: MCContext.cpp:645
llvm::MCObjectFileInfo::MergeableConst8Section
MCSection * MergeableConst8Section
Definition: MCObjectFileInfo.h:185
llvm::Triple::mips64el
@ mips64el
Definition: Triple.h:67
MCContext.h
llvm::COFF::IMAGE_SCN_MEM_READ
@ IMAGE_SCN_MEM_READ
Definition: COFF.h:321
MCSectionMachO.h
llvm::MCObjectFileInfo::getKCFITrapSection
MCSection * getKCFITrapSection(const MCSection &TextSec) const
Definition: MCObjectFileInfo.cpp:1139
llvm::MCObjectFileInfo::FDECFIEncoding
unsigned FDECFIEncoding
FDE CFI encoding.
Definition: MCObjectFileInfo.h:47
llvm::MCObjectFileInfo::TLSThreadInitSection
const MCSection * TLSThreadInitSection
Section for thread local data initialization functions.
Definition: MCObjectFileInfo.h:199
llvm::MCContext::getELFSection
MCSectionELF * getELFSection(const Twine &Section, unsigned Type, unsigned Flags)
Definition: MCContext.h:564
llvm::MachO::S_ATTR_DEBUG
@ S_ATTR_DEBUG
S_ATTR_DEBUG - A debug section.
Definition: MachO.h:207
llvm::SectionKind::getBSS
static SectionKind getBSS()
Definition: SectionKind.h:209
llvm::MCObjectFileInfo::DwarfAccelTypesSection
MCSection * DwarfAccelTypesSection
Definition: MCObjectFileInfo.h:103
llvm::Triple::supportsCOMDAT
bool supportsCOMDAT() const
Tests whether the target supports comdat.
Definition: Triple.h:942
llvm::MCContext::getObjectFileType
Environment getObjectFileType() const
Definition: MCContext.h:430
llvm::MCObjectFileInfo::DwarfStrOffDWOSection
MCSection * DwarfStrOffDWOSection
Definition: MCObjectFileInfo.h:112
llvm::Triple::ppc64
@ ppc64
Definition: Triple.h:71
llvm::MCObjectFileInfo::getStackSizesSection
MCSection * getStackSizesSection(const MCSection &TextSec) const
Definition: MCObjectFileInfo.cpp:1100
llvm::MCObjectFileInfo::GLJMPSection
MCSection * GLJMPSection
Definition: MCObjectFileInfo.h:226
llvm::MCObjectFileInfo::DwarfStrDWOSection
MCSection * DwarfStrDWOSection
Definition: MCObjectFileInfo.h:109
llvm::Triple::getObjectFormat
ObjectFormatType getObjectFormat() const
Get the object format for this triple.
Definition: Triple.h:380
llvm::report_fatal_error
void report_fatal_error(Error Err, bool gen_crash_diag=true)
Report a serious error, calling any installed error handler.
Definition: Error.cpp:145
llvm::MCContext::getXCOFFSection
MCSectionXCOFF * getXCOFFSection(StringRef Section, SectionKind K, Optional< XCOFF::CsectProperties > CsectProp=None, bool MultiSymbolsAllowed=false, const char *BeginSymName=nullptr, Optional< XCOFF::DwarfSectionSubtypeFlags > DwarfSubtypeFlags=None)
Definition: MCContext.cpp:770
llvm::MCContext::getDXContainerSection
MCSectionDXContainer * getDXContainerSection(StringRef Section, SectionKind K)
Get the section for the provided Section name.
Definition: MCContext.cpp:857
llvm::MCObjectFileInfo::PDataSection
MCSection * PDataSection
Definition: MCObjectFileInfo.h:220
llvm::MCContext::IsDXContainer
@ IsDXContainer
Definition: MCContext.h:90
llvm::ELF::SHF_EXCLUDE
@ SHF_EXCLUDE
Definition: ELF.h:1098
Align
uint64_t Align
Definition: ELFObjHandler.cpp:82
llvm::SectionKind::getText
static SectionKind getText()
Definition: SectionKind.h:190
llvm::XCOFF::XTY_SD
@ XTY_SD
Csect definition for initialized storage.
Definition: XCOFF.h:229
llvm::XCOFF::SSUBTYP_DWABREV
@ SSUBTYP_DWABREV
DWARF abbrev section.
Definition: XCOFF.h:147
llvm::MCObjectFileInfo::TLSDataSection
MCSection * TLSDataSection
Section directive for Thread Local data. ELF, MachO, COFF, and Wasm.
Definition: MCObjectFileInfo.h:151
llvm::MCObjectFileInfo::DwarfRangesSection
MCSection * DwarfRangesSection
Definition: MCObjectFileInfo.h:88
llvm::MCObjectFileInfo::getTextSection
MCSection * getTextSection() const
Definition: MCObjectFileInfo.h:263
llvm::MachO::S_LAZY_SYMBOL_POINTERS
@ S_LAZY_SYMBOL_POINTERS
S_LAZY_SYMBOL_POINTERS - Section with lazy symbol pointers.
Definition: MachO.h:141
llvm::Triple::GOFF
@ GOFF
Definition: Triple.h:284
MCSectionXCOFF.h
llvm::MCContext::getTargetTriple
const Triple & getTargetTriple() const
Definition: MCContext.h:435
llvm::MCObjectFileInfo::ConstDataSection
MCSection * ConstDataSection
Definition: MCObjectFileInfo.h:205
llvm::MCContext::getWasmSection
MCSectionWasm * getWasmSection(const Twine &Section, SectionKind K, unsigned Flags=0)
Definition: MCContext.h:645
llvm::MCObjectFileInfo::DwarfLoclistsSection
MCSection * DwarfLoclistsSection
The DWARF v5 locations list section.
Definition: MCObjectFileInfo.h:122
llvm::MCObjectFileInfo::getPseudoProbeDescSection
MCSection * getPseudoProbeDescSection(StringRef FuncName) const
Definition: MCObjectFileInfo.cpp:1174
llvm::MCObjectFileInfo::COFFGlobalTypeHashesSection
MCSection * COFFGlobalTypeHashesSection
Definition: MCObjectFileInfo.h:142
llvm::MachO::S_NON_LAZY_SYMBOL_POINTERS
@ S_NON_LAZY_SYMBOL_POINTERS
S_NON_LAZY_SYMBOL_POINTERS - Section with non-lazy symbol pointers.
Definition: MachO.h:139
llvm::StringRef::empty
constexpr bool empty() const
empty - Check if the string is empty.
Definition: StringRef.h:134
llvm::Triple::ppc64le
@ ppc64le
Definition: Triple.h:72
llvm::MachO::S_ATTR_LIVE_SUPPORT
@ S_ATTR_LIVE_SUPPORT
S_ATTR_LIVE_SUPPORT - Blocks are live if they reference live blocks.
Definition: MachO.h:202
llvm::ELF::SHF_LINK_ORDER
@ SHF_LINK_ORDER
Definition: ELF.h:1079
llvm::SectionKind::getMergeable1ByteCString
static SectionKind getMergeable1ByteCString()
Definition: SectionKind.h:193
llvm::Triple::ELF
@ ELF
Definition: Triple.h:283
llvm::MachO::S_ATTR_PURE_INSTRUCTIONS
@ S_ATTR_PURE_INSTRUCTIONS
S_ATTR_PURE_INSTRUCTIONS - Section contains only true machine instructions.
Definition: MachO.h:192
llvm::MCObjectFileInfo::FaultMapSection
MCSection * FaultMapSection
FaultMap section.
Definition: MCObjectFileInfo.h:162
llvm::MCObjectFileInfo::DwarfMacinfoSection
MCSection * DwarfMacinfoSection
Definition: MCObjectFileInfo.h:89
uint64_t
llvm::dwarf::DW_EH_PE_pcrel
@ DW_EH_PE_pcrel
Definition: Dwarf.h:448
llvm::MCContext::getAsmInfo
const MCAsmInfo * getAsmInfo() const
Definition: MCContext.h:447
llvm::MCObjectFileInfo::UStringSection
MCSection * UStringSection
Definition: MCObjectFileInfo.h:202
llvm::MCContext::IsELF
@ IsELF
Definition: MCContext.h:84
llvm::MCObjectFileInfo::CStringSection
MCSection * CStringSection
Definition: MCObjectFileInfo.h:201
llvm::ELF::SHF_STRINGS
@ SHF_STRINGS
Definition: ELF.h:1073
llvm::MCObjectFileInfo::DwarfMacroSection
MCSection * DwarfMacroSection
Definition: MCObjectFileInfo.h:90
llvm::XCOFF::XMC_TL
@ XMC_TL
Initialized thread-local variable.
Definition: XCOFF.h:113
MCSectionGOFF.h
StringExtras.h
llvm::MCObjectFileInfo::SupportsWeakOmittedEHFrame
bool SupportsWeakOmittedEHFrame
True if target object file supports a weak_definition of constant 0 for an omitted EH frame.
Definition: MCObjectFileInfo.h:32
llvm::ELF::SHF_ALLOC
@ SHF_ALLOC
Definition: ELF.h:1064
llvm::ELF::SHT_LLVM_BB_ADDR_MAP
@ SHT_LLVM_BB_ADDR_MAP
Definition: ELF.h:1017
llvm::MCObjectFileInfo::DwarfLineStrSection
MCSection * DwarfLineStrSection
Definition: MCObjectFileInfo.h:81
llvm::MachO::S_4BYTE_LITERALS
@ S_4BYTE_LITERALS
S_4BYTE_LITERALS - Section with 4 byte literals.
Definition: MachO.h:133
llvm::MCObjectFileInfo::DwarfLocSection
MCSection * DwarfLocSection
Definition: MCObjectFileInfo.h:86
llvm::MachO::S_THREAD_LOCAL_VARIABLES
@ S_THREAD_LOCAL_VARIABLES
S_THREAD_LOCAL_VARIABLES - Section with thread local variable structure data.
Definition: MachO.h:172
llvm::MachO::S_THREAD_LOCAL_REGULAR
@ S_THREAD_LOCAL_REGULAR
S_THREAD_LOCAL_REGULAR - Thread local data section.
Definition: MachO.h:167
llvm::MCContext::IsGOFF
@ IsGOFF
Definition: MCContext.h:85
llvm::Triple::bpfel
@ bpfel
Definition: Triple.h:56
llvm::SectionKind::getThreadData
static SectionKind getThreadData()
Definition: SectionKind.h:207
llvm::MCObjectFileInfo::initMCObjectFileInfo
void initMCObjectFileInfo(MCContext &MCCtx, bool PIC, bool LargeCodeModel=false)
Definition: MCObjectFileInfo.cpp:1026
llvm::ELF::SHT_X86_64_UNWIND
@ SHT_X86_64_UNWIND
Definition: ELF.h:1040
llvm::MCObjectFileInfo::PseudoProbeDescSection
MCSection * PseudoProbeDescSection
Definition: MCObjectFileInfo.h:177
MCSection.h
llvm::MCObjectFileInfo::DwarfInfoSection
MCSection * DwarfInfoSection
Definition: MCObjectFileInfo.h:79
Triple.h
llvm::MCObjectFileInfo::DwarfMacroDWOSection
MCSection * DwarfMacroDWOSection
Definition: MCObjectFileInfo.h:114
llvm::Triple::arm
@ arm
Definition: Triple.h:49
MCAsmInfo.h
llvm::MCObjectFileInfo::DwarfLoclistsDWOSection
MCSection * DwarfLoclistsDWOSection
Definition: MCObjectFileInfo.h:126
llvm::Triple::aarch64_be
@ aarch64_be
Definition: Triple.h:52
llvm::StringRef
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:50
llvm_unreachable
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
Definition: ErrorHandling.h:143
llvm::MCObjectFileInfo::getBBAddrMapSection
MCSection * getBBAddrMapSection(const MCSection &TextSec) const
Definition: MCObjectFileInfo.cpp:1119
llvm::Triple::thumb
@ thumb
Definition: Triple.h:83
llvm::MCSection
Instances of this class represent a uniqued identifier for a section in the current translation unit.
Definition: MCSection.h:39
MCSectionDXContainer.h
S
add sub stmia L5 ldr r0 bl L_printf $stub Instead of a and a wouldn t it be better to do three moves *Return an aggregate type is even return S
Definition: README.txt:210
llvm::MCContext::getCOFFSection
MCSectionCOFF * getCOFFSection(StringRef Section, unsigned Characteristics, SectionKind Kind, StringRef COMDATSymName, int Selection, unsigned UniqueID=GenericSectionID, const char *BeginSymName=nullptr)
Definition: MCContext.cpp:657
llvm::MachO::S_16BYTE_LITERALS
@ S_16BYTE_LITERALS
S_16BYTE_LITERALS - Section with only 16 byte literals.
Definition: MachO.h:160
llvm::MCContext::IsCOFF
@ IsCOFF
Definition: MCContext.h:86
llvm::MCObjectFileInfo::RemarksSection
MCSection * RemarksSection
Remarks section.
Definition: MCObjectFileInfo.h:165
llvm::MCObjectFileInfo::DwarfInfoDWOSection
MCSection * DwarfInfoDWOSection
Definition: MCObjectFileInfo.h:106
llvm::MCObjectFileInfo::GEHContSection
MCSection * GEHContSection
Definition: MCObjectFileInfo.h:223
llvm::MCObjectFileInfo::DrectveSection
MCSection * DrectveSection
COFF specific sections.
Definition: MCObjectFileInfo.h:219
llvm::MCObjectFileInfo::DwarfStrOffSection
MCSection * DwarfStrOffSection
The DWARF v5 string offset and address table sections.
Definition: MCObjectFileInfo.h:117
llvm::XCOFF::SSUBTYP_DWINFO
@ SSUBTYP_DWINFO
DWARF info section.
Definition: XCOFF.h:142
llvm::MCSection::setAlignment
void setAlignment(Align Value)
Definition: MCSection.h:141
llvm::MCObjectFileInfo::DataRelROSection
MCSection * DataRelROSection
Definition: MCObjectFileInfo.h:183
llvm::SectionKind::getData
static SectionKind getData()
Definition: SectionKind.h:213
llvm::MCObjectFileInfo::TOCBaseSection
MCSection * TOCBaseSection
Definition: MCObjectFileInfo.h:232
llvm::dwarf::DW_EH_PE_absptr
@ DW_EH_PE_absptr
Definition: Dwarf.h:437
llvm::SectionKind::getMergeableConst8
static SectionKind getMergeableConst8()
Definition: SectionKind.h:203
llvm::None
constexpr std::nullopt_t None
Definition: None.h:27
llvm::MCObjectFileInfo::DwarfRnglistsSection
MCSection * DwarfRnglistsSection
The DWARF v5 range list section.
Definition: MCObjectFileInfo.h:120
llvm::MCContext::getSwift5ReflectionSegmentName
const StringRef & getSwift5ReflectionSegmentName() const
Definition: MCContext.h:432
llvm::MCObjectFileInfo::DataSection
MCSection * DataSection
Section directive for standard data.
Definition: MCObjectFileInfo.h:56
llvm::MCObjectFileInfo::DwarfAccelNamespaceSection
MCSection * DwarfAccelNamespaceSection
Definition: MCObjectFileInfo.h:102
llvm::MachO::S_THREAD_LOCAL_VARIABLE_POINTERS
@ S_THREAD_LOCAL_VARIABLE_POINTERS
S_THREAD_LOCAL_VARIABLE_POINTERS - Section with pointers to thread local structures.
Definition: MachO.h:175
llvm::MCObjectFileInfo::MergeableConst32Section
MCSection * MergeableConst32Section
Definition: MCObjectFileInfo.h:187
llvm::MCObjectFileInfo::GIATsSection
MCSection * GIATsSection
Definition: MCObjectFileInfo.h:225
llvm::COFF::IMAGE_SCN_CNT_CODE
@ IMAGE_SCN_CNT_CODE
Definition: COFF.h:288
llvm::MCObjectFileInfo::DwarfDebugInlineSection
const MCSection * DwarfDebugInlineSection
Definition: MCObjectFileInfo.h:84
Casting.h
llvm::Triple::MachO
@ MachO
Definition: Triple.h:285
llvm::MCObjectFileInfo::EHFrameSection
MCSection * EHFrameSection
EH frame section.
Definition: MCObjectFileInfo.h:170
llvm::ELF::SHF_WRITE
@ SHF_WRITE
Definition: ELF.h:1061
llvm::Triple::mipsel
@ mipsel
Definition: Triple.h:65
llvm::XCOFF::XMC_TC0
@ XMC_TC0
TOC Anchor for TOC Addressability.
Definition: XCOFF.h:105
llvm::MCObjectFileInfo::COFFDebugTypesSection
MCSection * COFFDebugTypesSection
Definition: MCObjectFileInfo.h:141
llvm::MCObjectFileInfo::getLLVMStatsSection
MCSection * getLLVMStatsSection() const
Definition: MCObjectFileInfo.cpp:1197
Wasm.h
llvm::MCObjectFileInfo::LLVMStatsSection
MCSection * LLVMStatsSection
Definition: MCObjectFileInfo.h:180
llvm::MachO::S_THREAD_LOCAL_ZEROFILL
@ S_THREAD_LOCAL_ZEROFILL
S_THREAD_LOCAL_ZEROFILL - Thread local zerofill section.
Definition: MachO.h:169
llvm::MCObjectFileInfo::DataCoalSection
MCSection * DataCoalSection
Definition: MCObjectFileInfo.h:206
llvm::CodeModel::Large
@ Large
Definition: CodeGen.h:28
llvm::MCObjectFileInfo::DwarfAccelObjCSection
MCSection * DwarfAccelObjCSection
Definition: MCObjectFileInfo.h:101
llvm::Triple::COFF
@ COFF
Definition: Triple.h:281
llvm::MCObjectFileInfo::DwarfGnuPubTypesSection
MCSection * DwarfGnuPubTypesSection
Section for newer gnu pubtypes.
Definition: MCObjectFileInfo.h:135
llvm::XCOFF::XMC_RW
@ XMC_RW
Read Write Data.
Definition: XCOFF.h:104
llvm::MCObjectFileInfo::DwarfTypesDWOSection
MCSection * DwarfTypesDWOSection
Definition: MCObjectFileInfo.h:107
llvm::SectionKind::getMergeableConst4
static SectionKind getMergeableConst4()
Definition: SectionKind.h:202
llvm::MCObjectFileInfo::DwarfAccelNamesSection
MCSection * DwarfAccelNamesSection
Definition: MCObjectFileInfo.h:100
llvm::MCObjectFileInfo::ReadOnly16Section
MCSection * ReadOnly16Section
Definition: MCObjectFileInfo.h:234
llvm::MCObjectFileInfo::BSSSection
MCSection * BSSSection
Section that is default initialized to zero.
Definition: MCObjectFileInfo.h:59
llvm::MCObjectFileInfo::MergeableConst4Section
MCSection * MergeableConst4Section
Definition: MCObjectFileInfo.h:184
llvm::MCObjectFileInfo::TLSBSSSection
MCSection * TLSBSSSection
Section directive for Thread Local uninitialized data.
Definition: MCObjectFileInfo.h:156
llvm::MCObjectFileInfo::StackSizesSection
MCSection * StackSizesSection
Section containing metadata on function stack sizes.
Definition: MCObjectFileInfo.h:173
llvm::ELF::SHF_GROUP
@ SHF_GROUP
Definition: ELF.h:1086
llvm::MCObjectFileInfo::DwarfGnuPubNamesSection
MCSection * DwarfGnuPubNamesSection
Section for newer gnu pubnames.
Definition: MCObjectFileInfo.h:133
llvm::MCObjectFileInfo::DwarfMacinfoDWOSection
MCSection * DwarfMacinfoDWOSection
Definition: MCObjectFileInfo.h:113
llvm::XCOFF::SSUBTYP_DWFRAME
@ SSUBTYP_DWFRAME
DWARF frame section.
Definition: XCOFF.h:151
MCSectionSPIRV.h
llvm::COFF::IMAGE_SCN_MEM_EXECUTE
@ IMAGE_SCN_MEM_EXECUTE
Definition: COFF.h:320
llvm::MachO::S_THREAD_LOCAL_INIT_FUNCTION_POINTERS
@ S_THREAD_LOCAL_INIT_FUNCTION_POINTERS
S_THREAD_LOCAL_INIT_FUNCTION_POINTERS - Section with thread local variable initialization pointers to...
Definition: MachO.h:178
llvm::MCObjectFileInfo::StackMapSection
MCSection * StackMapSection
StackMap section.
Definition: MCObjectFileInfo.h:159
llvm::MCObjectFileInfo::PseudoProbeSection
MCSection * PseudoProbeSection
Section for pseudo probe information used by AutoFDO.
Definition: MCObjectFileInfo.h:176
llvm::COFF::IMAGE_SCN_MEM_16BIT
@ IMAGE_SCN_MEM_16BIT
Definition: COFF.h:297
llvm::EmitDwarfUnwindType::Always
@ Always
llvm::MCObjectFileInfo::DataCommonSection
MCSection * DataCommonSection
Definition: MCObjectFileInfo.h:208
llvm::MCObjectFileInfo::DwarfCUIndexSection
MCSection * DwarfCUIndexSection
Definition: MCObjectFileInfo.h:129
useCompactUnwind
static bool useCompactUnwind(const Triple &T)
Definition: MCObjectFileInfo.cpp:30
llvm::MCObjectFileInfo::TLSTLVSection
MCSection * TLSTLVSection
Section for thread local structure information.
Definition: MCObjectFileInfo.h:195
llvm::XCOFF::SSUBTYP_DWSTR
@ SSUBTYP_DWSTR
DWARF str section.
Definition: XCOFF.h:148
llvm::COFF::SectionCharacteristics
SectionCharacteristics
Definition: COFF.h:283
llvm::MCObjectFileInfo::COFFDebugSymbolsSection
MCSection * COFFDebugSymbolsSection
Definition: MCObjectFileInfo.h:140
llvm::wasm::WASM_SEG_FLAG_STRINGS
@ WASM_SEG_FLAG_STRINGS
Definition: Wasm.h:392
llvm::Triple::mips
@ mips
Definition: Triple.h:64
llvm::Triple::aarch64
@ aarch64
Definition: Triple.h:51
llvm::COFF::IMAGE_SCN_MEM_WRITE
@ IMAGE_SCN_MEM_WRITE
Definition: COFF.h:322
llvm::MCObjectFileInfo::getPCSection
MCSection * getPCSection(StringRef Name, const MCSection *TextSec) const
Definition: MCObjectFileInfo.cpp:1201
MCSectionWasm.h
llvm::MCObjectFileInfo::TextSection
MCSection * TextSection
Section directive for standard text.
Definition: MCObjectFileInfo.h:53
llvm::Triple::UnknownObjectFormat
@ UnknownObjectFormat
Definition: Triple.h:279