LLVM  14.0.0git
Classes | Public Types | Static Public Member Functions | List of all members
llvm::orc::IRSymbolMapper Class Reference

Maps IR global values to their linker symbol names / flags. More...

#include "llvm/ExecutionEngine/Orc/Mangling.h"

Classes

struct  ManglingOptions
 

Public Types

using SymbolNameToDefinitionMap = std::map< SymbolStringPtr, GlobalValue * >
 

Static Public Member Functions

static void add (ExecutionSession &ES, const ManglingOptions &MO, ArrayRef< GlobalValue * > GVs, SymbolFlagsMap &SymbolFlags, SymbolNameToDefinitionMap *SymbolToDefinition=nullptr)
 Add mangled symbols for the given GlobalValues to SymbolFlags. More...
 

Detailed Description

Maps IR global values to their linker symbol names / flags.

This utility can be used when adding new IR globals in the JIT.

Definition at line 39 of file Mangling.h.

Member Typedef Documentation

◆ SymbolNameToDefinitionMap

Definition at line 45 of file Mangling.h.

Member Function Documentation

◆ add()

void llvm::orc::IRSymbolMapper::add ( ExecutionSession ES,
const ManglingOptions MO,
ArrayRef< GlobalValue * >  GVs,
SymbolFlagsMap SymbolFlags,
SymbolNameToDefinitionMap SymbolToDefinition = nullptr 
)
static

Add mangled symbols for the given GlobalValues to SymbolFlags.

If a SymbolToDefinitionMap pointer is supplied then it will be populated with Name-to-GlobalValue* mappings. Note that this mapping is not necessarily one-to-one: thread-local GlobalValues, for example, may produce more than one symbol, in which case the map will contain duplicate values.

Definition at line 36 of file Mangling.cpp.

References assert(), llvm::ArrayRef< T >::empty(), llvm::orc::IRSymbolMapper::ManglingOptions::EmulatedTLS, llvm::JITSymbolFlags::fromGlobalValue(), G, and getParent().


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