20 #ifndef LLVM_IR_GLOBALVARIABLE_H
21 #define LLVM_IR_GLOBALVARIABLE_H
32 template<
typename ValueSubClass,
typename ItemParentClass>
33 class SymbolTableListTraits;
41 void setParent(
Module *parent);
43 bool isConstantGlobal : 1;
44 unsigned threadLocalMode : 3;
47 bool isExternallyInitializedConstant : 1;
54 void *operator new(
size_t s) {
55 return User::operator
new(s, 1);
140 return static_cast<Constant*
>(Op<0>().
get());
144 return static_cast<Constant*
>(Op<0>().
get());
169 return isExternallyInitializedConstant;
172 isExternallyInitializedConstant = Val;
ThreadLocalMode getThreadLocalMode() const
static bool classof(const Value *V)
The main container class for the LLVM Intermediate Representation.
const Constant * getInitializer() const
void setInitializer(Constant *InitVal)
bool isThreadLocal() const
If the value is "Thread Local", its value isn't shared by the threads.
bool hasUniqueInitializer() const
#define DEFINE_TRANSPARENT_OPERAND_ACCESSORS(CLASS, VALUECLASS)
Macro for generating out-of-class operand accessor definitions.
void setThreadLocal(bool Val)
bool hasDefinitiveInitializer() const
bool isWeakForLinker() const
bool isExternallyInitialized() const
LLVM Constant Representation.
virtual void replaceUsesOfWithOnConstant(Value *From, Value *To, Use *U)
void setExternallyInitialized(bool Val)
virtual void eraseFromParent()
unsigned getValueID() const
void setConstant(bool Val)
virtual void removeFromParent()
void setThreadLocalMode(ThreadLocalMode Val)
DECLARE_TRANSPARENT_OPERAND_ACCESSORS(Value)
Provide fast operand accessors.
void copyAttributesFrom(const GlobalValue *Src)
#define LLVM_DELETED_FUNCTION
bool hasInitializer() const
LinkageTypes
An enumeration for the kinds of linkage for global values.
bool isDeclaration() const
LLVM Value Representation.
bool mayBeOverridden() const
Constant * getInitializer()