LLVM API Documentation

Public Types | Public Member Functions | Static Public Attributes
llvm::JumpInstrTableInfo Class Reference

#include <JumpInstrTableInfo.h>

Inheritance diagram for llvm::JumpInstrTableInfo:
Inheritance graph
[legend]
Collaboration diagram for llvm::JumpInstrTableInfo:
Collaboration graph
[legend]

List of all members.

Public Types

typedef std::pair< Function
*, Function * > 
JumpPair
typedef DenseMap< FunctionType
*, std::vector< JumpPair > > 
JumpTables

Public Member Functions

 JumpInstrTableInfo ()
virtual ~JumpInstrTableInfo ()
const char * getPassName () const override
void insertEntry (FunctionType *TableFunTy, Function *Target, Function *Jump)
 Inserts an entry in a table, adding the table if it doesn't exist.
const JumpTablesgetTables () const
 Gets the tables.

Static Public Attributes

static char ID

Detailed Description

This class stores information about jump-instruction tables created by the JumpInstrTables pass (in lib/CodeGen/JumpInstrTables.cpp). Each table is a map from a function type to a vector of pairs. The first element of each pair is the function that has the jumptable annotation. The second element is a function that was declared by JumpInstrTables and used to replace all address-taking sites for the original function.

The information in this pass is used in AsmPrinter (lib/CodeGen/AsmPrinter/AsmPrinter.cpp) to generate the required assembly for the jump-instruction tables.

Definition at line 36 of file JumpInstrTableInfo.h.


Member Typedef Documentation

Definition at line 46 of file JumpInstrTableInfo.h.

Definition at line 47 of file JumpInstrTableInfo.h.


Constructor & Destructor Documentation

Definition at line 35 of file JumpInstrTableInfo.cpp.


Member Function Documentation

const char* llvm::JumpInstrTableInfo::getPassName ( ) const [inline, override, virtual]

getPassName - Return a nice clean name for a pass. This usually implemented in terms of the name that is registered by one of the Registration templates, but can be overloaded directly.

Reimplemented from llvm::Pass.

Definition at line 42 of file JumpInstrTableInfo.h.

Gets the tables.

Definition at line 53 of file JumpInstrTableInfo.h.

Referenced by llvm::AsmPrinter::doFinalization().

void JumpInstrTableInfo::insertEntry ( FunctionType TableFunTy,
Function Target,
Function Jump 
)

Inserts an entry in a table, adding the table if it doesn't exist.

Definition at line 37 of file JumpInstrTableInfo.cpp.

Referenced by llvm::JumpInstrTables::insertEntry().


Member Data Documentation

Definition at line 38 of file JumpInstrTableInfo.h.


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