class GlobalAlias

Declaration

class GlobalAlias : public GlobalValue, public ilist_node { /* full declaration omitted */ };

Description

This is an important base class in LLVM. It provides the common facilities of all constant values in an LLVM program. A constant is a value that is immutable at runtime. Functions are constants because their address is immutable. Same with global variables. All constants share the capabilities provided in this class. All constants can have a null value. They can have an operand list. Constants can be simple (integer and floating point values), complex (arrays and structures), or expression based (computations yielding a constant value composed of only certain operators and other constant values). Note that Constants are immutable (once created they never change) and are fully shared by structural equivalence. This means that two structurally equivalent constants will always have the same address. Constants are created on demand as needed and never deleted: thus clients don't have to worry about the lifetime of the objects. LLVM Constant Representation

Declared at: llvm/include/llvm/IR/GlobalAlias.h:28

Inherits from: GlobalValue, ilist_node

Member Variables

Inherited from GlobalValue:

protected ValueType
protected Linkage
protected Visibility
protected UnnamedAddrVal
protected DllStorageClass
protected ThreadLocal
protected HasLLVMReservedName
protected IsDSOLocal
protected HasPartition
protected HasSanitizerMetadata
protected IntID = (unsigned int)0U
protected Parent = nullptr
protected static GlobalValueSubClassDataBits = 15

Inherited from Value:

protected SubclassOptionalData
protected NumUserOperands
protected IsUsedByMD
protected HasName
protected HasMetadata
protected HasHungOffUses
protected HasDescriptor
public static MaxAlignmentExponent = 32
public static MaximumAlignment = 1ULL << MaxAlignmentExponent

Method Overview

  • public GlobalAlias(const llvm::GlobalAlias &)
  • private GlobalAlias(llvm::Type * Ty, unsigned int AddressSpace, llvm::GlobalValue::LinkageTypes Linkage, const llvm::Twine & Name, llvm::Constant * Aliasee, llvm::Module * Parent)
  • public static bool classof(const llvm::Value * V)
  • public void copyAttributesFrom(const llvm::GlobalAlias * Src)
  • public static llvm::GlobalAlias * create(llvm::Type * Ty, unsigned int AddressSpace, llvm::GlobalValue::LinkageTypes Linkage, const llvm::Twine & Name, llvm::Module * Parent)
  • public static llvm::GlobalAlias * create(llvm::Type * Ty, unsigned int AddressSpace, llvm::GlobalValue::LinkageTypes Linkage, const llvm::Twine & Name, llvm::GlobalValue * Aliasee)
  • public static llvm::GlobalAlias * create(llvm::GlobalValue::LinkageTypes Linkage, const llvm::Twine & Name, llvm::GlobalValue * Aliasee)
  • public static llvm::GlobalAlias * create(const llvm::Twine & Name, llvm::GlobalValue * Aliasee)
  • public static llvm::GlobalAlias * create(llvm::Type * Ty, unsigned int AddressSpace, llvm::GlobalValue::LinkageTypes Linkage, const llvm::Twine & Name, llvm::Constant * Aliasee, llvm::Module * Parent)
  • public void eraseFromParent()
  • public const llvm::Constant * getAliasee() const
  • public llvm::Constant * getAliasee()
  • public const llvm::GlobalObject * getAliaseeObject() const
  • public llvm::GlobalObject * getAliaseeObject()
  • public static bool isValidLinkage(llvm::GlobalValue::LinkageTypes L)
  • public void removeFromParent()
  • public void setAliasee(llvm::Constant * Aliasee)

Inherited from GlobalValue:

Inherited from Constant:

Inherited from User:

Inherited from Value:

Methods

GlobalAlias(const llvm::GlobalAlias&)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:35

Parameters

const llvm::GlobalAlias&

GlobalAlias(
    llvm::Type* Ty,
    unsigned int AddressSpace,
    llvm::GlobalValue::LinkageTypes Linkage,
    const llvm::Twine& Name,
    llvm::Constant* Aliasee,
    llvm::Module* Parent)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:31

