LLVM
8.0.1
|
#include "llvm/Support/LowLevelTypeImpl.h"
Public Member Functions | |
LLT (bool isPointer, bool isVector, uint16_t NumElements, unsigned SizeInBits, unsigned AddressSpace) | |
LLT () | |
LLT (MVT VT) | |
bool | isValid () const |
bool | isScalar () const |
bool | isPointer () const |
bool | isVector () const |
uint16_t | getNumElements () const |
Returns the number of elements in a vector LLT. More... | |
unsigned | getSizeInBits () const |
Returns the total size of the type. Must only be called on sized types. More... | |
unsigned | getScalarSizeInBits () const |
unsigned | getAddressSpace () const |
LLT | getElementType () const |
Returns the vector's element type. Only valid for vector types. More... | |
void | print (raw_ostream &OS) const |
bool | operator== (const LLT &RHS) const |
bool | operator!= (const LLT &RHS) const |
Static Public Member Functions | |
static LLT | scalar (unsigned SizeInBits) |
Get a low-level scalar or aggregate "bag of bits". More... | |
static LLT | pointer (uint16_t AddressSpace, unsigned SizeInBits) |
Get a low-level pointer in the given address space (defaulting to 0). More... | |
static LLT | vector (uint16_t NumElements, unsigned ScalarSizeInBits) |
Get a low-level vector of some number of elements and element width. More... | |
static LLT | vector (uint16_t NumElements, LLT ScalarTy) |
Get a low-level vector of some number of elements and element type. More... | |
Friends | |
struct | DenseMapInfo< LLT > |
class | GISelInstProfileBuilder |
Definition at line 40 of file LowLevelTypeImpl.h.
|
inlineexplicit |
Definition at line 74 of file LowLevelTypeImpl.h.
|
inlineexplicit |
Definition at line 78 of file LowLevelTypeImpl.h.
|
explicit |
Definition at line 19 of file LowLevelType.cpp.
References assert(), llvm::MVT::getSizeInBits(), llvm::MVT::getVectorElementType(), llvm::MVT::getVectorNumElements(), llvm::MVT::isValid(), and llvm::MVT::isVector().
|
inline |
Definition at line 122 of file LowLevelTypeImpl.h.
References assert().
Referenced by llvm::LegalizerInfo::computeTables(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), getElementType(), print(), and vector().
|
inline |
Returns the vector's element type. Only valid for vector types.
Definition at line 132 of file LowLevelTypeImpl.h.
References assert(), getAddressSpace(), getScalarSizeInBits(), isVector(), pointer(), print(), and scalar().
Referenced by llvm::AArch64LegalizerInfo::AArch64LegalizerInfo(), changeFCMPPredToAArch64CC(), llvm::LegalizeRuleSet::clampMaxNumElements(), llvm::LegalizeRuleSet::clampMinNumElements(), llvm::LegalizeRuleSet::clampNumElements(), llvm::LegalizerInfo::computeTables(), matchPair(), and print().
|
inline |
Returns the number of elements in a vector LLT.
Must only be called on vector types.
Definition at line 92 of file LowLevelTypeImpl.h.
References assert().
Referenced by llvm::MachineIRBuilder::buildInstr(), llvm::LegalizeRuleSet::clampMaxNumElements(), llvm::LegalizeRuleSet::clampMinNumElements(), llvm::LegalizeRuleSet::clampNumElements(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), llvm::getLLTForType(), getSizeInBits(), matchPair(), llvm::LegalizeMutations::moreElementsToNextPow2(), llvm::LegalityPredicates::numElementsNotPow2(), print(), llvm::MachineIRBuilder::validateSelectOp(), and llvm::MachineIRBuilder::validateTruncExt().
|
inline |
Definition at line 107 of file LowLevelTypeImpl.h.
References assert().
Referenced by llvm::LegalizeRuleSet::clampMaxNumElements(), llvm::LegalizeRuleSet::clampMinNumElements(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), getElementType(), getSizeInBits(), llvm::LegalizeMutations::moreElementsToNextPow2(), and print().
|
inline |
Returns the total size of the type. Must only be called on sized types.
Definition at line 101 of file LowLevelTypeImpl.h.
References getNumElements(), getScalarSizeInBits(), isPointer(), and isScalar().
Referenced by llvm::AArch64LegalizerInfo::AArch64LegalizerInfo(), llvm::AMDGPULegalizerInfo::AMDGPULegalizerInfo(), llvm::RegisterBankInfo::applyDefaultMapping(), llvm::MachineIRBuilder::buildConstant(), buildEXP(), llvm::MachineIRBuilder::buildExtOrTrunc(), llvm::MachineIRBuilder::buildFConstant(), llvm::MachineIRBuilder::buildSequence(), canTurnIntoCOPY(), changeFCMPPredToAArch64CC(), llvm::LegalizerInfo::computeTables(), llvm::ConstantFoldBinOp(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), llvm::InstructionSelector::executeMatchTable(), llvm::LegalizerHelper::fewerElementsVector(), llvm::ARMRegisterBankInfo::getInstrMapping(), llvm::X86RegisterBankInfo::getInstrMapping(), llvm::AArch64RegisterBankInfo::getInstrMapping(), getLeaOP(), getOffsetFromIndices(), llvm::X86GenRegisterBankInfo::getPartialMappingIdx(), getRegClassFromGRPhysReg(), llvm::TargetRegisterInfo::getRegSizeInBits(), isPreISelGenericFloatingPointOpcode(), llvm::AArch64LegalizerInfo::legalizeCustom(), llvm::ARMLegalizerInfo::legalizeCustom(), llvm::LegalizerHelper::libcall(), llvm::LegalizerHelper::lower(), llvm::AArch64CallLowering::lowerReturn(), matchPair(), llvm::LegalizeRuleSet::maxScalar(), llvm::LegalizeRuleSet::maxScalarIf(), llvm::LegalizeRuleSet::minScalar(), llvm::LegalityPredicates::narrowerThan(), llvm::LegalizerHelper::narrowScalar(), llvm::InstructionSelect::runOnMachineFunction(), selectCopy(), selectFPConvOpc(), selectMergeValues(), selectUnmergeValues(), llvm::LegalityPredicates::sizeNotPow2(), llvm::CombinerHelper::tryCombineCopy(), llvm::CombinerHelper::tryCombineExtendingLoads(), llvm::LegalizationArtifactCombiner::tryCombineSExt(), llvm::MachineIRBuilder::validateTruncExt(), vector(), llvm::LegalizerHelper::widenScalar(), and llvm::LegalityPredicates::widerThan().
|
inline |
Definition at line 86 of file LowLevelTypeImpl.h.
References isValid().
Referenced by llvm::MachineIRBuilder::buildAtomicCmpXchg(), llvm::MachineIRBuilder::buildAtomicCmpXchgWithSuccess(), llvm::MachineIRBuilder::buildAtomicRMW(), llvm::MachineIRBuilder::buildCast(), llvm::MachineIRBuilder::buildConstant(), llvm::MachineIRBuilder::buildInstr(), changeFCMPPredToAArch64CC(), llvm::LegalizerInfo::computeTables(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), llvm::InstructionSelector::executeMatchTable(), llvm::X86GenRegisterBankInfo::getPartialMappingIdx(), getSizeInBits(), matchPair(), print(), llvm::MachineIRBuilder::validateSelectOp(), and vector().
|
inline |
Definition at line 84 of file LowLevelTypeImpl.h.
References isValid().
Referenced by llvm::MachineIRBuilder::buildAtomicCmpXchg(), llvm::MachineIRBuilder::buildAtomicCmpXchgWithSuccess(), llvm::MachineIRBuilder::buildAtomicRMW(), llvm::MachineIRBuilder::buildCast(), llvm::MachineIRBuilder::buildConstant(), llvm::MachineIRBuilder::buildExtOrTrunc(), llvm::MachineIRBuilder::buildFConstant(), llvm::MachineIRBuilder::buildInstr(), changeFCMPPredToAArch64CC(), llvm::LegalizeRuleSet::clampScalar(), llvm::LegalizerInfo::computeTables(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), llvm::X86GenRegisterBankInfo::getPartialMappingIdx(), getSizeInBits(), llvm::LegalizerHelper::lower(), llvm::ARMCallLowering::lowerReturn(), llvm::MachineIRBuilder::materializeGEP(), llvm::LegalityPredicates::narrowerThan(), print(), selectFPConvOpc(), llvm::LegalityPredicates::sizeNotPow2(), llvm::MachineIRBuilder::validateBinaryOp(), llvm::MachineIRBuilder::validateSelectOp(), llvm::MachineIRBuilder::validateTruncExt(), and llvm::LegalityPredicates::widerThan().
|
inline |
Definition at line 82 of file LowLevelTypeImpl.h.
Referenced by llvm::GISelInstProfileBuilder::addNodeIDMachineOperand(), llvm::MIPatternMatch::bind_helper< LLT >::bind(), llvm::MachineIRBuilder::buildAtomicCmpXchg(), llvm::MachineIRBuilder::buildAtomicCmpXchgWithSuccess(), llvm::MachineIRBuilder::buildAtomicRMW(), changeFCMPPredToAArch64CC(), llvm::MachineRegisterInfo::constrainRegAttrs(), llvm::AArch64RegisterBankInfo::getInstrMapping(), llvm::TargetRegisterInfo::getRegSizeInBits(), llvm::MachineInstr::getTypeToPrint(), isImplicitOperandIn(), isPointer(), isScalar(), isVector(), matchPair(), print(), llvm::MachineOperand::print(), llvm::printRegClassOrBank(), llvm::InstructionSelect::runOnMachineFunction(), llvm::CombinerHelper::tryCombineCopy(), llvm::LegalizationArtifactCombiner::tryCombineInstruction(), and unsupportedBinOp().
|
inline |
Definition at line 88 of file LowLevelTypeImpl.h.
References isValid().
Referenced by llvm::AArch64LegalizerInfo::AArch64LegalizerInfo(), llvm::MachineIRBuilder::buildExtOrTrunc(), llvm::MachineIRBuilder::buildInstr(), canTurnIntoCOPY(), changeFCMPPredToAArch64CC(), llvm::LegalizeRuleSet::clampMaxNumElements(), llvm::LegalizeRuleSet::clampMinNumElements(), llvm::LegalizerInfo::computeTables(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), llvm::LegalizerHelper::fewerElementsVector(), getElementType(), llvm::AArch64RegisterBankInfo::getInstrMapping(), getRegClassFromGRPhysReg(), isPreISelGenericFloatingPointOpcode(), llvm::LegalizerHelper::lower(), matchPair(), llvm::LegalizerHelper::narrowScalar(), llvm::LegalityPredicates::numElementsNotPow2(), print(), llvm::LegalizationArtifactCombiner::tryCombineMerges(), llvm::MachineIRBuilder::validateBinaryOp(), llvm::MachineIRBuilder::validateSelectOp(), llvm::MachineIRBuilder::validateTruncExt(), and vector().
Definition at line 147 of file LowLevelTypeImpl.h.
Definition at line 142 of file LowLevelTypeImpl.h.
Get a low-level pointer in the given address space (defaulting to 0).
Definition at line 50 of file LowLevelTypeImpl.h.
References assert().
Referenced by llvm::AArch64CallLowering::AArch64CallLowering(), llvm::AArch64LegalizerInfo::AArch64LegalizerInfo(), llvm::AMDGPULegalizerInfo::AMDGPULegalizerInfo(), llvm::ARMLegalizerInfo::ARMLegalizerInfo(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), getElementType(), llvm::getLLTForType(), llvm::MipsCallLowering::MipsHandler::handle(), isSupportedType(), llvm::AMDGPUCallLowering::lowerFormalArguments(), llvm::X86CallLowering::lowerReturn(), llvm::ARMCallLowering::lowerReturn(), llvm::MipsLegalizerInfo::MipsLegalizerInfo(), llvm::X86CallLowering::X86CallLowering(), and llvm::X86LegalizerInfo::X86LegalizerInfo().
void LLT::print | ( | raw_ostream & | OS | ) | const |
Definition at line 37 of file LowLevelType.cpp.
References assert(), getAddressSpace(), getElementType(), getNumElements(), getScalarSizeInBits(), isPointer(), isScalar(), isValid(), and isVector().
Referenced by getElementType(), and llvm::operator<<().
Get a low-level scalar or aggregate "bag of bits".
Definition at line 43 of file LowLevelTypeImpl.h.
References assert().
Referenced by llvm::AArch64CallLowering::AArch64CallLowering(), llvm::AArch64LegalizerInfo::AArch64LegalizerInfo(), llvm::AMDGPULegalizerInfo::AMDGPULegalizerInfo(), llvm::ARMLegalizerInfo::ARMLegalizerInfo(), computeValueLLTs(), llvm::RegisterBankInfo::OperandsMapper::createVRegs(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), llvm::LegalizerHelper::fewerElementsVector(), getElementType(), llvm::getLLTForType(), getOffsetFromIndices(), llvm::MipsCallLowering::MipsHandler::handle(), isSupportedType(), llvm::AArch64LegalizerInfo::legalizeCustom(), llvm::ARMLegalizerInfo::legalizeCustom(), llvm::LegalizerHelper::lower(), llvm::X86CallLowering::lowerReturn(), llvm::AMDGPUCallLowering::lowerReturn(), llvm::ARMCallLowering::lowerReturn(), llvm::AArch64CallLowering::lowerReturn(), llvm::MipsLegalizerInfo::MipsLegalizerInfo(), llvm::LegalizerHelper::narrowScalar(), llvm::LegalizerHelper::widenScalar(), llvm::LegalizeMutations::widenScalarToNextPow2(), llvm::X86CallLowering::X86CallLowering(), and llvm::X86LegalizerInfo::X86LegalizerInfo().
Get a low-level vector of some number of elements and element width.
NumElements
must be at least 2.
Definition at line 58 of file LowLevelTypeImpl.h.
References assert().
Referenced by llvm::AArch64LegalizerInfo::AArch64LegalizerInfo(), llvm::AMDGPULegalizerInfo::AMDGPULegalizerInfo(), llvm::LegalizeRuleSet::clampMaxNumElements(), llvm::LegalizeRuleSet::clampMinNumElements(), llvm::LegalizerInfo::decreaseToSmallerTypesAndIncreaseToSmallest(), llvm::getLLTForType(), llvm::LegalizeMutations::moreElementsToNextPow2(), and llvm::X86LegalizerInfo::X86LegalizerInfo().
Get a low-level vector of some number of elements and element type.
Definition at line 66 of file LowLevelTypeImpl.h.
References assert(), getAddressSpace(), getSizeInBits(), isPointer(), and isVector().
|
friend |
Definition at line 149 of file LowLevelTypeImpl.h.
|
friend |
Definition at line 150 of file LowLevelTypeImpl.h.