16#define DEBUG_TYPE "jitlink"
29 return make_error<JITLinkError>(
"Object is not a relocatable MachO");
31 if (
auto Err = createNormalizedSections())
32 return std::move(Err);
34 if (
auto Err = createNormalizedSymbols())
35 return std::move(Err);
37 if (
auto Err = graphifyRegularSymbols())
38 return std::move(Err);
40 if (
auto Err = graphifySectionsWithCustomParsers())
41 return std::move(Err);
44 return std::move(Err);
64 "Custom parser for this section already exists");
65 CustomSectionParserFunctions[
SectionName] = std::move(Parser);
90 strcmp(NSec.
SegName,
"__DWARF") == 0);
114Section &MachOLinkGraphBuilder::getCommonSection() {
118 return *CommonSection;
121Error MachOLinkGraphBuilder::createNormalizedSections() {
127 for (
auto &SecRef : Obj.
sections()) {
128 NormalizedSection NSec;
134 const MachO::section_64 &Sec64 =
137 memcpy(&NSec.SectName, &Sec64.sectname, 16);
138 NSec.SectName[16] =
'\0';
139 memcpy(&NSec.SegName, Sec64.segname, 16);
140 NSec.SegName[16] =
'\0';
142 NSec.Address = orc::ExecutorAddr(Sec64.addr);
143 NSec.Size = Sec64.size;
144 NSec.Alignment = 1ULL << Sec64.align;
145 NSec.Flags = Sec64.flags;
146 DataOffset = Sec64.offset;
148 const MachO::section &Sec32 = Obj.
getSection(SecRef.getRawDataRefImpl());
150 memcpy(&NSec.SectName, &Sec32.sectname, 16);
151 NSec.SectName[16] =
'\0';
152 memcpy(&NSec.SegName, Sec32.segname, 16);
153 NSec.SegName[16] =
'\0';
155 NSec.Address = orc::ExecutorAddr(Sec32.addr);
156 NSec.Size = Sec32.size;
157 NSec.Alignment = 1ULL << Sec32.align;
158 NSec.Flags = Sec32.flags;
159 DataOffset = Sec32.offset;
163 dbgs() <<
" " << NSec.SegName <<
"," << NSec.SectName <<
": "
164 <<
formatv(
"{0:x16}", NSec.Address) <<
" -- "
165 <<
formatv(
"{0:x16}", NSec.Address + NSec.Size)
166 <<
", align: " << NSec.Alignment <<
", index: " << SecIndex
173 return make_error<JITLinkError>(
174 "Section data extends past end of file");
188 auto FullyQualifiedName =
189 G->allocateContent(StringRef(NSec.SegName) +
"," + NSec.SectName);
190 NSec.GraphSection = &G->createSection(
191 StringRef(FullyQualifiedName.data(), FullyQualifiedName.size()), Prot);
197 IndexToSection.insert(std::make_pair(SecIndex, std::move(NSec)));
200 std::vector<NormalizedSection *> Sections;
201 Sections.reserve(IndexToSection.size());
202 for (
auto &KV : IndexToSection)
203 Sections.push_back(&KV.second);
207 if (Sections.empty())
211 [](
const NormalizedSection *
LHS,
const NormalizedSection *
RHS) {
213 if (
LHS->Address !=
RHS->Address)
214 return LHS->Address <
RHS->Address;
215 return LHS->Size <
RHS->Size;
218 for (
unsigned I = 0,
E = Sections.size() - 1;
I !=
E; ++
I) {
219 auto &Cur = *Sections[
I];
220 auto &Next = *Sections[
I + 1];
221 if (Next.Address < Cur.Address + Cur.Size)
222 return make_error<JITLinkError>(
223 "Address range for section " +
224 formatv(
"\"{0}/{1}\" [ {2:x16} -- {3:x16} ] ", Cur.SegName,
225 Cur.SectName, Cur.Address, Cur.Address + Cur.Size) +
226 "overlaps section \"" + Next.SegName +
"/" + Next.SectName +
"\"" +
227 formatv(
"\"{0}/{1}\" [ {2:x16} -- {3:x16} ] ", Next.SegName,
228 Next.SectName, Next.Address, Next.Address + Next.Size));
234Error MachOLinkGraphBuilder::createNormalizedSymbols() {
237 for (
auto &SymRef : Obj.
symbols()) {
239 unsigned SymbolIndex = Obj.
getSymbolIndex(SymRef.getRawDataRefImpl());
247 const MachO::nlist_64 &NL64 =
249 Value = NL64.n_value;
255 const MachO::nlist &NL32 =
257 Value = NL32.n_value;
269 std::optional<StringRef>
Name;
271 if (
auto NameOrErr = SymRef.getName())
274 return NameOrErr.takeError();
276 return make_error<JITLinkError>(
"Symbol at index " +
278 " has no name (string table index 0), "
279 "but N_EXT bit is set");
284 dbgs() <<
"<anonymous symbol>";
287 dbgs() <<
": value = " <<
formatv(
"{0:x16}", Value)
288 <<
", type = " <<
formatv(
"{0:x2}", Type)
289 <<
", desc = " <<
formatv(
"{0:x4}",
Desc) <<
", sect = ";
291 dbgs() <<
static_cast<unsigned>(Sect - 1);
301 return NSec.takeError();
303 if (orc::ExecutorAddr(Value) < NSec->Address ||
304 orc::ExecutorAddr(Value) > NSec->Address + NSec->Size)
305 return make_error<JITLinkError>(
"Address " +
formatv(
"{0:x}", Value) +
306 " for symbol " + *
Name +
307 " does not fall within section");
309 if (!NSec->GraphSection) {
311 dbgs() <<
" Skipping: Symbol is in section " << NSec->SegName <<
"/"
313 <<
" which has no associated graph section.\n";
319 IndexToSymbol[SymbolIndex] =
327void MachOLinkGraphBuilder::addSectionStartSymAndBlock(
328 unsigned SecIndex, Section &GraphSec, orc::ExecutorAddr
Address,
332 Data ? G->createContentBlock(GraphSec, ArrayRef<char>(
Data,
Size),
334 : G->createZeroFillBlock(GraphSec,
Size,
Address, Alignment, 0);
335 auto &
Sym = G->addAnonymousSymbol(
B, 0,
Size,
false, IsLive);
336 auto SecI = IndexToSection.find(SecIndex);
337 assert(SecI != IndexToSection.end() &&
"SecIndex invalid");
338 auto &NSec = SecI->second;
339 assert(!NSec.CanonicalSymbols.count(
Sym.getAddress()) &&
340 "Anonymous block start symbol clashes with existing symbol address");
341 NSec.CanonicalSymbols[
Sym.getAddress()] = &
Sym;
344Error MachOLinkGraphBuilder::graphifyRegularSymbols() {
349 std::vector<std::vector<NormalizedSymbol *>> SecIndexToSymbols;
350 SecIndexToSymbols.resize(256);
354 for (
auto &KV : IndexToSymbol) {
355 auto &NSym = *KV.second;
361 return make_error<JITLinkError>(
"Anonymous common symbol at index " +
363 NSym.GraphSymbol = &G->addDefinedSymbol(
364 G->createZeroFillBlock(getCommonSection(),
372 return make_error<JITLinkError>(
"Anonymous external symbol at "
375 NSym.GraphSymbol = &G->addExternalSymbol(
381 return make_error<JITLinkError>(
"Anonymous absolute symbol at index " +
383 NSym.GraphSymbol = &G->addAbsoluteSymbol(
388 SecIndexToSymbols[NSym.Sect - 1].push_back(&NSym);
391 return make_error<JITLinkError>(
392 "Unupported N_PBUD symbol " +
393 (NSym.Name ? (
"\"" + *NSym.Name +
"\"") : Twine(
"<anon>")) +
394 " at index " + Twine(KV.first));
396 return make_error<JITLinkError>(
397 "Unupported N_INDR symbol " +
398 (NSym.Name ? (
"\"" + *NSym.Name +
"\"") : Twine(
"<anon>")) +
399 " at index " + Twine(KV.first));
401 return make_error<JITLinkError>(
402 "Unrecognized symbol type " + Twine(NSym.Type &
MachO::N_TYPE) +
404 (NSym.Name ? (
"\"" + *NSym.Name +
"\"") : Twine(
"<anon>")) +
405 " at index " + Twine(KV.first));
411 for (
auto &KV : IndexToSection) {
412 auto SecIndex = KV.first;
413 auto &NSec = KV.second;
415 if (!NSec.GraphSection) {
417 dbgs() <<
" " << NSec.SegName <<
"/" << NSec.SectName
418 <<
" has no graph section. Skipping.\n";
424 if (CustomSectionParserFunctions.
count(NSec.GraphSection->getName())) {
426 dbgs() <<
" Skipping section " << NSec.GraphSection->getName()
427 <<
" as it has a custom parser.\n";
432 if (
auto Err = graphifyCStringSection(
433 NSec, std::move(SecIndexToSymbols[SecIndex])))
438 dbgs() <<
" Graphifying regular section "
439 << NSec.GraphSection->getName() <<
"...\n";
445 auto &SecNSymStack = SecIndexToSymbols[SecIndex];
449 if (SecNSymStack.empty()) {
452 dbgs() <<
" Section non-empty, but contains no symbols. "
453 "Creating anonymous block to cover "
454 <<
formatv(
"{0:x16}", NSec.Address) <<
" -- "
455 <<
formatv(
"{0:x16}", NSec.Address + NSec.Size) <<
"\n";
457 addSectionStartSymAndBlock(SecIndex, *NSec.GraphSection, NSec.Address,
458 NSec.Data, NSec.Size, NSec.Alignment,
459 SectionIsNoDeadStrip);
462 dbgs() <<
" Section empty and contains no symbols. Skipping.\n";
471 const NormalizedSymbol *
RHS) {
472 if (
LHS->Value !=
RHS->Value)
473 return LHS->Value >
RHS->Value;
477 return static_cast<uint8_t
>(
LHS->S) <
static_cast<uint8_t
>(
RHS->S);
478 return LHS->Name <
RHS->Name;
482 if (!SecNSymStack.empty() &&
isAltEntry(*SecNSymStack.back()))
483 return make_error<JITLinkError>(
484 "First symbol in " + NSec.GraphSection->getName() +
" is alt-entry");
488 if (orc::ExecutorAddr(SecNSymStack.back()->Value) != NSec.Address) {
490 orc::ExecutorAddr(SecNSymStack.back()->Value) - NSec.Address;
492 dbgs() <<
" Section start not covered by symbol. "
493 <<
"Creating anonymous block to cover [ " << NSec.Address
494 <<
" -- " << (NSec.Address + AnonBlockSize) <<
" ]\n";
496 addSectionStartSymAndBlock(SecIndex, *NSec.GraphSection, NSec.Address,
497 NSec.Data, AnonBlockSize, NSec.Alignment,
498 SectionIsNoDeadStrip);
509 while (!SecNSymStack.empty()) {
510 SmallVector<NormalizedSymbol *, 8> BlockSyms;
514 BlockSyms.push_back(SecNSymStack.back());
515 SecNSymStack.pop_back();
516 while (!SecNSymStack.empty() &&
518 SecNSymStack.back()->Value == BlockSyms.back()->Value ||
519 !SubsectionsViaSymbols)) {
520 BlockSyms.push_back(SecNSymStack.back());
521 SecNSymStack.pop_back();
525 auto BlockStart = orc::ExecutorAddr(BlockSyms.front()->Value);
526 orc::ExecutorAddr BlockEnd =
527 SecNSymStack.empty() ? NSec.Address + NSec.Size
528 : orc::ExecutorAddr(SecNSymStack.back()->Value);
533 dbgs() <<
" Creating block for " <<
formatv(
"{0:x16}", BlockStart)
534 <<
" -- " <<
formatv(
"{0:x16}", BlockEnd) <<
": "
535 << NSec.GraphSection->getName() <<
" + "
536 <<
formatv(
"{0:x16}", BlockOffset) <<
" with "
537 << BlockSyms.size() <<
" symbol(s)...\n";
542 ? G->createContentBlock(
544 ArrayRef<char>(NSec.Data + BlockOffset,
BlockSize),
545 BlockStart, NSec.Alignment, BlockStart % NSec.Alignment)
546 : G->createZeroFillBlock(*NSec.GraphSection,
BlockSize,
547 BlockStart, NSec.Alignment,
548 BlockStart % NSec.Alignment);
550 std::optional<orc::ExecutorAddr> LastCanonicalAddr;
551 auto SymEnd = BlockEnd;
552 while (!BlockSyms.empty()) {
553 auto &NSym = *BlockSyms.back();
554 BlockSyms.pop_back();
559 auto &
Sym = createStandardGraphSymbol(
560 NSym,
B, SymEnd - orc::ExecutorAddr(NSym.Value), SectionIsText,
561 SymLive, LastCanonicalAddr != orc::ExecutorAddr(NSym.Value));
563 if (LastCanonicalAddr !=
Sym.getAddress()) {
564 if (LastCanonicalAddr)
565 SymEnd = *LastCanonicalAddr;
566 LastCanonicalAddr =
Sym.getAddress();
575Symbol &MachOLinkGraphBuilder::createStandardGraphSymbol(NormalizedSymbol &NSym,
576 Block &
B,
size_t Size,
582 dbgs() <<
" " <<
formatv(
"{0:x16}", NSym.Value) <<
" -- "
585 dbgs() <<
"<anonymous symbol>";
591 dbgs() <<
" [no-dead-strip]";
593 dbgs() <<
" [non-canonical]";
597 auto SymOffset = orc::ExecutorAddr(NSym.Value) -
B.getAddress();
600 ? G->addDefinedSymbol(
B, SymOffset, *NSym.Name,
Size, NSym.L, NSym.S,
601 IsText, IsNoDeadStrip)
602 : G->addAnonymousSymbol(
B, SymOffset,
Size, IsText, IsNoDeadStrip);
603 NSym.GraphSymbol = &
Sym;
611Error MachOLinkGraphBuilder::graphifySectionsWithCustomParsers() {
613 for (
auto &KV : IndexToSection) {
614 auto &NSec = KV.second;
617 if (!NSec.GraphSection)
620 auto HI = CustomSectionParserFunctions.
find(NSec.GraphSection->getName());
621 if (HI != CustomSectionParserFunctions.
end()) {
622 auto &Parse =
HI->second;
623 if (
auto Err = Parse(NSec))
631Error MachOLinkGraphBuilder::graphifyCStringSection(
632 NormalizedSection &NSec, std::vector<NormalizedSymbol *> NSyms) {
633 assert(NSec.GraphSection &&
"C string literal section missing graph section");
634 assert(NSec.Data &&
"C string literal section has no data");
637 dbgs() <<
" Graphifying C-string literal section "
638 << NSec.GraphSection->getName() <<
"\n";
641 if (NSec.Data[NSec.Size - 1] !=
'\0')
642 return make_error<JITLinkError>(
"C string literal section " +
643 NSec.GraphSection->getName() +
644 " does not end with null terminator");
648 [](
const NormalizedSymbol *
LHS,
const NormalizedSymbol *
RHS) {
649 if (
LHS->Value !=
RHS->Value)
650 return LHS->Value >
RHS->Value;
658 return *LHS->Name > *RHS->Name;
668 for (
size_t I = 0;
I != NSec.Size; ++
I) {
669 if (NSec.Data[
I] ==
'\0') {
672 auto &
B = G->createContentBlock(*NSec.GraphSection,
673 {NSec.Data + BlockStart, BlockSize},
674 NSec.Address + BlockStart, NSec.Alignment,
675 BlockStart % NSec.Alignment);
678 dbgs() <<
" Created block " <<
B.getRange()
679 <<
", align = " <<
B.getAlignment()
680 <<
", align-ofs = " <<
B.getAlignmentOffset() <<
" for \"";
681 for (
size_t J = 0; J != std::min(
B.getSize(),
size_t(16)); ++J)
682 switch (
B.getContent()[J]) {
684 case '\n':
dbgs() <<
"\\n";
break;
685 case '\t':
dbgs() <<
"\\t";
break;
686 default:
dbgs() <<
B.getContent()[J];
break;
688 if (
B.getSize() > 16)
695 orc::ExecutorAddr(NSyms.back()->Value) !=
B.getAddress()) {
696 auto &S = G->addAnonymousSymbol(
B, 0,
BlockSize,
false,
false);
697 setCanonicalSymbol(NSec, S);
699 dbgs() <<
" Adding symbol for c-string block " <<
B.getRange()
700 <<
": <anonymous symbol> at offset 0\n";
705 auto LastCanonicalAddr =
B.getAddress() +
BlockSize;
706 while (!NSyms.empty() && orc::ExecutorAddr(NSyms.back()->Value) <
708 auto &NSym = *NSyms.back();
709 size_t SymSize = (
B.getAddress() +
BlockSize) -
710 orc::ExecutorAddr(NSyms.back()->Value);
714 bool IsCanonical =
false;
715 if (LastCanonicalAddr != orc::ExecutorAddr(NSym.Value)) {
717 LastCanonicalAddr = orc::ExecutorAddr(NSym.Value);
720 auto &
Sym = createStandardGraphSymbol(NSym,
B, SymSize, SectionIsText,
721 SymLive, IsCanonical);
724 dbgs() <<
" Adding symbol for c-string block " <<
B.getRange()
726 << (
Sym.hasName() ?
Sym.getName() :
"<anonymous symbol>")
727 <<
" at offset " <<
formatv(
"{0:x}",
Sym.getOffset()) <<
"\n";
738 [](Block *
B) { return isCStringBlock(*B); }) &&
739 "All blocks in section should hold single c-strings");
745 auto *CUSec =
G.findSectionByName(CompactUnwindSectionName);
749 if (!
G.getTargetTriple().isOSBinFormatMachO())
750 return make_error<JITLinkError>(
751 "Error linking " +
G.getName() +
752 ": compact unwind splitting not supported on non-macho target " +
753 G.getTargetTriple().str());
755 unsigned CURecordSize = 0;
756 unsigned PersonalityEdgeOffset = 0;
757 unsigned LSDAEdgeOffset = 0;
758 switch (
G.getTargetTriple().getArch()) {
768 PersonalityEdgeOffset = 16;
772 return make_error<JITLinkError>(
773 "Error linking " +
G.getName() +
774 ": compact unwind splitting not supported on " +
775 G.getTargetTriple().getArchName());
778 std::vector<Block *> OriginalBlocks(CUSec->blocks().begin(),
779 CUSec->blocks().end());
781 dbgs() <<
"In " <<
G.getName() <<
" splitting compact unwind section "
782 << CompactUnwindSectionName <<
" containing "
783 << OriginalBlocks.
size() <<
" initial blocks...\n";
786 while (!OriginalBlocks.empty()) {
787 auto *
B = OriginalBlocks.back();
788 OriginalBlocks.pop_back();
790 if (
B->getSize() == 0) {
792 dbgs() <<
" Skipping empty block at "
793 <<
formatv(
"{0:x16}",
B->getAddress()) <<
"\n";
799 dbgs() <<
" Splitting block at " <<
formatv(
"{0:x16}",
B->getAddress())
800 <<
" into " << (
B->getSize() / CURecordSize)
801 <<
" compact unwind record(s)\n";
804 if (
B->getSize() % CURecordSize)
805 return make_error<JITLinkError>(
806 "Error splitting compact unwind record in " +
G.getName() +
807 ": block at " +
formatv(
"{0:x}",
B->getAddress()) +
" has size " +
809 " (not a multiple of CU record size of " +
810 formatv(
"{0:x}", CURecordSize) +
")");
812 unsigned NumBlocks =
B->getSize() / CURecordSize;
815 for (
unsigned I = 0;
I != NumBlocks; ++
I) {
816 auto &CURec =
G.splitBlock(*
B, CURecordSize, &
C);
817 bool AddedKeepAlive =
false;
819 for (
auto &
E : CURec.edges()) {
820 if (
E.getOffset() == 0) {
822 dbgs() <<
" Updating compact unwind record at "
823 <<
formatv(
"{0:x16}", CURec.getAddress()) <<
" to point to "
824 << (
E.getTarget().hasName() ?
E.getTarget().getName()
826 <<
" (at " <<
formatv(
"{0:x16}",
E.getTarget().getAddress())
830 if (
E.getTarget().isExternal())
831 return make_error<JITLinkError>(
832 "Error adding keep-alive edge for compact unwind record at " +
833 formatv(
"{0:x}", CURec.getAddress()) +
": target " +
834 E.getTarget().getName() +
" is an external symbol");
835 auto &TgtBlock =
E.getTarget().getBlock();
837 G.addAnonymousSymbol(CURec, 0, CURecordSize,
false,
false);
839 AddedKeepAlive =
true;
840 }
else if (
E.getOffset() != PersonalityEdgeOffset &&
841 E.getOffset() != LSDAEdgeOffset)
842 return make_error<JITLinkError>(
"Unexpected edge at offset " +
844 " in compact unwind record at " +
845 formatv(
"{0:x}", CURec.getAddress()));
849 return make_error<JITLinkError>(
850 "Error adding keep-alive edge for compact unwind record at " +
851 formatv(
"{0:x}", CURec.getAddress()) +
852 ": no outgoing target edge at offset 0");
static GCRegistry::Add< OcamlGC > B("ocaml", "ocaml 3.10-compatible GC")
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
static const char * CommonSectionName
static Expected< StringRef > getFileName(const DebugStringTableSubsectionRef &Strings, const DebugChecksumsSubsectionRef &Checksums, uint32_t FileID)
static uint64_t getPointerSize(const Value *V, const DataLayout &DL, const TargetLibraryInfo &TLI, const Function *F)
static const char * CommonSectionName
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
static const int BlockSize
Lightweight error class with error context and mandatory checking.
static ErrorSuccess success()
Create a success value.
Tagged union holding either a T or a Error.
iterator find(StringRef Key)
size_type count(StringRef Key) const
count - Return 1 if the element is in the map, 0 otherwise.
StringRef - Represent a constant reference to a string, i.e.
constexpr size_t size() const
size - Get the string size.
const char * data() const
data - Get a pointer to the start of the string (which may not be null terminated).
Manages the enabling and disabling of subtarget specific features.
Triple - Helper class for working with autoconf configuration names.
The instances of the Type class are immutable: once they are created, they are never changed.
Error operator()(LinkGraph &G)
std::optional< SmallVector< Symbol *, 8 > > SplitBlockCache
Cache type for the splitBlock function.
const char *(*)(Edge::Kind) GetEdgeKindNameFunction
static bool isDebugSection(const NormalizedSection &NSec)
void addCustomSectionParser(StringRef SectionName, SectionParserFunction Parse)
virtual ~MachOLinkGraphBuilder()
virtual Error addRelocations()=0
std::function< Error(NormalizedSection &S)> SectionParserFunction
static Scope getScope(StringRef Name, uint8_t Type)
static bool isZeroFillSection(const NormalizedSection &NSec)
Expected< std::unique_ptr< LinkGraph > > buildGraph()
NormalizedSection & getSectionByIndex(unsigned Index)
Index is zero-based (MachO section indexes are usually one-based) and assumed to be in-range.
MachOLinkGraphBuilder(const object::MachOObjectFile &Obj, Triple TT, SubtargetFeatures Features, LinkGraph::GetEdgeKindNameFunction GetEdgeKindName)
NormalizedSymbol & createNormalizedSymbol(ArgTs &&... Args)
Create a symbol.
static Linkage getLinkage(uint16_t Desc)
static bool isAltEntry(const NormalizedSymbol &NSym)
Expected< NormalizedSection & > findSectionByIndex(unsigned Index)
Try to get the section at the given index.
StringRef getData() const
bool isLittleEndian() const
const MachO::mach_header_64 & getHeader64() const
Expected< SectionRef > getSection(unsigned SectionIndex) const
uint64_t getSymbolIndex(DataRefImpl Symb) const
MachO::nlist getSymbolTableEntry(DataRefImpl DRI) const
MachO::section_64 getSection64(DataRefImpl DRI) const
bool isRelocatableObject() const override
True if this is a relocatable object (.o/.obj).
MachO::nlist_64 getSymbol64TableEntry(DataRefImpl DRI) const
bool is64Bit() const override
uint64_t getSectionIndex(DataRefImpl Sec) const override
section_iterator_range sections() const
symbol_iterator_range symbols() const
@ C
The default llvm calling convention, compatible with C.
@ S_GB_ZEROFILL
S_GB_ZEROFILL - Zero fill on demand section (that can be larger than 4 gigabytes).
@ S_THREAD_LOCAL_ZEROFILL
S_THREAD_LOCAL_ZEROFILL - Thread local zerofill section.
@ S_CSTRING_LITERALS
S_CSTRING_LITERALS - Section with literal C strings.
@ S_ZEROFILL
S_ZEROFILL - Zero fill on demand section.
@ MH_SUBSECTIONS_VIA_SYMBOLS
uint8_t GET_COMM_ALIGN(uint16_t n_desc)
@ S_ATTR_DEBUG
S_ATTR_DEBUG - A debug section.
@ S_ATTR_NO_DEAD_STRIP
S_ATTR_NO_DEAD_STRIP - No dead stripping.
@ S_ATTR_PURE_INSTRUCTIONS
S_ATTR_PURE_INSTRUCTIONS - Section contains only true machine instructions.
Linkage
Describes symbol linkage. This can be used to resolve definition clashes.
Scope
Defines the scope in which this symbol should be visible: Default – Visible in the public interface o...
Type
MessagePack types as defined in the standard, with the exception of Integer being divided into a sign...
MemProt
Describes Read/Write/Exec permissions for memory.
uint64_t ExecutorAddrDiff
@ NoAlloc
NoAlloc memory should not be allocated by the JITLinkMemoryManager at all.
NodeAddr< BlockNode * > Block
This is an optimization pass for GlobalISel generic memory operations.
auto formatv(const char *Fmt, Ts &&... Vals) -> formatv_object< decltype(std::make_tuple(detail::build_format_adapter(std::forward< Ts >(Vals))...))>
bool all_of(R &&range, UnaryPredicate P)
Provide wrappers to std::all_of which take ranges instead of having to pass begin/end explicitly.
void sort(IteratorTy Start, IteratorTy End)
raw_ostream & dbgs()
dbgs() - This returns a reference to a raw_ostream for debugging messages.
OutputIt move(R &&Range, OutputIt Out)
Provide wrappers to std::move which take ranges instead of having to pass begin/end explicitly.
Implement std::hash so that hash_code can be used in STL containers.
Description of the encoding of one expression Op.