8#ifndef LLVM_MC_MCSYMBOLMACHO_H
9#define LLVM_MC_MCSYMBOLMACHO_H
20 SF_DescFlagsMask = 0xFFFF,
23 SF_ReferenceTypeMask = 0x0007,
24 SF_ReferenceTypeUndefinedNonLazy = 0x0000,
25 SF_ReferenceTypeUndefinedLazy = 0x0001,
26 SF_ReferenceTypeDefined = 0x0002,
27 SF_ReferenceTypePrivateDefined = 0x0003,
28 SF_ReferenceTypePrivateUndefinedNonLazy = 0x0004,
29 SF_ReferenceTypePrivateUndefinedLazy = 0x0005,
32 SF_ThumbFunc = 0x0008,
33 SF_NoDeadStrip = 0x0020,
34 SF_WeakReference = 0x0040,
35 SF_WeakDefinition = 0x0080,
36 SF_SymbolResolver = 0x0100,
41 SF_CommonAlignmentMask = 0xF0FF,
42 SF_CommonAlignmentShift = 8
60 SF_ReferenceTypeUndefinedLazy);
77 return getFlags() & SF_WeakReference;
84 return getFlags() & SF_WeakDefinition;
91 return getFlags() & SF_SymbolResolver;
111 "Invalid .desc value!");
135 Align Alignment = *MaybeAlignment;
136 unsigned Log2Size =
Log2(Alignment);
143 (Log2Size << SF_CommonAlignmentShift);
147 if (EncodeAsAltEntry)
148 Flags |= SF_AltEntry;
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
bool isPrivateExtern() const
void setWeakReference() const
bool isNoDeadStrip() const
uint16_t getEncodedFlags(bool EncodeAsAltEntry) const
Get the encoded value of the flags as they will be emitted in to the MachO binary.
void setWeakDefinition() const
void setSymbolResolver() const
void clearReferenceType() const
MCSymbolMachO(const MCSymbolTableEntry *Name, bool isTemporary)
bool isWeakReference() const
void setReferenceTypeUndefinedLazy(bool Value) const
void setPrivateExtern(bool Value)
bool isSymbolLinkerVisible() const
void setDesc(unsigned Value) const
static bool classof(const MCSymbol *S)
bool isSymbolResolver() const
void setNoDeadStrip() const
bool isWeakDefinition() const
void setThumbFunc() const
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
bool isCommon() const
Is this a 'common' symbol.
void modifyFlags(uint32_t Value, uint32_t Mask) const
Modify the flags via a mask.
unsigned IsPrivateExtern
Mach-O specific: This symbol is private extern.
StringRef getName() const
getName - Get the symbol name.
void setFlags(uint32_t Value) const
Set the (implementation defined) symbol flags.
uint32_t getFlags() const
Get the (implementation defined) symbol flags.
MaybeAlign getCommonAlignment() const
Return the alignment of a 'common' symbol.
bool isTemporary() const
isTemporary - Check if this is an assembler temporary symbol.
const MCExpr * Value
If non-null, the value for a variable symbol.
bool isUsedInReloc() const
StringMapEntry - This is used to represent one value that is inserted into a StringMap.
Twine - A lightweight data structure for efficiently representing the concatenation of temporary valu...
LLVM Value Representation.
This is an optimization pass for GlobalISel generic memory operations.
void report_fatal_error(Error Err, bool gen_crash_diag=true)
Report a serious error, calling any installed error handler.
unsigned Log2(Align A)
Returns the log2 of the alignment.
This struct is a compact representation of a valid (non-zero power of two) alignment.
uint64_t value() const
This is a hole in the type system and should not be abused.
This struct is a compact representation of a valid (power of two) or undefined (0) alignment.