LLVM  3.7.0
Public Types | Public Member Functions | List of all members
llvm::orc::JITSymbol Class Reference

Represents a symbol in the JIT. More...

#include <JITSymbol.h>

Inheritance diagram for llvm::orc::JITSymbol:
[legend]
Collaboration diagram for llvm::orc::JITSymbol:
[legend]

Public Types

typedef std::function
< TargetAddress()> 
GetAddressFtor
 

Public Member Functions

 JITSymbol (std::nullptr_t)
 Create a 'null' symbol that represents failure to find a symbol definition. More...
 
 JITSymbol (TargetAddress Addr, JITSymbolFlags Flags)
 Create a symbol for a definition with a known address. More...
 
 JITSymbol (GetAddressFtor GetAddress, JITSymbolFlags Flags)
 Create a symbol for a definition that doesn't have a known address yet. More...
 
 operator bool () const
 Returns true if the symbol exists, false otherwise. More...
 
TargetAddress getAddress ()
 Get the address of the symbol in the target address space. More...
 
- Public Member Functions inherited from llvm::JITSymbolBase
 JITSymbolBase (JITSymbolFlags Flags)
 
JITSymbolFlags getFlags () const
 
bool isWeak () const
 
bool isExported () const
 

Additional Inherited Members

- Static Public Member Functions inherited from llvm::JITSymbolBase
static JITSymbolFlags flagsFromGlobalValue (const GlobalValue &GV)
 

Detailed Description

Represents a symbol in the JIT.

Definition at line 29 of file JITSymbol.h.

Member Typedef Documentation

Definition at line 32 of file JITSymbol.h.

Constructor & Destructor Documentation

llvm::orc::JITSymbol::JITSymbol ( std::nullptr_t  )
inline

Create a 'null' symbol that represents failure to find a symbol definition.

Definition at line 36 of file JITSymbol.h.

References llvm::None.

llvm::orc::JITSymbol::JITSymbol ( TargetAddress  Addr,
JITSymbolFlags  Flags 
)
inline

Create a symbol for a definition with a known address.

Definition at line 40 of file JITSymbol.h.

llvm::orc::JITSymbol::JITSymbol ( GetAddressFtor  GetAddress,
JITSymbolFlags  Flags 
)
inline

Create a symbol for a definition that doesn't have a known address yet.

Parameters
GetAddressA functor to materialize a definition (fixing the address) on demand.

This constructor allows a JIT layer to provide a reference to a symbol definition without actually materializing the definition up front. The user can materialize the definition at any time by calling the getAddress method.

Definition at line 52 of file JITSymbol.h.

Member Function Documentation

TargetAddress llvm::orc::JITSymbol::getAddress ( )
inline

Get the address of the symbol in the target address space.

Returns '0' if the symbol does not exist.

Definition at line 60 of file JITSymbol.h.

Referenced by llvm::orc::ObjectLinkingLayer< NotifyObjectLoadedT >::findSymbolIn().

llvm::orc::JITSymbol::operator bool ( ) const
inlineexplicit

Returns true if the symbol exists, false otherwise.

Definition at line 56 of file JITSymbol.h.


The documentation for this class was generated from the following file: