LLVM API Documentation
#include <MSP430ISelLowering.h>
Public Member Functions | |
MSP430TargetLowering (MSP430TargetMachine &TM) | |
virtual MVT | getScalarShiftAmountTy (EVT LHSTy) const |
virtual SDValue | LowerOperation (SDValue Op, SelectionDAG &DAG) const |
LowerOperation - Provide custom lowering hooks for some operations. More... | |
virtual const char * | getTargetNodeName (unsigned Opcode) const |
SDValue | LowerShifts (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerGlobalAddress (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerBlockAddress (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerExternalSymbol (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerBR_CC (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerSETCC (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerSELECT_CC (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerSIGN_EXTEND (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerRETURNADDR (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerFRAMEADDR (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerVASTART (SDValue Op, SelectionDAG &DAG) const |
SDValue | LowerJumpTable (SDValue Op, SelectionDAG &DAG) const |
SDValue | getReturnAddressFrameIndex (SelectionDAG &DAG) const |
TargetLowering::ConstraintType | getConstraintType (const std::string &Constraint) const |
std::pair< unsigned, const TargetRegisterClass * > | getRegForInlineAsmConstraint (const std::string &Constraint, MVT VT) const |
virtual bool | isTruncateFree (Type *Ty1, Type *Ty2) const |
virtual bool | isTruncateFree (EVT VT1, EVT VT2) const |
virtual bool | isZExtFree (Type *Ty1, Type *Ty2) const |
virtual bool | isZExtFree (EVT VT1, EVT VT2) const |
virtual bool | isZExtFree (SDValue Val, EVT VT2) const |
MachineBasicBlock * | EmitInstrWithCustomInserter (MachineInstr *MI, MachineBasicBlock *BB) const |
MachineBasicBlock * | EmitShiftInstr (MachineInstr *MI, MachineBasicBlock *BB) const |
![]() | |
TargetLowering (const TargetMachine &TM, const TargetLoweringObjectFile *TLOF) | |
NOTE: The constructor takes ownership of TLOF. More... | |
virtual bool | getPreIndexedAddressParts (SDNode *, SDValue &, SDValue &, ISD::MemIndexedMode &, SelectionDAG &) const |
virtual unsigned | getJumpTableEncoding () const |
virtual const MCExpr * | LowerCustomJumpTableEntry (const MachineJumpTableInfo *, const MachineBasicBlock *, unsigned, MCContext &) const |
virtual SDValue | getPICJumpTableRelocBase (SDValue Table, SelectionDAG &DAG) const |
Returns relocation base for the given PIC jumptable. More... | |
virtual const MCExpr * | getPICJumpTableRelocBaseExpr (const MachineFunction *MF, unsigned JTI, MCContext &Ctx) const |
virtual bool | isOffsetFoldingLegal (const GlobalAddressSDNode *GA) const |
bool | isInTailCallPosition (SelectionDAG &DAG, SDNode *Node, SDValue &Chain) const |
void | softenSetCCOperands (SelectionDAG &DAG, EVT VT, SDValue &NewLHS, SDValue &NewRHS, ISD::CondCode &CCCode, SDLoc DL) const |
std::pair< SDValue, SDValue > | makeLibCall (SelectionDAG &DAG, RTLIB::Libcall LC, EVT RetVT, const SDValue *Ops, unsigned NumOps, bool isSigned, SDLoc dl, bool doesNotReturn=false, bool isReturnValueUsed=true) const |
Returns a pair of (return value, chain). More... | |
bool | SimplifyDemandedBits (SDValue Op, const APInt &DemandedMask, APInt &KnownZero, APInt &KnownOne, TargetLoweringOpt &TLO, unsigned Depth=0) const |
virtual void | computeMaskedBitsForTargetNode (const SDValue Op, APInt &KnownZero, APInt &KnownOne, const SelectionDAG &DAG, unsigned Depth=0) const |
virtual unsigned | ComputeNumSignBitsForTargetNode (SDValue Op, unsigned Depth=0) const |
SDValue | SimplifySetCC (EVT VT, SDValue N0, SDValue N1, ISD::CondCode Cond, bool foldBooleans, DAGCombinerInfo &DCI, SDLoc dl) const |
virtual bool | isGAPlusOffset (SDNode *N, const GlobalValue *&GA, int64_t &Offset) const |
virtual SDValue | PerformDAGCombine (SDNode *N, DAGCombinerInfo &DCI) const |
virtual bool | isTypeDesirableForOp (unsigned, EVT VT) const |
virtual bool | isDesirableToTransformToIntegerOp (unsigned, EVT) const |
virtual bool | IsDesirableToPromoteOp (SDValue, EVT &) const |
std::pair< SDValue, SDValue > | LowerCallTo (CallLoweringInfo &CLI) const |
virtual void | HandleByVal (CCState *, unsigned &, unsigned) const |
Target-specific cleanup for formal ByVal parameters. More... | |
virtual bool | CanLowerReturn (CallingConv::ID, MachineFunction &, bool, const SmallVectorImpl< ISD::OutputArg > &, LLVMContext &) const |
virtual bool | isUsedByReturnOnly (SDNode *, SDValue &) const |
virtual bool | mayBeEmittedAsTailCall (CallInst *) const |
virtual MVT | getTypeForExtArgOrReturn (MVT VT, ISD::NodeType) const |
virtual const uint16_t * | getScratchRegisters (CallingConv::ID CC) const |
virtual void | LowerOperationWrapper (SDNode *N, SmallVectorImpl< SDValue > &Results, SelectionDAG &DAG) const |
virtual void | ReplaceNodeResults (SDNode *, SmallVectorImpl< SDValue > &, SelectionDAG &) const |
virtual FastISel * | createFastISel (FunctionLoweringInfo &, const TargetLibraryInfo *) const |
virtual bool | ExpandInlineAsm (CallInst *) const |
virtual AsmOperandInfoVector | ParseConstraints (ImmutableCallSite CS) const |
virtual ConstraintWeight | getMultipleConstraintMatchWeight (AsmOperandInfo &info, int maIndex) const |
virtual ConstraintWeight | getSingleConstraintMatchWeight (AsmOperandInfo &info, const char *constraint) const |
virtual void | ComputeConstraintToUse (AsmOperandInfo &OpInfo, SDValue Op, SelectionDAG *DAG=0) const |
virtual const char * | LowerXConstraint (EVT ConstraintVT) const |
virtual void | LowerAsmOperandForConstraint (SDValue Op, std::string &Constraint, std::vector< SDValue > &Ops, SelectionDAG &DAG) const |
SDValue | BuildExactSDIV (SDValue Op1, SDValue Op2, SDLoc dl, SelectionDAG &DAG) const |
Given an exact SDIV by a constant, create a multiplication with the multiplicative inverse of the constant. More... | |
SDValue | BuildSDIV (SDNode *N, SelectionDAG &DAG, bool IsAfterLegalization, std::vector< SDNode * > *Created) const |
Given an ISD::SDIV node expressing a divide by constant, return a DAG expression to select that will generate the same value by multiplying by a magic number. See: http://the.wall.riscom.net/books/proc/ppc/cwg/code2.html More... | |
SDValue | BuildUDIV (SDNode *N, SelectionDAG &DAG, bool IsAfterLegalization, std::vector< SDNode * > *Created) const |
Given an ISD::UDIV node expressing a divide by constant, return a DAG expression to select that will generate the same value by multiplying by a magic number. See: http://the.wall.riscom.net/books/proc/ppc/cwg/code2.html More... | |
virtual void | AdjustInstrPostInstrSelection (MachineInstr *MI, SDNode *Node) const |
![]() | |
TargetLoweringBase (const TargetMachine &TM, const TargetLoweringObjectFile *TLOF) | |
NOTE: The constructor takes ownership of TLOF. More... | |
virtual | ~TargetLoweringBase () |
const TargetMachine & | getTargetMachine () const |
const DataLayout * | getDataLayout () const |
const TargetLoweringObjectFile & | getObjFileLowering () const |
bool | isBigEndian () const |
bool | isLittleEndian () const |
virtual MVT | getPointerTy (uint32_t=0) const |
unsigned | getPointerSizeInBits (uint32_t AS=0) const |
unsigned | getPointerTypeSizeInBits (Type *Ty) const |
EVT | getShiftAmountTy (EVT LHSTy) const |
virtual MVT | getVectorIdxTy () const |
bool | isSelectExpensive () const |
Return true if the select operation is expensive for this target. More... | |
virtual bool | isSelectSupported (SelectSupportKind) const |
virtual bool | shouldSplitVectorElementType (EVT) const |
bool | isIntDivCheap () const |
bool | isSlowDivBypassed () const |
Returns true if target has indicated at least one type should be bypassed. More... | |
const DenseMap< unsigned int, unsigned int > & | getBypassSlowDivWidths () const |
bool | isPow2DivCheap () const |
Return true if pow2 div is cheaper than a chain of srl/add/sra. More... | |
bool | isJumpExpensive () const |
bool | isPredictableSelectExpensive () const |
virtual bool | isLoadBitCastBeneficial (EVT, EVT) const |
virtual EVT | getSetCCResultType (LLVMContext &Context, EVT VT) const |
virtual MVT::SimpleValueType | getCmpLibcallReturnType () const |
BooleanContent | getBooleanContents (bool isVec) const |
Sched::Preference | getSchedulingPreference () const |
Return target scheduling preference. More... | |
virtual Sched::Preference | getSchedulingPreference (SDNode *) const |
virtual const TargetRegisterClass * | getRegClassFor (MVT VT) const |
virtual const TargetRegisterClass * | getRepRegClassFor (MVT VT) const |
virtual uint8_t | getRepRegClassCostFor (MVT VT) const |
bool | isTypeLegal (EVT VT) const |
const ValueTypeActionImpl & | getValueTypeActions () const |
LegalizeTypeAction | getTypeAction (LLVMContext &Context, EVT VT) const |
LegalizeTypeAction | getTypeAction (MVT VT) const |
EVT | getTypeToTransformTo (LLVMContext &Context, EVT VT) const |
EVT | getTypeToExpandTo (LLVMContext &Context, EVT VT) const |
unsigned | getVectorTypeBreakdown (LLVMContext &Context, EVT VT, EVT &IntermediateVT, unsigned &NumIntermediates, MVT &RegisterVT) const |
virtual bool | getTgtMemIntrinsic (IntrinsicInfo &, const CallInst &, unsigned) const |
virtual bool | isFPImmLegal (const APFloat &, EVT) const |
virtual bool | isShuffleMaskLegal (const SmallVectorImpl< int > &, EVT) const |
virtual bool | canOpTrap (unsigned Op, EVT VT) const |
virtual bool | isVectorClearMaskLegal (const SmallVectorImpl< int > &, EVT) const |
LegalizeAction | getOperationAction (unsigned Op, EVT VT) const |
bool | isOperationLegalOrCustom (unsigned Op, EVT VT) const |
bool | isOperationLegalOrPromote (unsigned Op, EVT VT) const |
bool | isOperationExpand (unsigned Op, EVT VT) const |
bool | isOperationLegal (unsigned Op, EVT VT) const |
Return true if the specified operation is legal on this target. More... | |
LegalizeAction | getLoadExtAction (unsigned ExtType, MVT VT) const |
bool | isLoadExtLegal (unsigned ExtType, EVT VT) const |
Return true if the specified load with extension is legal on this target. More... | |
LegalizeAction | getTruncStoreAction (MVT ValVT, MVT MemVT) const |
bool | isTruncStoreLegal (EVT ValVT, EVT MemVT) const |
LegalizeAction | getIndexedLoadAction (unsigned IdxMode, MVT VT) const |
bool | isIndexedLoadLegal (unsigned IdxMode, EVT VT) const |
Return true if the specified indexed load is legal on this target. More... | |
LegalizeAction | getIndexedStoreAction (unsigned IdxMode, MVT VT) const |
bool | isIndexedStoreLegal (unsigned IdxMode, EVT VT) const |
Return true if the specified indexed load is legal on this target. More... | |
LegalizeAction | getCondCodeAction (ISD::CondCode CC, MVT VT) const |
bool | isCondCodeLegal (ISD::CondCode CC, MVT VT) const |
Return true if the specified condition code is legal on this target. More... | |
MVT | getTypeToPromoteTo (unsigned Op, MVT VT) const |
EVT | getValueType (Type *Ty, bool AllowUnknown=false) const |
MVT | getSimpleValueType (Type *Ty, bool AllowUnknown=false) const |
Return the MVT corresponding to this LLVM type. See getValueType. More... | |
virtual unsigned | getByValTypeAlignment (Type *Ty) const |
MVT | getRegisterType (MVT VT) const |
Return the type of registers that this ValueType will eventually require. More... | |
MVT | getRegisterType (LLVMContext &Context, EVT VT) const |
Return the type of registers that this ValueType will eventually require. More... | |
unsigned | getNumRegisters (LLVMContext &Context, EVT VT) const |
virtual bool | ShouldShrinkFPConstant (EVT) const |
bool | hasTargetDAGCombine (ISD::NodeType NT) const |
unsigned | getMaxStoresPerMemset (bool OptSize) const |
Get maximum # of store operations permitted for llvm.memset. More... | |
unsigned | getMaxStoresPerMemcpy (bool OptSize) const |
Get maximum # of store operations permitted for llvm.memcpy. More... | |
unsigned | getMaxStoresPerMemmove (bool OptSize) const |
Get maximum # of store operations permitted for llvm.memmove. More... | |
virtual bool | allowsUnalignedMemoryAccesses (EVT, bool *=0) const |
Determine if the target supports unaligned memory accesses. More... | |
virtual EVT | getOptimalMemOpType (uint64_t, unsigned, unsigned, bool, bool, bool, MachineFunction &) const |
virtual bool | isSafeMemOpType (MVT) const |
bool | usesUnderscoreSetJmp () const |
Determine if we should use _setjmp or setjmp to implement llvm.setjmp. More... | |
bool | usesUnderscoreLongJmp () const |
Determine if we should use _longjmp or longjmp to implement llvm.longjmp. More... | |
bool | supportJumpTables () const |
Return whether the target can generate code for jump tables. More... | |
int | getMinimumJumpTableEntries () const |
unsigned | getStackPointerRegisterToSaveRestore () const |
unsigned | getExceptionPointerRegister () const |
unsigned | getExceptionSelectorRegister () const |
unsigned | getJumpBufSize () const |
unsigned | getJumpBufAlignment () const |
unsigned | getMinStackArgumentAlignment () const |
Return the minimum stack alignment of an argument. More... | |
unsigned | getMinFunctionAlignment () const |
Return the minimum function alignment. More... | |
unsigned | getPrefFunctionAlignment () const |
Return the preferred function alignment. More... | |
unsigned | getPrefLoopAlignment () const |
Return the preferred loop alignment. More... | |
bool | getInsertFencesForAtomic () const |
virtual bool | getStackCookieLocation (unsigned &, unsigned &) const |
virtual unsigned | getMaximalGlobalOffset () const |
virtual bool | isNoopAddrSpaceCast (unsigned SrcAS, unsigned DestAS) const |
Returns true if a cast between SrcAS and DestAS is a noop. More... | |
virtual void | resetOperationActions () |
Reset the operation actions based on target options. More... | |
virtual bool | GetAddrModeArguments (IntrinsicInst *, SmallVectorImpl< Value * > &, Type *&) const |
virtual bool | isLegalAddressingMode (const AddrMode &AM, Type *Ty) const |
virtual int | getScalingFactorCost (const AddrMode &AM, Type *Ty) const |
Return the cost of the scaling factor used in the addressing mode represented by AM for this target, for a load/store of the specified type. More... | |
virtual bool | isLegalICmpImmediate (int64_t) const |
virtual bool | isLegalAddImmediate (int64_t) const |
virtual bool | allowTruncateForTailCall (Type *, Type *) const |
virtual bool | hasPairedLoad (Type *, unsigned &) const |
virtual bool | hasPairedLoad (EVT, unsigned &) const |
virtual bool | isFNegFree (EVT VT) const |
virtual bool | isFAbsFree (EVT VT) const |
virtual bool | isFMAFasterThanFMulAndFAdd (EVT) const |
virtual bool | isNarrowingProfitable (EVT, EVT) const |
void | setLibcallName (RTLIB::Libcall Call, const char *Name) |
Rename the default libcall routine name for the specified libcall. More... | |
const char * | getLibcallName (RTLIB::Libcall Call) const |
Get the libcall routine name for the specified libcall. More... | |
void | setCmpLibcallCC (RTLIB::Libcall Call, ISD::CondCode CC) |
ISD::CondCode | getCmpLibcallCC (RTLIB::Libcall Call) const |
void | setLibcallCallingConv (RTLIB::Libcall Call, CallingConv::ID CC) |
Set the CallingConv that should be used for the specified libcall. More... | |
CallingConv::ID | getLibcallCallingConv (RTLIB::Libcall Call) const |
Get the CallingConv that should be used for the specified libcall. More... | |
LegalizeKind | getTypeConversion (LLVMContext &Context, EVT VT) const |
int | InstructionOpcodeToISD (unsigned Opcode) const |
Get the ISD node that corresponds to the Instruction class opcode. More... | |
std::pair< unsigned, MVT > | getTypeLegalizationCost (Type *Ty) const |
Estimate the cost of type-legalization and the legalized type. More... | |
Definition at line 72 of file MSP430ISelLowering.h.
|
explicit |
Definition at line 60 of file MSP430ISelLowering.cpp.
References llvm::TargetLoweringBase::addRegisterClass(), llvm::ISD::BlockAddress, llvm::ISD::BR_CC, llvm::ISD::BR_JT, llvm::ISD::BRCOND, llvm::TargetLoweringBase::computeRegisterProperties(), llvm::ISD::CTLZ, llvm::ISD::CTLZ_ZERO_UNDEF, llvm::ISD::CTPOP, llvm::ISD::CTTZ, llvm::ISD::CTTZ_ZERO_UNDEF, llvm::TargetLoweringBase::Custom, llvm::ISD::DYNAMIC_STACKALLOC, llvm::TargetLoweringBase::Expand, llvm::ISD::ExternalSymbol, llvm::ISD::EXTLOAD, llvm::TargetLoweringBase::getDataLayout(), llvm::ISD::GlobalAddress, HWMultIntr, HWMultMode, HWMultNoIntr, llvm::MVT::i1, llvm::MVT::i16, llvm::MVT::i8, llvm::ISD::JumpTable, llvm::TargetLoweringBase::Legal, llvm::ISD::MUL, llvm::RTLIB::MUL_I16, llvm::RTLIB::MUL_I8, llvm::ISD::MULHS, llvm::ISD::MULHU, llvm::MVT::Other, llvm::ISD::POST_INC, llvm::TargetLoweringBase::Promote, llvm::ISD::ROTL, llvm::ISD::ROTR, llvm::ISD::SDIV, llvm::ISD::SDIVREM, llvm::ISD::SELECT, llvm::ISD::SELECT_CC, llvm::TargetLoweringBase::setBooleanContents(), llvm::TargetLoweringBase::setBooleanVectorContents(), llvm::ISD::SETCC, llvm::TargetLoweringBase::setIndexedLoadAction(), llvm::TargetLoweringBase::setIntDivIsCheap(), llvm::TargetLoweringBase::setLibcallName(), llvm::TargetLoweringBase::setLoadExtAction(), llvm::TargetLoweringBase::setMinFunctionAlignment(), llvm::TargetLoweringBase::setOperationAction(), llvm::TargetLoweringBase::setPrefFunctionAlignment(), llvm::TargetLoweringBase::setStackPointerRegisterToSaveRestore(), llvm::TargetLoweringBase::setTruncStoreAction(), llvm::ISD::SEXTLOAD, llvm::ISD::SHL, llvm::ISD::SHL_PARTS, llvm::ISD::SIGN_EXTEND, llvm::ISD::SIGN_EXTEND_INREG, llvm::ISD::SMUL_LOHI, llvm::ISD::SRA, llvm::ISD::SRA_PARTS, llvm::ISD::SREM, llvm::ISD::SRL, llvm::ISD::SRL_PARTS, llvm::ISD::UDIV, llvm::ISD::UDIVREM, llvm::ISD::UMUL_LOHI, llvm::ISD::UREM, llvm::ISD::VAARG, llvm::ISD::VACOPY, llvm::ISD::VAEND, llvm::ISD::VASTART, llvm::TargetLoweringBase::ZeroOrOneBooleanContent, and llvm::ISD::ZEXTLOAD.
|
virtual |
This method should be implemented by targets that mark instructions with the 'usesCustomInserter' flag. These instructions are special in various ways, which require special support to insert. The specified MachineInstr is created but not inserted into any basic blocks, and this method is called to expand it into a sequence of instructions, potentially also creating new basic blocks and control flow.
Reimplemented from llvm::TargetLowering.
Definition at line 1306 of file MSP430ISelLowering.cpp.
References llvm::MachineInstrBuilder::addImm(), llvm::MachineInstrBuilder::addReg(), llvm::MachineBasicBlock::addSuccessor(), llvm::MachineBasicBlock::begin(), llvm::BuildMI(), llvm::MachineFunction::CreateMachineBasicBlock(), EmitShiftInstr(), llvm::MachineBasicBlock::end(), llvm::MachineInstr::eraseFromParent(), F(), llvm::MCInstrInfo::get(), llvm::MachineBasicBlock::getBasicBlock(), llvm::MachineInstr::getDebugLoc(), llvm::MachineOperand::getImm(), llvm::TargetMachine::getInstrInfo(), llvm::MachineInstr::getOpcode(), llvm::MachineInstr::getOperand(), llvm::MachineBasicBlock::getParent(), llvm::MachineOperand::getReg(), llvm::TargetLoweringBase::getTargetMachine(), I, llvm::MachineFunction::insert(), llvm::next(), llvm::TargetOpcode::PHI, llvm::MachineBasicBlock::splice(), TII, and llvm::MachineBasicBlock::transferSuccessorsAndUpdatePHIs().
MachineBasicBlock * MSP430TargetLowering::EmitShiftInstr | ( | MachineInstr * | MI, |
MachineBasicBlock * | BB | ||
) | const |
Definition at line 1198 of file MSP430ISelLowering.cpp.
References llvm::MachineInstrBuilder::addImm(), llvm::MachineInstrBuilder::addMBB(), llvm::MachineInstrBuilder::addReg(), llvm::MachineBasicBlock::addSuccessor(), llvm::MachineBasicBlock::begin(), llvm::BuildMI(), MSP430CC::COND_E, MSP430CC::COND_NE, llvm::MachineFunction::CreateMachineBasicBlock(), llvm::MachineRegisterInfo::createVirtualRegister(), llvm::MachineBasicBlock::end(), llvm::MachineInstr::eraseFromParent(), F(), llvm::MCInstrInfo::get(), llvm::MachineBasicBlock::getBasicBlock(), llvm::MachineInstr::getDebugLoc(), llvm::TargetMachine::getInstrInfo(), llvm::MachineInstr::getOpcode(), llvm::MachineInstr::getOperand(), llvm::MachineBasicBlock::getParent(), llvm::MachineOperand::getReg(), llvm::MachineFunction::getRegInfo(), llvm::TargetLoweringBase::getTargetMachine(), I, llvm::MachineFunction::insert(), llvm_unreachable, llvm::next(), llvm::TargetOpcode::PHI, llvm::MachineBasicBlock::splice(), TII, and llvm::MachineBasicBlock::transferSuccessorsAndUpdatePHIs().
Referenced by EmitInstrWithCustomInserter().
|
virtual |
getConstraintType - Given a constraint letter, return the type of constraint it is for this target.
Reimplemented from llvm::TargetLowering.
Definition at line 216 of file MSP430ISelLowering.cpp.
References llvm::TargetLowering::C_RegisterClass, and llvm::TargetLowering::getConstraintType().
|
virtual |
Given a physical register constraint (e.g. {edx}), return the register number and the register class for the register.
Given a register class constraint, like 'r', if this corresponds directly to an LLVM register class, return a register of 0 and the register class pointer.
This should only be used for C_Register constraints. On error, this returns a register number of 0 and a null register class pointer..
Reimplemented from llvm::TargetLowering.
Definition at line 230 of file MSP430ISelLowering.cpp.
References llvm::TargetLowering::getRegForInlineAsmConstraint(), and llvm::MVT::i8.
SDValue MSP430TargetLowering::getReturnAddressFrameIndex | ( | SelectionDAG & | DAG | ) | const |
Definition at line 1029 of file MSP430ISelLowering.cpp.
References llvm::MachineFrameInfo::CreateFixedObject(), llvm::SelectionDAG::getFrameIndex(), llvm::MachineFunction::getFrameInfo(), llvm::MachineFunction::getInfo(), llvm::SelectionDAG::getMachineFunction(), llvm::DataLayout::getPointerSize(), llvm::TargetLoweringBase::getPointerTy(), llvm::MSP430MachineFunctionInfo::getRAIndex(), and llvm::MSP430MachineFunctionInfo::setRAIndex().
Referenced by LowerRETURNADDR().
Reimplemented from llvm::TargetLoweringBase.
Definition at line 76 of file MSP430ISelLowering.h.
References llvm::MVT::i8.
|
virtual |
getTargetNodeName - This method returns the name of a target specific DAG node.
Reimplemented from llvm::TargetLowering.
Definition at line 1146 of file MSP430ISelLowering.cpp.
References llvm::MSP430ISD::BR_CC, llvm::MSP430ISD::CALL, llvm::MSP430ISD::CMP, llvm::MSP430ISD::RET_FLAG, llvm::MSP430ISD::RETI_FLAG, llvm::MSP430ISD::RLA, llvm::MSP430ISD::RRA, llvm::MSP430ISD::RRC, llvm::MSP430ISD::SELECT_CC, llvm::MSP430ISD::SHL, llvm::MSP430ISD::SRA, and llvm::MSP430ISD::Wrapper.
isTruncateFree - Return true if it's free to truncate a value of type Ty1 to type Ty2. e.g. On msp430 it's free to truncate a i16 value in register R15W to i8 by referencing its sub-register R15B.
Reimplemented from llvm::TargetLoweringBase.
Definition at line 1164 of file MSP430ISelLowering.cpp.
References llvm::Type::getPrimitiveSizeInBits(), and llvm::Type::isIntegerTy().
Reimplemented from llvm::TargetLoweringBase.
Definition at line 1172 of file MSP430ISelLowering.cpp.
References llvm::EVT::getSizeInBits(), and llvm::EVT::isInteger().
isZExtFree - Return true if any actual instruction that defines a value of type Ty1 implicit zero-extends the value to Ty2 in the result register. This does not necessarily include registers defined in unknown ways, such as incoming arguments, or copies from unknown virtual registers. Also, if isTruncateFree(Ty2, Ty1) is true, this does not necessarily apply to truncate instructions. e.g. on msp430, all instructions that define 8-bit values implicit zero-extend the result out to 16 bits.
Reimplemented from llvm::TargetLoweringBase.
Definition at line 1179 of file MSP430ISelLowering.cpp.
References llvm::Type::isIntegerTy().
Referenced by isZExtFree().
Reimplemented from llvm::TargetLoweringBase.
Definition at line 1184 of file MSP430ISelLowering.cpp.
References llvm::MVT::i16, and llvm::MVT::i8.
Return true if zero-extending the specific node Val to type VT2 is free (either because it's implicitly zero-extended such as ARM ldrb / ldrh or because it's folded such as X86 zero-extending loads).
Reimplemented from llvm::TargetLoweringBase.
Definition at line 1189 of file MSP430ISelLowering.cpp.
References llvm::SDValue::getValueType(), and isZExtFree().
SDValue MSP430TargetLowering::LowerBlockAddress | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 806 of file MSP430ISelLowering.cpp.
References llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getTargetBlockAddress(), and llvm::MSP430ISD::Wrapper.
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerBR_CC | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 898 of file MSP430ISelLowering.cpp.
References llvm::MSP430ISD::BR_CC, EmitCMP(), llvm::SelectionDAG::getNode(), llvm::SDValue::getOperand(), and llvm::SDValue::getValueType().
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerExternalSymbol | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 797 of file MSP430ISelLowering.cpp.
References llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getTargetExternalSymbol(), and llvm::MSP430ISD::Wrapper.
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerFRAMEADDR | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 1069 of file MSP430ISelLowering.cpp.
References llvm::SelectionDAG::getCopyFromReg(), llvm::SelectionDAG::getEntryNode(), llvm::MachineFunction::getFrameInfo(), llvm::SelectionDAG::getLoad(), llvm::SelectionDAG::getMachineFunction(), llvm::SDValue::getOperand(), llvm::SDValue::getValueType(), and llvm::MachineFrameInfo::setFrameAddressIsTaken().
Referenced by LowerOperation(), and LowerRETURNADDR().
SDValue MSP430TargetLowering::LowerGlobalAddress | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 785 of file MSP430ISelLowering.cpp.
References llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getTargetGlobalAddress(), and llvm::MSP430ISD::Wrapper.
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerJumpTable | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 1102 of file MSP430ISelLowering.cpp.
References llvm::JumpTableSDNode::getIndex(), llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getTargetJumpTable(), and llvm::MSP430ISD::Wrapper.
Referenced by LowerOperation().
|
virtual |
LowerOperation - Provide custom lowering hooks for some operations.
Reimplemented from llvm::TargetLowering.
Definition at line 187 of file MSP430ISelLowering.cpp.
References llvm::ISD::BlockAddress, llvm::ISD::BR_CC, llvm::ISD::ExternalSymbol, llvm::ISD::FRAMEADDR, llvm::SDValue::getOpcode(), llvm::ISD::GlobalAddress, llvm::ISD::JumpTable, llvm_unreachable, LowerBlockAddress(), LowerBR_CC(), LowerExternalSymbol(), LowerFRAMEADDR(), LowerGlobalAddress(), LowerJumpTable(), LowerRETURNADDR(), LowerSELECT_CC(), LowerSETCC(), LowerShifts(), LowerSIGN_EXTEND(), LowerVASTART(), llvm::ISD::RETURNADDR, llvm::ISD::SELECT_CC, llvm::ISD::SETCC, llvm::ISD::SHL, llvm::ISD::SIGN_EXTEND, llvm::ISD::SRA, llvm::ISD::SRL, and llvm::ISD::VASTART.
SDValue MSP430TargetLowering::LowerRETURNADDR | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 1045 of file MSP430ISelLowering.cpp.
References llvm::ISD::ADD, llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getEntryNode(), llvm::MachineFunction::getFrameInfo(), llvm::SelectionDAG::getLoad(), llvm::SelectionDAG::getMachineFunction(), llvm::SelectionDAG::getNode(), llvm::SDValue::getOperand(), llvm::DataLayout::getPointerSize(), llvm::TargetLoweringBase::getPointerTy(), getReturnAddressFrameIndex(), llvm::MVT::i16, LowerFRAMEADDR(), and llvm::MachineFrameInfo::setReturnAddressIsTaken().
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerSELECT_CC | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 993 of file MSP430ISelLowering.cpp.
References EmitCMP(), llvm::SelectionDAG::getNode(), llvm::SDValue::getOperand(), llvm::SDValue::getValueType(), llvm::SelectionDAG::getVTList(), llvm::MVT::Glue, llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back(), llvm::MSP430ISD::SELECT_CC, and llvm::SmallVectorTemplateCommon< T >::size().
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerSETCC | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 913 of file MSP430ISelLowering.cpp.
References llvm::ISD::AND, MSP430CC::COND_E, MSP430CC::COND_HS, MSP430CC::COND_LO, MSP430CC::COND_NE, EmitCMP(), llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getCopyFromReg(), llvm::SelectionDAG::getEntryNode(), llvm::SelectionDAG::getNode(), llvm::SDValue::getOpcode(), llvm::SDValue::getOperand(), llvm::SDValue::getValueType(), llvm::SelectionDAG::getVTList(), llvm::MVT::Glue, llvm::SDValue::hasOneUse(), llvm::MVT::i16, llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back(), llvm::MSP430ISD::SELECT_CC, llvm::SmallVectorTemplateCommon< T >::size(), llvm::ISD::SRA, llvm::ISD::TRUNCATE, and llvm::ISD::XOR.
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerShifts | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 742 of file MSP430ISelLowering.cpp.
References llvm::SDValue::getNode(), llvm::SelectionDAG::getNode(), llvm::SDValue::getOpcode(), llvm::SDNode::getOperand(), llvm::SDValue::getValueType(), llvm_unreachable, N, llvm::MSP430ISD::RLA, llvm::MSP430ISD::RRA, llvm::MSP430ISD::RRC, llvm::MSP430ISD::SHL, llvm::ISD::SHL, llvm::MSP430ISD::SRA, llvm::ISD::SRA, llvm::MSP430ISD::SRL, and llvm::ISD::SRL.
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerSIGN_EXTEND | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 1015 of file MSP430ISelLowering.cpp.
References llvm::ISD::ANY_EXTEND, llvm::SelectionDAG::getNode(), llvm::SDValue::getOperand(), llvm::SDValue::getValueType(), llvm::SelectionDAG::getValueType(), llvm::MVT::i16, and llvm::ISD::SIGN_EXTEND_INREG.
Referenced by LowerOperation().
SDValue MSP430TargetLowering::LowerVASTART | ( | SDValue | Op, |
SelectionDAG & | DAG | ||
) | const |
Definition at line 1086 of file MSP430ISelLowering.cpp.
References llvm::ISD::FrameIndex, llvm::SelectionDAG::getFrameIndex(), llvm::MachineFunction::getInfo(), llvm::SelectionDAG::getMachineFunction(), llvm::SDValue::getOperand(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getStore(), and llvm::MSP430MachineFunctionInfo::getVarArgsFrameIndex().
Referenced by LowerOperation().