Parameters

llvm::Type* Ty
unsigned int AddressSpace
llvm::GlobalValue::LinkageTypes Linkage
const llvm::Twine& Name
llvm::Constant* Aliasee
llvm::Module* Parent

static bool classof(const llvm::Value* V)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:101

Parameters

const llvm::Value* V

void copyAttributesFrom(
    const llvm::GlobalAlias* Src)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:68

Parameters

const llvm::GlobalAlias* Src

static llvm::GlobalAlias* create(
    llvm::Type* Ty,
    unsigned int AddressSpace,
    llvm::GlobalValue::LinkageTypes Linkage,
    const llvm::Twine& Name,
    llvm::Module* Parent)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:45

Parameters

llvm::Type* Ty
unsigned int AddressSpace
llvm::GlobalValue::LinkageTypes Linkage
const llvm::Twine& Name
llvm::Module* Parent

static llvm::GlobalAlias* create(
    llvm::Type* Ty,
    unsigned int AddressSpace,
    llvm::GlobalValue::LinkageTypes Linkage,
    const llvm::Twine& Name,
    llvm::GlobalValue* Aliasee)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:50

Parameters

llvm::Type* Ty
unsigned int AddressSpace
llvm::GlobalValue::LinkageTypes Linkage
const llvm::Twine& Name
llvm::GlobalValue* Aliasee

static llvm::GlobalAlias* create(
    llvm::GlobalValue::LinkageTypes Linkage,
    const llvm::Twine& Name,
    llvm::GlobalValue* Aliasee)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:55

Parameters

llvm::GlobalValue::LinkageTypes Linkage
const llvm::Twine& Name
llvm::GlobalValue* Aliasee

static llvm::GlobalAlias* create(
    const llvm::Twine& Name,
    llvm::GlobalValue* Aliasee)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:59

Parameters

const llvm::Twine& Name
llvm::GlobalValue* Aliasee

static llvm::GlobalAlias* create(
    llvm::Type* Ty,
    unsigned int AddressSpace,
    llvm::GlobalValue::LinkageTypes Linkage,
    const llvm::Twine& Name,
    llvm::Constant* Aliasee,
    llvm::Module* Parent)

Description

If a parent module is specified, the alias is automatically inserted into the end of the specified module's alias list.

Declared at: llvm/include/llvm/IR/GlobalAlias.h:40

Parameters

llvm::Type* Ty
unsigned int AddressSpace
llvm::GlobalValue::LinkageTypes Linkage
const llvm::Twine& Name
llvm::Constant* Aliasee
llvm::Module* Parent

void eraseFromParent()

Description

eraseFromParent - This method unlinks 'this' from the containing module and deletes it.

Declared at: llvm/include/llvm/IR/GlobalAlias.h:80

const llvm::Constant* getAliasee() const

Declared at: llvm/include/llvm/IR/GlobalAlias.h:84

llvm::Constant* getAliasee()

Declared at: llvm/include/llvm/IR/GlobalAlias.h:87

const llvm::GlobalObject* getAliaseeObject() const

Declared at: llvm/include/llvm/IR/GlobalAlias.h:89

llvm::GlobalObject* getAliaseeObject()

Declared at: llvm/include/llvm/IR/GlobalAlias.h:90

static bool isValidLinkage(
    llvm::GlobalValue::LinkageTypes L)

Declared at: llvm/include/llvm/IR/GlobalAlias.h:95

Parameters

llvm::GlobalValue::LinkageTypes L

void removeFromParent()

Description

removeFromParent - This method unlinks 'this' from the containing module, but does not delete it.

Declared at: llvm/include/llvm/IR/GlobalAlias.h:75

void setAliasee(llvm::Constant* Aliasee)

Description

These methods retrieve and set alias target.

Declared at: llvm/include/llvm/IR/GlobalAlias.h:83

Parameters

llvm::Constant* Aliasee