LLVM: llvm::SwitchCG Namespace Reference (original) (raw)

Classes
struct BitTestBlock
struct BitTestCase
struct CaseBits
struct CaseBlock
This structure is used to communicate between SelectionDAGBuilder and SDISel for the code generation of additional basic blocks needed by multi-case switch statements. More...
struct CaseCluster
A cluster of case labels. More...
struct JumpTable
struct JumpTableHeader
class SwitchLowering
struct SwitchWorkListItem
Typedefs
using CaseClusterVector = std::vector<CaseCluster>
using CaseClusterIt = CaseClusterVector::iterator
using CaseBitsVector = std::vector<CaseBits>
using JumpTableBlock = std::pair<JumpTableHeader, JumpTable>
using BitTestInfo = SmallVector<BitTestCase, 3>
using SwitchWorkList = SmallVector<SwitchWorkListItem, 4>
Enumerations
enum CaseClusterKind { CC_Range, CC_JumpTable, CC_BitTests }
Functions
void sortAndRangeify (CaseClusterVector &Clusters)
Sort Clusters and merge adjacent cases.
uint64_t getJumpTableRange (const CaseClusterVector &Clusters, unsigned First, unsigned Last)
Return the range of values within a range.
uint64_t getJumpTableNumCases (const SmallVectorImpl< unsigned > &TotalCases, unsigned First, unsigned Last)
Return the number of cases within a range.

BitTestInfo

CaseBitsVector

CaseClusterIt

using llvm::SwitchCG::CaseClusterIt = CaseClusterVector::iterator

CaseClusterVector

JumpTableBlock

SwitchWorkList

CaseClusterKind

Enumerator
CC_Range A cluster of adjacent case labels with the same destination, or just one case.
CC_JumpTable A cluster of cases suitable for jump table lowering.
CC_BitTests A cluster of cases suitable for bit test lowering.

Definition at line 31 of file SwitchLoweringUtils.h.

getJumpTableNumCases()

getJumpTableRange()

sortAndRangeify()

void llvm::SwitchCG::sortAndRangeify ( CaseClusterVector & Clusters )