LLVM API Documentation

Classes | Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Friends
llvm::SelectionDAG Class Reference

#include <SelectionDAG.h>

Collaboration diagram for llvm::SelectionDAG:
Collaboration graph
[legend]

List of all members.

Classes

struct  DAGUpdateListener

Public Types

typedef ilist< SDNode >
::const_iterator 
allnodes_const_iterator
typedef ilist< SDNode >::iterator allnodes_iterator

Public Member Functions

 SelectionDAG (const TargetMachine &TM, llvm::CodeGenOpt::Level)
 ~SelectionDAG ()
void init (MachineFunction &mf, const TargetLowering *TLI)
void clear ()
MachineFunctiongetMachineFunction () const
const TargetMachinegetTarget () const
const TargetSubtargetInfogetSubtarget () const
const TargetLoweringgetTargetLoweringInfo () const
const TargetSelectionDAGInfogetSelectionDAGInfo () const
LLVMContextgetContext () const
void viewGraph (const std::string &Title)
void viewGraph ()
void clearGraphAttrs ()
void setGraphAttrs (const SDNode *N, const char *Attrs)
const std::string getGraphAttrs (const SDNode *N) const
void setGraphColor (const SDNode *N, const char *Color)
void setSubgraphColor (SDNode *N, const char *Color)
allnodes_const_iterator allnodes_begin () const
allnodes_const_iterator allnodes_end () const
allnodes_iterator allnodes_begin ()
allnodes_iterator allnodes_end ()
ilist< SDNode >::size_type allnodes_size () const
const SDValuegetRoot () const
SDValue getEntryNode () const
const SDValuesetRoot (SDValue N)
void Combine (CombineLevel Level, AliasAnalysis &AA, CodeGenOpt::Level OptLevel)
 This is the entry point for the file.
bool LegalizeTypes ()
void Legalize ()
bool LegalizeOp (SDNode *N, SmallSetVector< SDNode *, 16 > &UpdatedNodes)
 Transforms a SelectionDAG node and any operands to it into a node that is compatible with the target instruction selector, as indicated by the TargetLowering object.
bool LegalizeVectors ()
void RemoveDeadNodes ()
void DeleteNode (SDNode *N)
SDVTList getVTList (EVT VT)
SDVTList getVTList (EVT VT1, EVT VT2)
SDVTList getVTList (EVT VT1, EVT VT2, EVT VT3)
SDVTList getVTList (EVT VT1, EVT VT2, EVT VT3, EVT VT4)
SDVTList getVTList (ArrayRef< EVT > VTs)
SDValue getConstant (uint64_t Val, EVT VT, bool isTarget=false, bool isOpaque=false)
SDValue getConstant (const APInt &Val, EVT VT, bool isTarget=false, bool isOpaque=false)
SDValue getConstant (const ConstantInt &Val, EVT VT, bool isTarget=false, bool isOpaque=false)
SDValue getIntPtrConstant (uint64_t Val, bool isTarget=false)
SDValue getTargetConstant (uint64_t Val, EVT VT, bool isOpaque=false)
SDValue getTargetConstant (const APInt &Val, EVT VT, bool isOpaque=false)
SDValue getTargetConstant (const ConstantInt &Val, EVT VT, bool isOpaque=false)
SDValue getConstantFP (double Val, EVT VT, bool isTarget=false)
SDValue getConstantFP (const APFloat &Val, EVT VT, bool isTarget=false)
SDValue getConstantFP (const ConstantFP &CF, EVT VT, bool isTarget=false)
SDValue getTargetConstantFP (double Val, EVT VT)
SDValue getTargetConstantFP (const APFloat &Val, EVT VT)
SDValue getTargetConstantFP (const ConstantFP &Val, EVT VT)
SDValue getGlobalAddress (const GlobalValue *GV, SDLoc DL, EVT VT, int64_t offset=0, bool isTargetGA=false, unsigned char TargetFlags=0)
SDValue getTargetGlobalAddress (const GlobalValue *GV, SDLoc DL, EVT VT, int64_t offset=0, unsigned char TargetFlags=0)
SDValue getFrameIndex (int FI, EVT VT, bool isTarget=false)
SDValue getTargetFrameIndex (int FI, EVT VT)
SDValue getJumpTable (int JTI, EVT VT, bool isTarget=false, unsigned char TargetFlags=0)
SDValue getTargetJumpTable (int JTI, EVT VT, unsigned char TargetFlags=0)
SDValue getConstantPool (const Constant *C, EVT VT, unsigned Align=0, int Offs=0, bool isT=false, unsigned char TargetFlags=0)
SDValue getTargetConstantPool (const Constant *C, EVT VT, unsigned Align=0, int Offset=0, unsigned char TargetFlags=0)
SDValue getConstantPool (MachineConstantPoolValue *C, EVT VT, unsigned Align=0, int Offs=0, bool isT=false, unsigned char TargetFlags=0)
SDValue getTargetConstantPool (MachineConstantPoolValue *C, EVT VT, unsigned Align=0, int Offset=0, unsigned char TargetFlags=0)
SDValue getTargetIndex (int Index, EVT VT, int64_t Offset=0, unsigned char TargetFlags=0)
SDValue getBasicBlock (MachineBasicBlock *MBB)
SDValue getBasicBlock (MachineBasicBlock *MBB, SDLoc dl)
SDValue getExternalSymbol (const char *Sym, EVT VT)
SDValue getExternalSymbol (const char *Sym, SDLoc dl, EVT VT)
SDValue getTargetExternalSymbol (const char *Sym, EVT VT, unsigned char TargetFlags=0)
SDValue getValueType (EVT)
SDValue getRegister (unsigned Reg, EVT VT)
SDValue getRegisterMask (const uint32_t *RegMask)
SDValue getEHLabel (SDLoc dl, SDValue Root, MCSymbol *Label)
SDValue getBlockAddress (const BlockAddress *BA, EVT VT, int64_t Offset=0, bool isTarget=false, unsigned char TargetFlags=0)
SDValue getTargetBlockAddress (const BlockAddress *BA, EVT VT, int64_t Offset=0, unsigned char TargetFlags=0)
SDValue getCopyToReg (SDValue Chain, SDLoc dl, unsigned Reg, SDValue N)
SDValue getCopyToReg (SDValue Chain, SDLoc dl, unsigned Reg, SDValue N, SDValue Glue)
SDValue getCopyToReg (SDValue Chain, SDLoc dl, SDValue Reg, SDValue N, SDValue Glue)
SDValue getCopyFromReg (SDValue Chain, SDLoc dl, unsigned Reg, EVT VT)
SDValue getCopyFromReg (SDValue Chain, SDLoc dl, unsigned Reg, EVT VT, SDValue Glue)
SDValue getCondCode (ISD::CondCode Cond)
SDValue getConvertRndSat (EVT VT, SDLoc dl, SDValue Val, SDValue DTy, SDValue STy, SDValue Rnd, SDValue Sat, ISD::CvtCode Code)
SDValue getVectorShuffle (EVT VT, SDLoc dl, SDValue N1, SDValue N2, const int *MaskElts)
SDValue getVectorShuffle (EVT VT, SDLoc dl, SDValue N1, SDValue N2, ArrayRef< int > MaskElts)
SDValue getCommutedVectorShuffle (const ShuffleVectorSDNode &SV)
 Returns an ISD::VECTOR_SHUFFLE node semantically equivalent to the shuffle node in input but with swapped operands.
SDValue getAnyExtOrTrunc (SDValue Op, SDLoc DL, EVT VT)
SDValue getSExtOrTrunc (SDValue Op, SDLoc DL, EVT VT)
SDValue getZExtOrTrunc (SDValue Op, SDLoc DL, EVT VT)
SDValue getZeroExtendInReg (SDValue Op, SDLoc DL, EVT SrcTy)
SDValue getAnyExtendVectorInReg (SDValue Op, SDLoc DL, EVT VT)
SDValue getSignExtendVectorInReg (SDValue Op, SDLoc DL, EVT VT)
SDValue getZeroExtendVectorInReg (SDValue Op, SDLoc DL, EVT VT)
SDValue getBoolExtOrTrunc (SDValue Op, SDLoc SL, EVT VT, EVT OpVT)
SDValue getNOT (SDLoc DL, SDValue Val, EVT VT)
 getNOT - Create a bitwise NOT operation as (XOR Val, -1).
SDValue getLogicalNOT (SDLoc DL, SDValue Val, EVT VT)
 Create a logical NOT operation as (XOR Val, BooleanOne).
SDValue getCALLSEQ_START (SDValue Chain, SDValue Op, SDLoc DL)
SDValue getCALLSEQ_END (SDValue Chain, SDValue Op1, SDValue Op2, SDValue InGlue, SDLoc DL)
SDValue getUNDEF (EVT VT)
 getUNDEF - Return an UNDEF node. UNDEF does not have a useful SDLoc.
SDValue getGLOBAL_OFFSET_TABLE (EVT VT)
SDValue getNode (unsigned Opcode, SDLoc DL, EVT VT)
SDValue getNode (unsigned Opcode, SDLoc DL, EVT VT, SDValue N)
SDValue getNode (unsigned Opcode, SDLoc DL, EVT VT, SDValue N1, SDValue N2, bool nuw=false, bool nsw=false, bool exact=false)
SDValue getNode (unsigned Opcode, SDLoc DL, EVT VT, SDValue N1, SDValue N2, SDValue N3)
SDValue getNode (unsigned Opcode, SDLoc DL, EVT VT, SDValue N1, SDValue N2, SDValue N3, SDValue N4)
SDValue getNode (unsigned Opcode, SDLoc DL, EVT VT, SDValue N1, SDValue N2, SDValue N3, SDValue N4, SDValue N5)
SDValue getNode (unsigned Opcode, SDLoc DL, EVT VT, ArrayRef< SDUse > Ops)
SDValue getNode (unsigned Opcode, SDLoc DL, EVT VT, ArrayRef< SDValue > Ops)
SDValue getNode (unsigned Opcode, SDLoc DL, ArrayRef< EVT > ResultTys, ArrayRef< SDValue > Ops)
SDValue getNode (unsigned Opcode, SDLoc DL, SDVTList VTs, ArrayRef< SDValue > Ops)
SDValue getNode (unsigned Opcode, SDLoc DL, SDVTList VTs)
SDValue getNode (unsigned Opcode, SDLoc DL, SDVTList VTs, SDValue N)
SDValue getNode (unsigned Opcode, SDLoc DL, SDVTList VTs, SDValue N1, SDValue N2)
SDValue getNode (unsigned Opcode, SDLoc DL, SDVTList VTs, SDValue N1, SDValue N2, SDValue N3)
SDValue getNode (unsigned Opcode, SDLoc DL, SDVTList VTs, SDValue N1, SDValue N2, SDValue N3, SDValue N4)
SDValue getNode (unsigned Opcode, SDLoc DL, SDVTList VTs, SDValue N1, SDValue N2, SDValue N3, SDValue N4, SDValue N5)
SDValue getStackArgumentTokenFactor (SDValue Chain)
SDValue getMemcpy (SDValue Chain, SDLoc dl, SDValue Dst, SDValue Src, SDValue Size, unsigned Align, bool isVol, bool AlwaysInline, MachinePointerInfo DstPtrInfo, MachinePointerInfo SrcPtrInfo)
SDValue getMemmove (SDValue Chain, SDLoc dl, SDValue Dst, SDValue Src, SDValue Size, unsigned Align, bool isVol, MachinePointerInfo DstPtrInfo, MachinePointerInfo SrcPtrInfo)
SDValue getMemset (SDValue Chain, SDLoc dl, SDValue Dst, SDValue Src, SDValue Size, unsigned Align, bool isVol, MachinePointerInfo DstPtrInfo)
SDValue getSetCC (SDLoc DL, EVT VT, SDValue LHS, SDValue RHS, ISD::CondCode Cond)
SDValue getSelect (SDLoc DL, EVT VT, SDValue Cond, SDValue LHS, SDValue RHS)
SDValue getSelectCC (SDLoc DL, SDValue LHS, SDValue RHS, SDValue True, SDValue False, ISD::CondCode Cond)
SDValue getVAArg (EVT VT, SDLoc dl, SDValue Chain, SDValue Ptr, SDValue SV, unsigned Align)
SDValue getAtomicCmpSwap (unsigned Opcode, SDLoc dl, EVT MemVT, SDVTList VTs, SDValue Chain, SDValue Ptr, SDValue Cmp, SDValue Swp, MachinePointerInfo PtrInfo, unsigned Alignment, AtomicOrdering SuccessOrdering, AtomicOrdering FailureOrdering, SynchronizationScope SynchScope)
SDValue getAtomicCmpSwap (unsigned Opcode, SDLoc dl, EVT MemVT, SDVTList VTs, SDValue Chain, SDValue Ptr, SDValue Cmp, SDValue Swp, MachineMemOperand *MMO, AtomicOrdering SuccessOrdering, AtomicOrdering FailureOrdering, SynchronizationScope SynchScope)
SDValue getAtomic (unsigned Opcode, SDLoc dl, EVT MemVT, SDValue Chain, SDValue Ptr, SDValue Val, const Value *PtrVal, unsigned Alignment, AtomicOrdering Ordering, SynchronizationScope SynchScope)
SDValue getAtomic (unsigned Opcode, SDLoc dl, EVT MemVT, SDValue Chain, SDValue Ptr, SDValue Val, MachineMemOperand *MMO, AtomicOrdering Ordering, SynchronizationScope SynchScope)
SDValue getAtomic (unsigned Opcode, SDLoc dl, EVT MemVT, EVT VT, SDValue Chain, SDValue Ptr, MachineMemOperand *MMO, AtomicOrdering Ordering, SynchronizationScope SynchScope)
SDValue getAtomic (unsigned Opcode, SDLoc dl, EVT MemVT, SDVTList VTList, ArrayRef< SDValue > Ops, MachineMemOperand *MMO, AtomicOrdering SuccessOrdering, AtomicOrdering FailureOrdering, SynchronizationScope SynchScope)
SDValue getAtomic (unsigned Opcode, SDLoc dl, EVT MemVT, SDVTList VTList, ArrayRef< SDValue > Ops, MachineMemOperand *MMO, AtomicOrdering Ordering, SynchronizationScope SynchScope)
SDValue getMemIntrinsicNode (unsigned Opcode, SDLoc dl, SDVTList VTList, ArrayRef< SDValue > Ops, EVT MemVT, MachinePointerInfo PtrInfo, unsigned Align=0, bool Vol=false, bool ReadMem=true, bool WriteMem=true, unsigned Size=0)
SDValue getMemIntrinsicNode (unsigned Opcode, SDLoc dl, SDVTList VTList, ArrayRef< SDValue > Ops, EVT MemVT, MachineMemOperand *MMO)
SDValue getMergeValues (ArrayRef< SDValue > Ops, SDLoc dl)
 getMergeValues - Create a MERGE_VALUES node from the given operands.
SDValue getLoad (EVT VT, SDLoc dl, SDValue Chain, SDValue Ptr, MachinePointerInfo PtrInfo, bool isVolatile, bool isNonTemporal, bool isInvariant, unsigned Alignment, const AAMDNodes &AAInfo=AAMDNodes(), const MDNode *Ranges=nullptr)
SDValue getLoad (EVT VT, SDLoc dl, SDValue Chain, SDValue Ptr, MachineMemOperand *MMO)
SDValue getExtLoad (ISD::LoadExtType ExtType, SDLoc dl, EVT VT, SDValue Chain, SDValue Ptr, MachinePointerInfo PtrInfo, EVT MemVT, bool isVolatile, bool isNonTemporal, bool isInvariant, unsigned Alignment, const AAMDNodes &AAInfo=AAMDNodes())
SDValue getExtLoad (ISD::LoadExtType ExtType, SDLoc dl, EVT VT, SDValue Chain, SDValue Ptr, EVT MemVT, MachineMemOperand *MMO)
SDValue getIndexedLoad (SDValue OrigLoad, SDLoc dl, SDValue Base, SDValue Offset, ISD::MemIndexedMode AM)
SDValue getLoad (ISD::MemIndexedMode AM, ISD::LoadExtType ExtType, EVT VT, SDLoc dl, SDValue Chain, SDValue Ptr, SDValue Offset, MachinePointerInfo PtrInfo, EVT MemVT, bool isVolatile, bool isNonTemporal, bool isInvariant, unsigned Alignment, const AAMDNodes &AAInfo=AAMDNodes(), const MDNode *Ranges=nullptr)
SDValue getLoad (ISD::MemIndexedMode AM, ISD::LoadExtType ExtType, EVT VT, SDLoc dl, SDValue Chain, SDValue Ptr, SDValue Offset, EVT MemVT, MachineMemOperand *MMO)
SDValue getStore (SDValue Chain, SDLoc dl, SDValue Val, SDValue Ptr, MachinePointerInfo PtrInfo, bool isVolatile, bool isNonTemporal, unsigned Alignment, const AAMDNodes &AAInfo=AAMDNodes())
SDValue getStore (SDValue Chain, SDLoc dl, SDValue Val, SDValue Ptr, MachineMemOperand *MMO)
SDValue getTruncStore (SDValue Chain, SDLoc dl, SDValue Val, SDValue Ptr, MachinePointerInfo PtrInfo, EVT TVT, bool isNonTemporal, bool isVolatile, unsigned Alignment, const AAMDNodes &AAInfo=AAMDNodes())
SDValue getTruncStore (SDValue Chain, SDLoc dl, SDValue Val, SDValue Ptr, EVT TVT, MachineMemOperand *MMO)
SDValue getIndexedStore (SDValue OrigStoe, SDLoc dl, SDValue Base, SDValue Offset, ISD::MemIndexedMode AM)
SDValue getSrcValue (const Value *v)
 getSrcValue - Construct a node to track a Value* through the backend.
SDValue getMDNode (const MDNode *MD)
 getMDNode - Return an MDNodeSDNode which holds an MDNode.
SDValue getAddrSpaceCast (SDLoc dl, EVT VT, SDValue Ptr, unsigned SrcAS, unsigned DestAS)
 getAddrSpaceCast - Return an AddrSpaceCastSDNode.
SDValue getShiftAmountOperand (EVT LHSTy, SDValue Op)
SDNodeUpdateNodeOperands (SDNode *N, SDValue Op)
SDNodeUpdateNodeOperands (SDNode *N, SDValue Op1, SDValue Op2)
SDNodeUpdateNodeOperands (SDNode *N, SDValue Op1, SDValue Op2, SDValue Op3)
SDNodeUpdateNodeOperands (SDNode *N, SDValue Op1, SDValue Op2, SDValue Op3, SDValue Op4)
SDNodeUpdateNodeOperands (SDNode *N, SDValue Op1, SDValue Op2, SDValue Op3, SDValue Op4, SDValue Op5)
SDNodeUpdateNodeOperands (SDNode *N, ArrayRef< SDValue > Ops)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT, SDValue Op1)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT, SDValue Op1, SDValue Op2)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT, SDValue Op1, SDValue Op2, SDValue Op3)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT, ArrayRef< SDValue > Ops)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT1, EVT VT2)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT1, EVT VT2, ArrayRef< SDValue > Ops)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT1, EVT VT2, EVT VT3, ArrayRef< SDValue > Ops)
SDNodeSelectNodeTo (SDNode *N, unsigned MachineOpc, EVT VT1, EVT VT2, EVT VT3, EVT VT4, ArrayRef< SDValue > Ops)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT1, EVT VT2, SDValue Op1)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT1, EVT VT2, SDValue Op1, SDValue Op2)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT1, EVT VT2, SDValue Op1, SDValue Op2, SDValue Op3)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, EVT VT1, EVT VT2, EVT VT3, SDValue Op1, SDValue Op2, SDValue Op3)
SDNodeSelectNodeTo (SDNode *N, unsigned TargetOpc, SDVTList VTs, ArrayRef< SDValue > Ops)
SDNodeMorphNodeTo (SDNode *N, unsigned Opc, SDVTList VTs, ArrayRef< SDValue > Ops)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT, SDValue Op1)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT, SDValue Op1, SDValue Op2)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT, SDValue Op1, SDValue Op2, SDValue Op3)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT, ArrayRef< SDValue > Ops)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2, SDValue Op1)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2, SDValue Op1, SDValue Op2)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2, SDValue Op1, SDValue Op2, SDValue Op3)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2, ArrayRef< SDValue > Ops)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2, EVT VT3, SDValue Op1, SDValue Op2)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2, EVT VT3, SDValue Op1, SDValue Op2, SDValue Op3)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2, EVT VT3, ArrayRef< SDValue > Ops)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, EVT VT1, EVT VT2, EVT VT3, EVT VT4, ArrayRef< SDValue > Ops)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, ArrayRef< EVT > ResultTys, ArrayRef< SDValue > Ops)
MachineSDNodegetMachineNode (unsigned Opcode, SDLoc dl, SDVTList VTs, ArrayRef< SDValue > Ops)
SDValue getTargetExtractSubreg (int SRIdx, SDLoc DL, EVT VT, SDValue Operand)
SDValue getTargetInsertSubreg (int SRIdx, SDLoc DL, EVT VT, SDValue Operand, SDValue Subreg)
SDNodegetNodeIfExists (unsigned Opcode, SDVTList VTs, ArrayRef< SDValue > Ops, bool nuw=false, bool nsw=false, bool exact=false)
SDDbgValuegetDbgValue (MDNode *MDPtr, SDNode *N, unsigned R, bool IsIndirect, uint64_t Off, DebugLoc DL, unsigned O)
SDDbgValuegetConstantDbgValue (MDNode *MDPtr, const Value *C, uint64_t Off, DebugLoc DL, unsigned O)
 Constant.
SDDbgValuegetFrameIndexDbgValue (MDNode *MDPtr, unsigned FI, uint64_t Off, DebugLoc DL, unsigned O)
 Frame index.
void RemoveDeadNode (SDNode *N)
void RemoveDeadNodes (SmallVectorImpl< SDNode * > &DeadNodes)
void ReplaceAllUsesWith (SDValue From, SDValue Op)
void ReplaceAllUsesWith (SDNode *From, SDNode *To)
void ReplaceAllUsesWith (SDNode *From, const SDValue *To)
void ReplaceAllUsesOfValueWith (SDValue From, SDValue To)
void ReplaceAllUsesOfValuesWith (const SDValue *From, const SDValue *To, unsigned Num)
unsigned AssignTopologicalOrder ()
void RepositionNode (allnodes_iterator Position, SDNode *N)
void AddDbgValue (SDDbgValue *DB, SDNode *SD, bool isParameter)
ArrayRef< SDDbgValue * > GetDbgValues (const SDNode *SD)
 GetDbgValues - Get the debug values which reference the given SDNode.
void TransferDbgValues (SDValue From, SDValue To)
 TransferDbgValues - Transfer SDDbgValues.
bool hasDebugValues () const
SDDbgInfo::DbgIterator DbgBegin ()
SDDbgInfo::DbgIterator DbgEnd ()
SDDbgInfo::DbgIterator ByvalParmDbgBegin ()
SDDbgInfo::DbgIterator ByvalParmDbgEnd ()
void dump () const
SDValue CreateStackTemporary (EVT VT, unsigned minAlign=1)
SDValue CreateStackTemporary (EVT VT1, EVT VT2)
SDValue FoldConstantArithmetic (unsigned Opcode, EVT VT, SDNode *Cst1, SDNode *Cst2)
 FoldConstantArithmetic -.
SDValue FoldSetCC (EVT VT, SDValue N1, SDValue N2, ISD::CondCode Cond, SDLoc dl)
 FoldSetCC - Constant fold a setcc to true or false.
bool SignBitIsZero (SDValue Op, unsigned Depth=0) const
bool MaskedValueIsZero (SDValue Op, const APInt &Mask, unsigned Depth=0) const
void computeKnownBits (SDValue Op, APInt &KnownZero, APInt &KnownOne, unsigned Depth=0) const
unsigned ComputeNumSignBits (SDValue Op, unsigned Depth=0) const
bool isBaseWithConstantOffset (SDValue Op) const
bool isKnownNeverNaN (SDValue Op) const
 isKnownNeverNan - Test whether the given SDValue is known to never be NaN.
bool isKnownNeverZero (SDValue Op) const
bool isEqualTo (SDValue A, SDValue B) const
SDValue UnrollVectorOp (SDNode *N, unsigned ResNE=0)
bool isConsecutiveLoad (LoadSDNode *LD, LoadSDNode *Base, unsigned Bytes, int Dist) const
unsigned InferPtrAlignment (SDValue Ptr) const
std::pair< EVT, EVTGetSplitDestVTs (const EVT &VT) const
std::pair< SDValue, SDValueSplitVector (const SDValue &N, const SDLoc &DL, const EVT &LoVT, const EVT &HiVT)
std::pair< SDValue, SDValueSplitVector (const SDValue &N, const SDLoc &DL)
std::pair< SDValue, SDValueSplitVectorOperand (const SDNode *N, unsigned OpNo)
void ExtractVectorElements (SDValue Op, SmallVectorImpl< SDValue > &Args, unsigned Start=0, unsigned Count=0)
unsigned getEVTAlignment (EVT MemoryVT) const

Static Public Member Functions

static bool isCommutativeBinOp (unsigned Opcode)
static const fltSemanticsEVTToAPFloatSemantics (EVT VT)

Public Attributes

bool NewNodesMustHaveLegalTypes
std::map< const SDNode
*, std::string > 
NodeGraphAttrs

Friends

struct DAGUpdateListener
 DAGUpdateListener is a friend so it can manipulate the listener stack.

Detailed Description

SelectionDAG class - This is used to represent a portion of an LLVM function in a low-level Data Dependence DAG representation suitable for instruction selection. This DAG is constructed as the first step of instruction selection in order to allow implementation of machine specific optimizations and code simplifications.

The representation used by the SelectionDAG is a target-independent representation, which has some similarities to the GCC RTL representation, but is significantly more simple, powerful, and is a graph form instead of a linear form.

Definition at line 169 of file SelectionDAG.h.


Member Typedef Documentation

Definition at line 314 of file SelectionDAG.h.

Definition at line 317 of file SelectionDAG.h.


Constructor & Destructor Documentation

SelectionDAG::SelectionDAG ( const TargetMachine TM,
llvm::CodeGenOpt::Level  OL 
) [explicit]

Definition at line 909 of file SelectionDAG.cpp.

References llvm::ilist< NodeTy >::push_back().

Definition at line 925 of file SelectionDAG.cpp.


Member Function Documentation

void SelectionDAG::AddDbgValue ( SDDbgValue DB,
SDNode SD,
bool  isParameter 
)

AddDbgValue - Add a dbg_value SDNode. If SD is non-null that means the value is produced by SD.

Definition at line 6174 of file SelectionDAG.cpp.

References llvm::SDDbgInfo::add(), and llvm::SDNode::setHasDebugValue().

Referenced by llvm::SelectionDAGBuilder::resolveDanglingDebugInfo(), and TransferDbgValues().

Definition at line 318 of file SelectionDAG.h.

References llvm::iplist< NodeTy, Traits >::begin().

Definition at line 319 of file SelectionDAG.h.

References llvm::iplist< NodeTy, Traits >::end().

ilist<SDNode>::size_type llvm::SelectionDAG::allnodes_size ( ) const [inline]

Definition at line 320 of file SelectionDAG.h.

References llvm::iplist< NodeTy, Traits >::size().

Referenced by AssignTopologicalOrder().

AssignTopologicalOrder - Topological-sort the AllNodes list and a assign a unique node id for each node in the DAG based on their topological order. Returns the number of nodes.

AssignTopologicalOrder - Assign a unique node id for each node in the DAG based on their topological order. It returns the maximum id and a vector of the SDNodes* in assigned order by reference.

Definition at line 6085 of file SelectionDAG.cpp.

References allnodes_begin(), allnodes_end(), allnodes_size(), llvm::iplist< NodeTy, Traits >::back(), llvm::checkForCycles(), llvm::dbgs(), llvm::SDNode::dumprFull(), llvm::iplist< NodeTy, Traits >::end(), llvm::ISD::EntryToken, llvm::iplist< NodeTy, Traits >::front(), llvm::SDNode::getNodeId(), llvm::SDNode::getNumOperands(), llvm::SDNode::getOpcode(), I, llvm::ilist< NodeTy >::insert(), llvm_unreachable, P, llvm::iplist< NodeTy, Traits >::remove(), llvm::SDNode::setNodeId(), llvm::SDNode::use_begin(), llvm::SDNode::use_empty(), and llvm::SDNode::use_end().

Referenced by Legalize().

clearGraphAttrs - Clear all previously defined node graph attributes. Intended to be used from a debugging tool (eg. gdb).

Definition at line 165 of file SelectionDAGPrinter.cpp.

References llvm::errs(), and NodeGraphAttrs.

void SelectionDAG::Combine ( CombineLevel  Level,
AliasAnalysis AA,
CodeGenOpt::Level  OptLevel 
)

This is the entry point for the file.

Combine - This iterates over the nodes in the SelectionDAG, folding certain types of nodes together, or eliminating superfluous nodes. The Level argument controls whether Combine is allowed to produce nodes and types that are illegal on the target.

This is the main entry point to this class.

Definition at line 11981 of file DAGCombiner.cpp.

void SelectionDAG::computeKnownBits ( SDValue  Op,
APInt KnownZero,
APInt KnownOne,
unsigned  Depth = 0 
) const

Determine which bits of Op are known to be either zero or one and return them in the KnownZero/KnownOne bitsets. Targets can implement the computeKnownBitsForTargetNode method in the TargetLowering class to allow target nodes to be understood.

Determine which bits of Op are known to be either zero or one and return them in the KnownZero/KnownOne bitsets.

Definition at line 1930 of file SelectionDAG.cpp.

References llvm::APInt::abs(), llvm::ISD::ADD, ADD, llvm::ISD::ADDE, Align(), llvm::ISD::AND, llvm::ISD::ANY_EXTEND, llvm::ISD::AssertZext, llvm::ISD::BUILTIN_OP_END, llvm::APInt::clearAllBits(), llvm::TargetLowering::computeKnownBitsForTargetNode(), llvm::computeKnownBitsFromRangeMetadata(), llvm::ISD::Constant, llvm::APInt::countLeadingOnes(), llvm::countLeadingZeros(), llvm::APInt::countTrailingOnes(), llvm::ISD::CTLZ, llvm::ISD::CTLZ_ZERO_UNDEF, llvm::ISD::CTPOP, llvm::ISD::CTTZ, llvm::ISD::CTTZ_ZERO_UNDEF, llvm::ISD::FGETSIGN, llvm::ISD::FrameIndex, llvm::APInt::getBitsSet(), llvm::TargetLoweringBase::getBooleanContents(), llvm::APInt::getBoolValue(), llvm::APInt::getHighBitsSet(), llvm::APInt::getLowBitsSet(), llvm::MemSDNode::getMemoryVT(), llvm::SDValue::getNode(), llvm::SDValue::getOpcode(), llvm::SDValue::getOperand(), llvm::MemSDNode::getRanges(), llvm::SDValue::getResNo(), llvm::EVT::getScalarType(), llvm::APInt::getSignBit(), llvm::EVT::getSizeInBits(), llvm::TargetMachine::getSubtargetImpl(), llvm::TargetSubtargetInfo::getTargetLowering(), llvm::SDValue::getValueType(), InferPtrAlignment(), llvm::ISD::INTRINSIC_VOID, llvm::ISD::INTRINSIC_W_CHAIN, llvm::ISD::INTRINSIC_WO_CHAIN, llvm::APInt::isPowerOf2(), llvm::EVT::isVector(), llvm::ISD::isZEXTLoad(), llvm::AArch64DB::LD, llvm::ISD::LOAD, llvm::Log2_32(), llvm::APInt::lshr(), llvm::ISD::MUL, llvm::ISD::OR, Ranges, llvm::ISD::SADDO, llvm::ISD::SELECT, llvm::ISD::SELECT_CC, llvm::ISD::SETCC, llvm::ISD::SHL, llvm::ISD::SIGN_EXTEND, llvm::ISD::SIGN_EXTEND_INREG, llvm::ISD::SMULO, llvm::ISD::SRA, llvm::ISD::SREM, llvm::ISD::SRL, llvm::ISD::SSUBO, llvm::ISD::SUB, llvm::ISD::TargetFrameIndex, llvm::ISD::TRUNCATE, llvm::ISD::UADDO, llvm::ISD::UDIV, llvm::ISD::UMULO, llvm::ISD::UREM, llvm::ISD::USUBO, llvm::ISD::XOR, llvm::ISD::ZERO_EXTEND, llvm::TargetLoweringBase::ZeroOrOneBooleanContent, and llvm::APInt::zext().

Referenced by llvm::SelectionDAGISel::CheckOrMask(), computeKnownBitsForMinMax(), llvm::SparcTargetLowering::computeKnownBitsForTargetNode(), llvm::AArch64TargetLowering::computeKnownBitsForTargetNode(), llvm::ARMTargetLowering::computeKnownBitsForTargetNode(), ComputeNumSignBits(), FoldMaskAndShiftToScale(), InferPtrAlignment(), isBitfieldInsertOpFromOr(), isBitfieldPositioningOp(), isTruncateOf(), isU24(), isWordAligned(), MaskedValueIsZero(), llvm::ARMTargetLowering::PerformCMOVCombine(), llvm::PPCTargetLowering::SelectAddressRegImm(), llvm::PPCTargetLowering::SelectAddressRegReg(), llvm::TargetLowering::SimplifyDemandedBits(), and ValueHasExactlyOneBitSet().

ComputeNumSignBits - Return the number of times the sign bit of the register is replicated into the other bits. We know that at least 1 bit is always equal to the sign bit (itself), but other cases can give us information. For example, immediately after an "SRA X, 2", we know that the top 3 bits are all equal to each other, so we return 3. Targets can implement the ComputeNumSignBitsForTarget method in the TargetLowering class to allow target nodes to be understood.

ComputeNumSignBits - Return the number of times the sign bit of the register is replicated into the other bits. We know that at least 1 bit is always equal to the sign bit (itself), but other cases can give us information. For example, immediately after an "SRA X, 2", we know that the top 3 bits are all equal to each other, so we return 3.

Definition at line 2367 of file SelectionDAG.cpp.

References llvm::ISD::ADD, llvm::ISD::AND, llvm::ISD::AssertSext, llvm::ISD::AssertZext, llvm::ISD::BUILTIN_OP_END, llvm::CallingConv::C, computeKnownBits(), llvm::TargetLowering::ComputeNumSignBitsForTargetNode(), llvm::ISD::Constant, llvm::APInt::countLeadingZeros(), llvm::APInt::getBitWidth(), llvm::TargetLoweringBase::getBooleanContents(), llvm::APInt::getNumSignBits(), llvm::SDValue::getOpcode(), llvm::SDValue::getOperand(), llvm::SDValue::getResNo(), llvm::EVT::getScalarType(), llvm::EVT::getSizeInBits(), llvm::TargetMachine::getSubtargetImpl(), llvm::TargetSubtargetInfo::getTargetLowering(), llvm::SDValue::getValueType(), llvm::ISD::INTRINSIC_VOID, llvm::ISD::INTRINSIC_W_CHAIN, llvm::ISD::INTRINSIC_WO_CHAIN, llvm::EVT::isInteger(), llvm::APInt::isNegative(), llvm::EVT::isVector(), llvm::AArch64DB::LD, llvm::ISD::OR, llvm::ISD::ROTL, llvm::ISD::ROTR, llvm::ISD::SADDO, llvm::ISD::SELECT, llvm::ISD::SETCC, llvm::ISD::SEXTLOAD, llvm::ISD::SHL, llvm::ISD::SIGN_EXTEND, llvm::ISD::SIGN_EXTEND_INREG, llvm::ISD::SMULO, llvm::ISD::SRA, llvm::ISD::SSUBO, llvm::ISD::SUB, llvm::ISD::TRUNCATE, llvm::ISD::UADDO, llvm::ISD::UMULO, llvm::ISD::USUBO, llvm::ISD::XOR, llvm::TargetLoweringBase::ZeroOrNegativeOneBooleanContent, and llvm::ISD::ZEXTLOAD.

Referenced by llvm::AMDGPUTargetLowering::ComputeNumSignBitsForTargetNode(), llvm::TargetLowering::expandMUL(), isI24(), llvm::AMDGPUTargetLowering::LowerSDIVREM(), and llvm::AMDGPUTargetLowering::PerformDAGCombine().

Definition at line 1102 of file SelectionDAG.h.

References llvm::SDDbgInfo::DbgBegin().

Referenced by llvm::ScheduleDAGSDNodes::EmitSchedule().

Definition at line 1103 of file SelectionDAG.h.

References llvm::SDDbgInfo::DbgEnd().

Referenced by llvm::ScheduleDAGSDNodes::EmitSchedule().

DeleteNode - Remove the specified node from the system. This node must have no referrers.

Definition at line 671 of file SelectionDAG.cpp.

Referenced by Legalize().

void SelectionDAG::dump ( ) const
void SelectionDAG::ExtractVectorElements ( SDValue  Op,
SmallVectorImpl< SDValue > &  Args,
unsigned  Start = 0,
unsigned  Count = 0 
)

ExtractVectorElements - Append the extracted elements from Start to Count out of the vector Op in Args. If Count is 0, all of the elements will be extracted.

Definition at line 6608 of file SelectionDAG.cpp.

References llvm::ISD::EXTRACT_VECTOR_ELT, getConstant(), getNode(), llvm::SDValue::getValueType(), llvm::EVT::getVectorElementType(), llvm::TargetLoweringBase::getVectorIdxTy(), llvm::EVT::getVectorNumElements(), and llvm::SmallVectorTemplateBase< T, isPodLike >::push_back().

SDValue SelectionDAG::FoldConstantArithmetic ( unsigned  Opcode,
EVT  VT,
SDNode Cst1,
SDNode Cst2 
)
SDValue SelectionDAG::FoldSetCC ( EVT  VT,
SDValue  N1,
SDValue  N2,
ISD::CondCode  Cond,
SDLoc  dl 
)
SDValue SelectionDAG::getAddrSpaceCast ( SDLoc  dl,
EVT  VT,
SDValue  Ptr,
unsigned  SrcAS,
unsigned  DestAS 
)

getAnyExtendVectorInReg - Return an operation which will any-extend the low lanes of the operand into the specified vector type. For example, this can convert a v16i8 into a v4i32 by any-extending the low four lanes of the operand from i8 to i32.

Definition at line 1015 of file SelectionDAG.cpp.

References llvm::ISD::ANY_EXTEND_VECTOR_INREG, getNode(), llvm::EVT::getSizeInBits(), llvm::SDValue::getValueType(), llvm::EVT::getVectorNumElements(), and llvm::EVT::isVector().

getAnyExtOrTrunc - Convert Op, which must be of integer type, to the integer type VT, by either any-extending or truncating it.

Definition at line 976 of file SelectionDAG.cpp.

References llvm::ISD::ANY_EXTEND, llvm::EVT::bitsGT(), getNode(), llvm::SDValue::getValueType(), and llvm::ISD::TRUNCATE.

Referenced by getNode().

SDValue SelectionDAG::getAtomic ( unsigned  Opcode,
SDLoc  dl,
EVT  MemVT,
SDValue  Chain,
SDValue  Ptr,
SDValue  Val,
const Value PtrVal,
unsigned  Alignment,
AtomicOrdering  Ordering,
SynchronizationScope  SynchScope 
)
SDValue SelectionDAG::getAtomic ( unsigned  Opcode,
SDLoc  dl,
EVT  MemVT,
SDValue  Chain,
SDValue  Ptr,
SDValue  Val,
MachineMemOperand MMO,
AtomicOrdering  Ordering,
SynchronizationScope  SynchScope 
)
SDValue SelectionDAG::getAtomic ( unsigned  Opcode,
SDLoc  dl,
EVT  MemVT,
EVT  VT,
SDValue  Chain,
SDValue  Ptr,
MachineMemOperand MMO,
AtomicOrdering  Ordering,
SynchronizationScope  SynchScope 
)

getAtomic - Gets a node for an atomic op, produces result and chain and takes 1 operand.

Definition at line 4530 of file SelectionDAG.cpp.

References llvm::ISD::ATOMIC_LOAD, getAtomic(), getVTList(), and llvm::MVT::Other.

SDValue SelectionDAG::getAtomic ( unsigned  Opcode,
SDLoc  dl,
EVT  MemVT,
SDVTList  VTList,
ArrayRef< SDValue Ops,
MachineMemOperand MMO,
AtomicOrdering  SuccessOrdering,
AtomicOrdering  FailureOrdering,
SynchronizationScope  SynchScope 
)
SDValue SelectionDAG::getAtomic ( unsigned  Opcode,
SDLoc  dl,
EVT  MemVT,
SDVTList  VTList,
ArrayRef< SDValue Ops,
MachineMemOperand MMO,
AtomicOrdering  Ordering,
SynchronizationScope  SynchScope 
)

Definition at line 4419 of file SelectionDAG.cpp.

References getAtomic().

SDValue SelectionDAG::getAtomicCmpSwap ( unsigned  Opcode,
SDLoc  dl,
EVT  MemVT,
SDVTList  VTs,
SDValue  Chain,
SDValue  Ptr,
SDValue  Cmp,
SDValue  Swp,
MachinePointerInfo  PtrInfo,
unsigned  Alignment,
AtomicOrdering  SuccessOrdering,
AtomicOrdering  FailureOrdering,
SynchronizationScope  SynchScope 
)

getAtomicCmpSwap - Gets a node for an atomic cmpxchg op. There are two valid Opcodes. ISD::ATOMIC_CMO_SWAP produces the value loaded and a chain result. ISD::ATOMIC_CMP_SWAP_WITH_SUCCESS produces the value loaded, a success flag (initially i1), and a chain.

Definition at line 4428 of file SelectionDAG.cpp.

References llvm::ISD::ATOMIC_CMP_SWAP, llvm::ISD::ATOMIC_CMP_SWAP_WITH_SUCCESS, getEVTAlignment(), getMachineFunction(), llvm::MachineFunction::getMachineMemOperand(), llvm::EVT::getStoreSize(), llvm::SDValue::getValueType(), llvm::MachineMemOperand::MOLoad, llvm::MachineMemOperand::MOStore, and llvm::MachineMemOperand::MOVolatile.

Referenced by ReplaceATOMIC_LOAD().

SDValue SelectionDAG::getAtomicCmpSwap ( unsigned  Opcode,
SDLoc  dl,
EVT  MemVT,
SDVTList  VTs,
SDValue  Chain,
SDValue  Ptr,
SDValue  Cmp,
SDValue  Swp,
MachineMemOperand MMO,
AtomicOrdering  SuccessOrdering,
AtomicOrdering  FailureOrdering,
SynchronizationScope  SynchScope 
)
SDValue SelectionDAG::getBlockAddress ( const BlockAddress BA,
EVT  VT,
int64_t  Offset = 0,
bool  isTarget = false,
unsigned char  TargetFlags = 0 
)
SDValue SelectionDAG::getBoolExtOrTrunc ( SDValue  Op,
SDLoc  SL,
EVT  VT,
EVT  OpVT 
)

getBoolExtOrTrunc - Convert Op, which must be of integer type, to the integer type VT, by using an extension appropriate for the target's BooleanContent for type OpVT or truncating it.

Definition at line 994 of file SelectionDAG.cpp.

References llvm::EVT::bitsLE(), llvm::TargetLoweringBase::getBooleanContents(), llvm::TargetLoweringBase::getExtendForContent(), getNode(), llvm::SDValue::getValueType(), and llvm::ISD::TRUNCATE.

Referenced by llvm::TargetLowering::SimplifySetCC().

SDValue llvm::SelectionDAG::getCALLSEQ_END ( SDValue  Chain,
SDValue  Op1,
SDValue  Op2,
SDValue  InGlue,
SDLoc  DL 
) [inline]

getCALLSEQ_START - Return a new CALLSEQ_START node, which always must have a glue result (to ensure it's not CSE'd). CALLSEQ_START does not have a useful SDLoc.

Definition at line 627 of file SelectionDAG.h.

References llvm::ISD::CALLSEQ_START, getNode(), getVTList(), llvm::MVT::Glue, and llvm::MVT::Other.

Referenced by llvm::HexagonTargetLowering::LowerCall(), llvm::SystemZTargetLowering::LowerCall(), llvm::NVPTXTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), and llvm::SparcTargetLowering::LowerGlobalTLSAddress().

Returns an ISD::VECTOR_SHUFFLE node semantically equivalent to the shuffle node in input but with swapped operands.

Example: shuffle A, B, <0,5,2,7> -> shuffle B, A, <4,1,6,3>

Definition at line 1586 of file SelectionDAG.cpp.

References llvm::ShuffleVectorSDNode::getMaskElt(), llvm::SDNode::getOperand(), llvm::SDNode::getSimpleValueType(), llvm::MVT::getVectorNumElements(), getVectorShuffle(), and llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back().

Referenced by lowerVectorShuffle().

SDValue SelectionDAG::getConstant ( uint64_t  Val,
EVT  VT,
bool  isTarget = false,
bool  isOpaque = false 
)

Definition at line 1070 of file SelectionDAG.cpp.

References llvm::EVT::getScalarType(), and llvm::EVT::getSizeInBits().

Referenced by AddCombineToVPADDL(), addIPMSequence(), adjustForSubtraction(), adjustForTestUnderMask(), adjustICmpTruncate(), adjustSubwordCmp(), adjustZeroCmp(), bitcastf32Toi32(), llvm::TargetLowering::BuildExactSDIV(), BuildIntrinsicOp(), buildRSRC(), llvm::TargetLowering::BuildSDIV(), BuildSplatI(), llvm::TargetLowering::BuildUDIV(), BuildVectorFromScalar(), ChangeVSETULTtoVSETULE(), CMPEQCombine(), combineX86ShuffleChain(), constantFoldBFE(), CreateCopyOfByValArgument(), createFPCmp(), createLoadLR(), createStoreLR(), emitCLC(), EmitCMP(), emitCmp(), emitMemMem(), emitSETCC(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForMemchr(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::ARMSelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForMemset(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemset(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForStrcmp(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForStrcpy(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForStrlen(), Expand64BitShift(), ExpandBITCAST(), expandExp(), expandExp2(), expandf64Toi32(), llvm::TargetLowering::expandFP_TO_SINT(), llvm::TargetLowering::expandMUL(), expandPow(), ExpandUnalignedLoad(), ExpandUnalignedStore(), ExtractVectorElements(), FoldConstantArithmetic(), FoldMaskAndShiftToExtract(), FoldMaskAndShiftToScale(), FoldMaskedShiftToScaledMask(), FoldSetCC(), genConstMult(), GeneratePerfectShuffle(), GenerateTBL(), getAArch64Cmp(), getAArch64XALUOOp(), getAbsolute(), getARMIndexedAddressParts(), getBoundedStrlen(), getBuildVectorSplat(), getConstant(), getCopyFromParts(), getCopyFromPartsVector(), getCopyToPartsVector(), GetExponent(), getINSERTPS(), getIntPtrConstant(), getLogicalNOT(), getMemBasePlusOffset(), getMemsetStringVal(), getMemsetValue(), getNode(), getNOT(), getPSHUFB(), getReadPerformanceCounter(), getReadTimeStampCounter(), GetSignificand(), getT2IndexedAddressParts(), getTargetConstant(), getTargetShuffleNode(), getTargetVShiftByConstNode(), getTargetVShiftNode(), getV4X86ShuffleImm8ForMask(), llvm::SelectionDAGBuilder::getValueImpl(), getVShift(), getZeroExtendInReg(), initAccumulator(), InsertFenceForAtomic(), isBLACompatibleAddress(), isConditionalZeroOrAllOnes(), IsSingleInstrConstant(), LowerADDC_ADDE_SUBC_SUBE(), LowerAsSplatVectorLoad(), LowerATOMIC_FENCE(), LowerBR_CC(), llvm::HexagonTargetLowering::LowerBR_JT(), LowerBuildVectorv16i8(), llvm::HexagonTargetLowering::LowerCall(), llvm::SystemZTargetLowering::LowerCall(), llvm::NVPTXTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), LowerCallResult(), llvm::TargetLowering::LowerCallTo(), LowerCMP_SWAP(), LowerCTLZ(), LowerCTLZ_ZERO_UNDEF(), LowerCTTZ(), llvm::AMDGPUTargetLowering::LowerDIVREM24(), llvm::HexagonTargetLowering::LowerDYNAMIC_STACKALLOC(), LowerDYNAMIC_STACKALLOC(), LowerExtendedLoad(), LowerF128Load(), LowerF128Store(), LowerFCOPYSIGN(), lowerFCOPYSIGN32(), lowerFCOPYSIGN64(), LowerFGETSIGN(), llvm::R600TargetLowering::LowerFormalArguments(), llvm::NVPTXTargetLowering::LowerFormalArguments(), llvm::SparcTargetLowering::LowerFormalArguments_32(), llvm::SparcTargetLowering::LowerFormalArguments_64(), llvm::AMDGPUTargetLowering::LowerGlobalAddress(), lowerIntegerElementInsertionVectorShuffle(), LowerInterruptReturn(), LowerINTRINSIC_W_CHAIN(), LowerINTRINSIC_WO_CHAIN(), llvm::AMDGPUTargetLowering::LowerIntrinsicIABS(), LowerIntVSETCC_AVX512(), LowerLabelRef(), llvm::AMDGPUTargetLowering::LowerLOAD(), llvm::MipsTargetLowering::lowerLOAD(), LowerLOAD_SUB(), LowerMemOpCallTo(), lowerMSABinaryBitImmIntr(), lowerMSABitClear(), lowerMSABitClearImm(), lowerMSASplatImm(), lowerMSASplatZExt(), LowerMUL_LOHI(), lowerMUL_LOHI32(), llvm::R600TargetLowering::LowerOperation(), LowerPREFETCH(), llvm::NVPTXTargetLowering::LowerReturn(), llvm::SparcTargetLowering::LowerReturn_32(), llvm::SparcTargetLowering::LowerReturn_64(), llvm::MSP430TargetLowering::LowerRETURNADDR(), llvm::HexagonTargetLowering::LowerRETURNADDR(), LowerReverse_VECTOR_SHUFFLEv16i8_v8i16(), LowerScalarImmediateShift(), LowerSDIV_v4i16(), LowerSDIV_v4i8(), llvm::AMDGPUTargetLowering::LowerSDIVREM(), LowerSELECT_CC(), llvm::MSP430TargetLowering::LowerSETCC(), LowerShift(), LowerShiftParts(), llvm::AMDGPUTargetLowering::LowerSTORE(), LowerUDIV(), LowerUMULO_SMULO(), lowerV16I8VectorShuffle(), lowerV2F64VectorShuffle(), lowerV4F32VectorShuffle(), lowerV4F64VectorShuffle(), LowerVECTOR_SHUFFLE(), lowerVECTOR_SHUFFLE_SHF(), LowerVECTOR_SHUFFLEtoBlend(), LowerVECTOR_SHUFFLEv16i8(), LowerVECTOR_SHUFFLEv8i8(), lowerVectorShuffleAsBlend(), lowerVectorShuffleAsByteRotate(), LowerVSELECTtoBlend(), LowerVSETCC(), LowerXALUO(), LowerXOR(), llvm::SparcTargetLowering::makeAddress(), MaterializeSETB(), memsetStore(), NarrowVectorLoadToElement(), NormalizeBuildVector(), OptimizeConditionalInDecrement(), PerformADCCombine(), performANDCombine(), PerformAndCombine(), PerformARMBUILD_VECTORCombine(), performBitcastCombine(), PerformBrCondCombine(), PerformCMOVCombine(), performConcatVectorsCombine(), llvm::R600TargetLowering::PerformDAGCombine(), llvm::SITargetLowering::PerformDAGCombine(), llvm::AMDGPUTargetLowering::PerformDAGCombine(), llvm::SystemZTargetLowering::PerformDAGCombine(), llvm::PPCTargetLowering::PerformDAGCombine(), performDSPShiftCombine(), PerformEXTRACT_VECTOR_ELTCombine(), performIntegerAbsCombine(), PerformINTRINSIC_WO_CHAINCombine(), PerformIntrinsicCombine(), PerformISDSETCCCombine(), PerformLOADCombine(), performMulCombine(), PerformMULCombine(), PerformMulCombine(), performORCombine(), PerformORCombine(), PerformSELECTCombine(), performSetccAddFolding(), PerformSETCCCombine(), PerformShiftCombine(), PerformSHLCombine(), performSTORECombine(), PerformSTORECombine(), PerformSubCombine(), PerformVCVTCombine(), PerformVDIVCombine(), PerformZExtCombine(), PrepareCall(), llvm::AArch64TargetLowering::ReconstructShuffle(), ReplaceATOMIC_LOAD(), llvm::R600TargetLowering::ReplaceNodeResults(), ReplaceREADCYCLECOUNTER(), replaceSplatVectorStore(), llvm::AMDGPUTargetLowering::ScalarizeVectorLoad(), llvm::AMDGPUTargetLowering::ScalarizeVectorStore(), llvm::SelectionDAGISel::SelectCodeCommon(), ShrinkLoadReplaceStoreWithStore(), llvm::TargetLowering::SimplifyDemandedBits(), llvm::TargetLowering::SimplifySetCC(), SkipExtensionForVMULL(), llvm::TargetLowering::softenSetCCOperands(), SplitVector(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), llvm::AMDGPUTargetLowering::SplitVectorStore(), TranslateX86CC(), tryCombineShiftImm(), tryCombineToEXTR(), tryExtendDUPToExtractHigh(), tryFoldToZero(), tryFormConcatFromShuffle(), tryLowerToSLI(), TryMULWIDECombine(), tryToFoldExtendOfConstant(), UnrollVectorOp(), llvm::SelectionDAGBuilder::visitBitTestCase(), llvm::SelectionDAGBuilder::visitBitTestHeader(), llvm::SelectionDAGBuilder::visitJumpTableHeader(), llvm::SelectionDAGBuilder::visitSPDescriptorParent(), llvm::SelectionDAGBuilder::visitSwitchCase(), WidenMaskArithmetic(), and WidenVector().

SDValue SelectionDAG::getConstant ( const APInt Val,
EVT  VT,
bool  isTarget = false,
bool  isOpaque = false 
)

Definition at line 1078 of file SelectionDAG.cpp.

References llvm::ConstantInt::get(), and getConstant().

SDValue SelectionDAG::getConstant ( const ConstantInt Val,
EVT  VT,
bool  isTarget = false,
bool  isOpaque = false 
)
SDDbgValue * SelectionDAG::getConstantDbgValue ( MDNode MDPtr,
const Value C,
uint64_t  Off,
DebugLoc  DL,
unsigned  O 
)

Constant.

Definition at line 5776 of file SelectionDAG.cpp.

SDValue SelectionDAG::getConstantFP ( double  Val,
EVT  VT,
bool  isTarget = false 
)
SDValue SelectionDAG::getConstantFP ( const APFloat Val,
EVT  VT,
bool  isTarget = false 
)

Definition at line 1186 of file SelectionDAG.cpp.

References llvm::ConstantFP::get(), getConstantFP(), and getContext().

SDValue SelectionDAG::getConstantFP ( const ConstantFP CF,
EVT  VT,
bool  isTarget = false 
)
SDValue SelectionDAG::getConstantPool ( const Constant C,
EVT  VT,
unsigned  Align = 0,
int  Offs = 0,
bool  isT = false,
unsigned char  TargetFlags = 0 
)
SDValue SelectionDAG::getConstantPool ( MachineConstantPoolValue C,
EVT  VT,
unsigned  Align = 0,
int  Offs = 0,
bool  isT = false,
unsigned char  TargetFlags = 0 
)

Definition at line 283 of file SelectionDAG.h.

Referenced by BuildVectorFromScalar(), canFoldInAddressingMode(), CreateStackTemporary(), llvm::SelectionDAGBuilder::EmitBranchForMergedCondition(), llvm::XCoreSelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::AArch64SelectionDAGInfo::EmitTargetCodeForMemset(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemset(), llvm::ARMSelectionDAGInfo::EmitTargetCodeForMemset(), llvm::TargetLowering::expandFP_TO_SINT(), ExpandUnalignedLoad(), ExpandUnalignedStore(), ExtractSubVector(), getConstant(), getConstantFP(), getCopyFromParts(), getCopyFromPartsVector(), getCopyToParts(), getCopyToPartsVector(), getEVTAlignment(), getMemcpy(), getMemcpyLoadsAndStores(), getMemmove(), getMemmoveLoadsAndStores(), getMemset(), getMemsetStores(), getMemsetStringVal(), GetRegistersForValue(), GetSplitDestVTs(), llvm::SelectionDAGBuilder::getValue(), llvm::SelectionDAGBuilder::getValueImpl(), getVectorMaskingNode(), llvm::SelectionDAGBuilder::init(), LowerAsSplatVectorLoad(), LowerBITCAST(), llvm::HexagonTargetLowering::LowerCall(), llvm::AMDGPUTargetLowering::LowerCall(), llvm::SystemZTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), llvm::SelectionDAGBuilder::LowerCallOperands(), llvm::HexagonTargetLowering::LowerCallResult(), llvm::AMDGPUTargetLowering::LowerDIVREM24(), LowerExtendedLoad(), llvm::SparcTargetLowering::LowerF128_LibCallArg(), llvm::SparcTargetLowering::LowerF128Compare(), llvm::SparcTargetLowering::LowerF128Op(), LowerFABSorFNEG(), LowerFCOPYSIGN(), llvm::R600TargetLowering::LowerFormalArguments(), llvm::SITargetLowering::LowerFormalArguments(), llvm::HexagonTargetLowering::LowerFormalArguments(), llvm::SystemZTargetLowering::LowerFormalArguments(), llvm::SparcTargetLowering::LowerFormalArguments_32(), llvm::SparcTargetLowering::LowerFormalArguments_64(), LowerFSINCOS(), llvm::HexagonTargetLowering::LowerReturn(), llvm::SystemZTargetLowering::LowerReturn(), llvm::SparcTargetLowering::LowerReturn_32(), llvm::SparcTargetLowering::LowerReturn_64(), LowerSIGN_EXTEND_AVX512(), LowerToTLSExecModel(), LowerVECTOR_SHUFFLE(), llvm::TargetLowering::makeLibCall(), PerformARMBUILD_VECTORCombine(), PerformBUILD_VECTORCombine(), llvm::AMDGPUTargetLowering::PerformDAGCombine(), llvm::PPCTargetLowering::PerformDAGCombine(), performExtendCombine(), PerformInsertEltCombine(), PerformLOADCombine(), performSelectCombine(), PerformSELECTCombine(), performSTORECombine(), PerformSTORECombine(), llvm::AArch64TargetLowering::ReconstructShuffle(), ReplaceLoadVector(), llvm::R600TargetLowering::ReplaceNodeResults(), llvm::PPCTargetLowering::ReplaceNodeResults(), llvm::TargetLowering::SimplifySetCC(), llvm::TargetLowering::softenSetCCOperands(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), tryFormConcatFromShuffle(), UnrollVectorOp(), llvm::TargetLowering::verifyReturnAddressArgumentIsConstant(), llvm::SelectionDAGBuilder::visitBitTestCase(), llvm::SelectionDAGBuilder::visitBitTestHeader(), llvm::SelectionDAGBuilder::visitJumpTableHeader(), llvm::SelectionDAGBuilder::visitSPDescriptorParent(), llvm::SelectionDAGBuilder::visitSwitchCase(), and XFormVExtractWithShuffleIntoLoad().

SDValue SelectionDAG::getConvertRndSat ( EVT  VT,
SDLoc  dl,
SDValue  Val,
SDValue  DTy,
SDValue  STy,
SDValue  Rnd,
SDValue  Sat,
ISD::CvtCode  Code 
)

Returns the ConvertRndSat Note: Avoid using this node because it may disappear in the future and most targets don't support it.

Definition at line 1607 of file SelectionDAG.cpp.

References AddNodeIDNode(), llvm::tgtok::Code, llvm::ISD::CONVERT_RNDSAT, llvm::ISD::CVT_FF, llvm::ISD::CVT_SS, llvm::ISD::CVT_UU, llvm::FoldingSet< T >::FindNodeOrInsertPos(), llvm::SDLoc::getDebugLoc(), llvm::SDLoc::getIROrder(), getVTList(), and llvm::FoldingSetImpl::InsertNode().

SDValue llvm::SelectionDAG::getCopyFromReg ( SDValue  Chain,
SDLoc  dl,
unsigned  Reg,
EVT  VT 
) [inline]
SDValue llvm::SelectionDAG::getCopyFromReg ( SDValue  Chain,
SDLoc  dl,
unsigned  Reg,
EVT  VT,
SDValue  Glue 
) [inline]
SDValue llvm::SelectionDAG::getCopyToReg ( SDValue  Chain,
SDLoc  dl,
unsigned  Reg,
SDValue  N 
) [inline]
SDValue llvm::SelectionDAG::getCopyToReg ( SDValue  Chain,
SDLoc  dl,
unsigned  Reg,
SDValue  N,
SDValue  Glue 
) [inline]
SDValue llvm::SelectionDAG::getCopyToReg ( SDValue  Chain,
SDLoc  dl,
SDValue  Reg,
SDValue  N,
SDValue  Glue 
) [inline]
SDDbgValue * SelectionDAG::getDbgValue ( MDNode MDPtr,
SDNode N,
unsigned  R,
bool  IsIndirect,
uint64_t  Off,
DebugLoc  DL,
unsigned  O 
)

getDbgValue - Creates a SDDbgValue node.

getDbgValue - Creates a SDDbgValue node.

SDNode

Definition at line 5768 of file SelectionDAG.cpp.

Referenced by llvm::SelectionDAGBuilder::resolveDanglingDebugInfo(), and TransferDbgValues().

GetDbgValues - Get the debug values which reference the given SDNode.

Definition at line 1091 of file SelectionDAG.h.

References llvm::SDDbgInfo::getSDDbgValues().

Referenced by ProcessSDDbgValues(), and TransferDbgValues().

SDValue SelectionDAG::getEHLabel ( SDLoc  dl,
SDValue  Root,
MCSymbol Label 
)

getEntryNode - Return the token chain corresponding to the entry of the function.

Definition at line 330 of file SelectionDAG.h.

Referenced by clear(), llvm::SelectionDAGBuilder::CopyValueToVirtualRegister(), llvm::SITargetLowering::CreateLiveInRegister(), llvm::MipsTargetLowering::getAddrLocal(), getFLUSHW(), getFRAMEADDR(), getMemCmpLoad(), getStackArgumentTokenFactor(), llvm::SelectionDAGBuilder::getValue(), llvm::SelectionDAGBuilder::getValueImpl(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerF128Compare(), llvm::SparcTargetLowering::LowerF128Op(), LowerFABSorFNEG(), LowerFCOPYSIGN(), llvm::SparcTargetLowering::LowerFormalArguments_32(), llvm::MSP430TargetLowering::LowerFRAMEADDR(), llvm::HexagonTargetLowering::LowerFRAMEADDR(), LowerFSINCOS(), llvm::AMDGPUTargetLowering::LowerGlobalAddress(), llvm::SparcTargetLowering::LowerGlobalTLSAddress(), LowerINTRINSIC_W_CHAIN(), llvm::R600TargetLowering::LowerOperation(), llvm::MSP430TargetLowering::LowerRETURNADDR(), llvm::HexagonTargetLowering::LowerRETURNADDR(), LowerRETURNADDR(), llvm::MSP430TargetLowering::LowerSETCC(), LowerSIGN_EXTEND_AVX512(), LowerToTLSExecModel(), LowerToTLSGeneralDynamicModel32(), LowerToTLSGeneralDynamicModel64(), LowerToTLSLocalDynamicModel(), LowerVectorBroadcast(), LowerZERO_EXTEND_AVX512(), llvm::SparcTargetLowering::makeAddress(), llvm::TargetLowering::makeLibCall(), performDivRemCombine(), PerformEXTRACT_VECTOR_ELTCombine(), ReplaceREADCYCLECOUNTER(), llvm::SelectionDAGISel::SelectCodeCommon(), and llvm::SelectionDAGBuilder::visitSPDescriptorParent().

SDValue SelectionDAG::getExtLoad ( ISD::LoadExtType  ExtType,
SDLoc  dl,
EVT  VT,
SDValue  Chain,
SDValue  Ptr,
MachinePointerInfo  PtrInfo,
EVT  MemVT,
bool  isVolatile,
bool  isNonTemporal,
bool  isInvariant,
unsigned  Alignment,
const AAMDNodes AAInfo = AAMDNodes() 
)
SDValue SelectionDAG::getExtLoad ( ISD::LoadExtType  ExtType,
SDLoc  dl,
EVT  VT,
SDValue  Chain,
SDValue  Ptr,
EVT  MemVT,
MachineMemOperand MMO 
)
SDValue SelectionDAG::getFrameIndex ( int  FI,
EVT  VT,
bool  isTarget = false 
)
SDDbgValue * SelectionDAG::getFrameIndexDbgValue ( MDNode MDPtr,
unsigned  FI,
uint64_t  Off,
DebugLoc  DL,
unsigned  O 
)

Frame index.

FrameIndex.

Definition at line 5784 of file SelectionDAG.cpp.

getGLOBAL_OFFSET_TABLE - Return a GLOBAL_OFFSET_TABLE node. This does not have a useful SDLoc.

Definition at line 655 of file SelectionDAG.h.

References getNode(), and llvm::ISD::GLOBAL_OFFSET_TABLE.

Referenced by llvm::TargetLowering::getPICJumpTableRelocBase().

SDValue SelectionDAG::getGlobalAddress ( const GlobalValue GV,
SDLoc  DL,
EVT  VT,
int64_t  offset = 0,
bool  isTargetGA = false,
unsigned char  TargetFlags = 0 
)
const std::string SelectionDAG::getGraphAttrs ( const SDNode N) const

getGraphAttrs - Get graph attributes for a node. (eg. "color=red".) Used from getNodeAttributes.

Definition at line 189 of file SelectionDAGPrinter.cpp.

References llvm::errs(), I, and NodeGraphAttrs.

Referenced by llvm::DOTGraphTraits< SelectionDAG * >::getNodeAttributes().

SDValue SelectionDAG::getIndexedLoad ( SDValue  OrigLoad,
SDLoc  dl,
SDValue  Base,
SDValue  Offset,
ISD::MemIndexedMode  AM 
)
SDValue SelectionDAG::getIndexedStore ( SDValue  OrigStoe,
SDLoc  dl,
SDValue  Base,
SDValue  Offset,
ISD::MemIndexedMode  AM 
)
SDValue SelectionDAG::getIntPtrConstant ( uint64_t  Val,
bool  isTarget = false 
)

Definition at line 1179 of file SelectionDAG.cpp.

References getConstant(), llvm::TargetLoweringBase::getPointerTy(), llvm::TargetMachine::getSubtargetImpl(), and llvm::TargetSubtargetInfo::getTargetLowering().

Referenced by buildFromShuffleMostly(), CMPEQCombine(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemset(), ExtractSubVector(), getCopyToParts(), getFRAMEADDR(), getINSERTPS(), InsertSubVector(), LowerBITCAST(), LowerBuildVectorv16i8(), LowerBuildVectorv4x32(), LowerBuildVectorv8i16(), llvm::HexagonTargetLowering::LowerCall(), llvm::SystemZTargetLowering::LowerCall(), llvm::NVPTXTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), LowerCONCAT_VECTORS(), lowerCTPOP16BitElements(), lowerCTPOP32BitElements(), llvm::HexagonTargetLowering::LowerEH_RETURN(), LowerExtendedLoad(), LowerFCOPYSIGN(), llvm::SystemZTargetLowering::LowerFormalArguments(), llvm::NVPTXTargetLowering::LowerFormalArguments(), LowerFSINCOS(), llvm::SparcTargetLowering::LowerGlobalTLSAddress(), LowerINTRINSIC_W_CHAIN(), llvm::NVPTXTargetLowering::LowerReturn(), LowerRETURNADDR(), LowerScalarVariableShift(), LowerSDIV(), LowerToTLSExecModel(), LowerUDIV(), LowerUMULO_SMULO(), LowerVAARG(), LowerVACOPY(), LowerVASTART(), LowerVECTOR_SHUFFLE_256(), LowerVECTOR_SHUFFLEv16i8(), LowerVECTOR_SHUFFLEv8i16(), LowerVectorINT_TO_FP(), LowerVectorIntExtend(), llvm::PPCTargetLowering::PerformDAGCombine(), performExtendCombine(), performSTORECombine(), PerformSTORECombine(), PrepareCall(), PrepareTailCall(), llvm::AArch64TargetLowering::ReconstructShuffle(), ReplaceLoadVector(), llvm::PPCTargetLowering::ReplaceNodeResults(), and splitAndLower256BitVectorShuffle().

SDValue SelectionDAG::getJumpTable ( int  JTI,
EVT  VT,
bool  isTarget = false,
unsigned char  TargetFlags = 0 
)
SDValue SelectionDAG::getLoad ( EVT  VT,
SDLoc  dl,
SDValue  Chain,
SDValue  Ptr,
MachinePointerInfo  PtrInfo,
bool  isVolatile,
bool  isNonTemporal,
bool  isInvariant,
unsigned  Alignment,
const AAMDNodes AAInfo = AAMDNodes(),
const MDNode Ranges = nullptr 
)

getLoad - Loads are not normal binary operators: their result type is not determined by their operands, and they produce a value AND a token chain.

Definition at line 4734 of file SelectionDAG.cpp.

References getUNDEF(), llvm::SDValue::getValueType(), llvm::ISD::NON_EXTLOAD, llvm::RegState::Undef, and llvm::ISD::UNINDEXED.

Referenced by bitcastf32Toi32(), convertLocVTToValVT(), EltsFromConsecutiveLoads(), llvm::ARMSelectionDAGInfo::EmitTargetCodeForMemcpy(), expandf64Toi32(), ExpandUnalignedLoad(), ExpandUnalignedStore(), llvm::MipsTargetLowering::getAddrGlobal(), llvm::MipsTargetLowering::getAddrGlobalLargeGOT(), llvm::MipsTargetLowering::getAddrLocal(), getExtLoad(), getFRAMEADDR(), getIndexedLoad(), getLoad(), getMemCmpLoad(), getMemmoveLoadsAndStores(), LowerAsSplatVectorLoad(), llvm::HexagonTargetLowering::LowerBR_JT(), llvm::NVPTXTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), llvm::TargetLowering::LowerCallTo(), LowerExtendedLoad(), LowerF128Load(), llvm::SparcTargetLowering::LowerF128Op(), LowerFABSorFNEG(), LowerFCOPYSIGN(), llvm::R600TargetLowering::LowerFormalArguments(), llvm::HexagonTargetLowering::LowerFormalArguments(), llvm::SystemZTargetLowering::LowerFormalArguments(), llvm::NVPTXTargetLowering::LowerFormalArguments(), llvm::SparcTargetLowering::LowerFormalArguments_32(), llvm::SparcTargetLowering::LowerFormalArguments_64(), llvm::MSP430TargetLowering::LowerFRAMEADDR(), llvm::HexagonTargetLowering::LowerFRAMEADDR(), LowerINTRINSIC_W_CHAIN(), lowerMSALoadIntr(), llvm::MSP430TargetLowering::LowerRETURNADDR(), llvm::HexagonTargetLowering::LowerRETURNADDR(), LowerRETURNADDR(), LowerSIGN_EXTEND_AVX512(), LowerToTLSExecModel(), LowerVAARG(), LowerVectorBroadcast(), LowerZERO_EXTEND_AVX512(), llvm::SparcTargetLowering::makeAddress(), NarrowVectorLoadToElement(), PerformEXTRACT_VECTOR_ELTCombine(), performIntToFpCombine(), PerformLOADCombine(), PerformSTORECombine(), llvm::TargetLowering::SimplifySetCC(), SkipLoadExtensionForVMULL(), and llvm::SelectionDAGBuilder::visitSPDescriptorParent().

SDValue SelectionDAG::getLoad ( EVT  VT,
SDLoc  dl,
SDValue  Chain,
SDValue  Ptr,
MachineMemOperand MMO 
)
SDValue SelectionDAG::getLoad ( ISD::MemIndexedMode  AM,
ISD::LoadExtType  ExtType,
EVT  VT,
SDLoc  dl,
SDValue  Chain,
SDValue  Ptr,
SDValue  Offset,
MachinePointerInfo  PtrInfo,
EVT  MemVT,
bool  isVolatile,
bool  isNonTemporal,
bool  isInvariant,
unsigned  Alignment,
const AAMDNodes AAInfo = AAMDNodes(),
const MDNode Ranges = nullptr 
)
SDValue SelectionDAG::getLoad ( ISD::MemIndexedMode  AM,
ISD::LoadExtType  ExtType,
EVT  VT,
SDLoc  dl,
SDValue  Chain,
SDValue  Ptr,
SDValue  Offset,
EVT  MemVT,
MachineMemOperand MMO 
)

Definition at line 278 of file SelectionDAG.h.

Referenced by CalculateTailCallSPDiff(), llvm::AMDGPUTargetLowering::CreateLiveInRegister(), CreateStackTemporary(), ExpandPowI(), llvm::SelectionDAGBuilder::FindMergedConditions(), FindOptimalMemOpLowering(), fixupFuncForFI(), getAtomic(), getAtomicCmpSwap(), getFRAMEADDR(), llvm::MipsTargetLowering::getGlobalReg(), llvm::DOTGraphTraits< SelectionDAG * >::getGraphName(), getLoad(), getMemcpyLoadsAndStores(), getMemIntrinsicNode(), getMemmoveLoadsAndStores(), getMemsetStores(), GetRegistersForValue(), llvm::MSP430TargetLowering::getReturnAddressFrameIndex(), llvm::SparcTargetLowering::getSRetArgSize(), getStore(), GetTLSADDR(), getTruncStore(), hasReturnsTwiceAttr(), InferPtrAlignment(), isConsecutiveLoad(), isConsecutiveLSLoc(), llvm::HexagonTargetLowering::IsEligibleForTailCallOptimization(), llvm::TargetLowering::isInTailCallPosition(), LowerAsSplatVectorLoad(), llvm::HexagonTargetLowering::LowerBR_JT(), llvm::HexagonTargetLowering::LowerCall(), llvm::AMDGPUTargetLowering::LowerCall(), llvm::SystemZTargetLowering::LowerCall(), llvm::NVPTXTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), llvm::HexagonTargetLowering::LowerCallResult(), llvm::SelectionDAGBuilder::LowerCallTo(), llvm::TargetLowering::LowerCallTo(), llvm::HexagonTargetLowering::LowerEH_RETURN(), llvm::SparcTargetLowering::LowerF128_LibCallArg(), llvm::SparcTargetLowering::LowerF128Op(), llvm::R600TargetLowering::LowerFormalArguments(), llvm::SITargetLowering::LowerFormalArguments(), llvm::HexagonTargetLowering::LowerFormalArguments(), llvm::SystemZTargetLowering::LowerFormalArguments(), llvm::NVPTXTargetLowering::LowerFormalArguments(), llvm::SparcTargetLowering::LowerFormalArguments_32(), llvm::SparcTargetLowering::LowerFormalArguments_64(), llvm::MSP430TargetLowering::LowerFRAMEADDR(), llvm::HexagonTargetLowering::LowerFRAMEADDR(), llvm::AMDGPUTargetLowering::LowerGlobalAddress(), llvm::SparcTargetLowering::LowerGlobalTLSAddress(), llvm::HexagonTargetLowering::LowerINLINEASM(), LowerInterruptReturn(), LowerINTRINSIC_W_CHAIN(), llvm::R600TargetLowering::LowerOperation(), llvm::SITargetLowering::LowerOperation(), llvm::HexagonTargetLowering::LowerReturn(), llvm::SystemZTargetLowering::LowerReturn(), llvm::NVPTXTargetLowering::LowerReturn(), llvm::SparcTargetLowering::LowerReturn_32(), llvm::SparcTargetLowering::LowerReturn_64(), llvm::MSP430TargetLowering::LowerRETURNADDR(), llvm::HexagonTargetLowering::LowerRETURNADDR(), LowerRETURNADDR(), LowerToTLSLocalDynamicModel(), llvm::MSP430TargetLowering::LowerVASTART(), llvm::HexagonTargetLowering::LowerVASTART(), LowerVASTART(), llvm::SparcTargetLowering::makeAddress(), NarrowVectorLoadToElement(), PerformADDCombineWithOperands(), llvm::PPCTargetLowering::PerformDAGCombine(), PerformOrCombine(), performSTORECombine(), PerformSTORECombine(), PrepareTailCall(), and viewGraph().

getMachineNode - These are used for target selectors to create a new node with specified return type(s), MachineInstr opcode, and operands.

Note that getMachineNode returns the resultant node. If there is already a node of the specified opcode and operands, it returns that node instead of the current one.

Definition at line 5569 of file SelectionDAG.cpp.

References getVTList(), and llvm::None.

Referenced by buildRSRC(), getLeftShift(), getMachineNode(), getPrefetchNode(), getScatterNode(), getTargetExtractSubreg(), getTargetInsertSubreg(), LowerATOMIC_FENCE(), LowerBITCAST(), LowerF128Load(), LowerF128Store(), LowerF64Op(), LowerFNEGorFABS(), lowerGR128Binary(), llvm::R600TargetLowering::LowerOperation(), narrowIfNeeded(), performBitcastCombine(), ReplaceBITCASTResults(), llvm::PPCTargetLowering::SelectAddressRegImm(), llvm::SelectionDAGISel::SelectCodeCommon(), Widen(), and wrapAddr64Rsrc().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT,
SDValue  Op1 
)

Definition at line 5575 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT,
SDValue  Op1,
SDValue  Op2 
)

Definition at line 5582 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT,
SDValue  Op1,
SDValue  Op2,
SDValue  Op3 
)

Definition at line 5590 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

Definition at line 5598 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2 
)

Definition at line 5605 of file SelectionDAG.cpp.

References getMachineNode(), getVTList(), and llvm::None.

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2,
SDValue  Op1 
)

Definition at line 5611 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2,
SDValue  Op1,
SDValue  Op2 
)

Definition at line 5619 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2,
SDValue  Op1,
SDValue  Op2,
SDValue  Op3 
)

Definition at line 5627 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2,
ArrayRef< SDValue Ops 
)

Definition at line 5636 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2,
EVT  VT3,
SDValue  Op1,
SDValue  Op2 
)

Definition at line 5644 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2,
EVT  VT3,
SDValue  Op1,
SDValue  Op2,
SDValue  Op3 
)

Definition at line 5653 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2,
EVT  VT3,
ArrayRef< SDValue Ops 
)

Definition at line 5662 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
EVT  VT1,
EVT  VT2,
EVT  VT3,
EVT  VT4,
ArrayRef< SDValue Ops 
)

Definition at line 5670 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

MachineSDNode * SelectionDAG::getMachineNode ( unsigned  Opcode,
SDLoc  dl,
ArrayRef< EVT ResultTys,
ArrayRef< SDValue Ops 
)

Definition at line 5678 of file SelectionDAG.cpp.

References getMachineNode(), and getVTList().

SDValue SelectionDAG::getMemcpy ( SDValue  Chain,
SDLoc  dl,
SDValue  Dst,
SDValue  Src,
SDValue  Size,
unsigned  Align,
bool  isVol,
bool  AlwaysInline,
MachinePointerInfo  DstPtrInfo,
MachinePointerInfo  SrcPtrInfo 
)
SDValue SelectionDAG::getMemIntrinsicNode ( unsigned  Opcode,
SDLoc  dl,
SDVTList  VTList,
ArrayRef< SDValue Ops,
EVT  MemVT,
MachinePointerInfo  PtrInfo,
unsigned  Align = 0,
bool  Vol = false,
bool  ReadMem = true,
bool  WriteMem = true,
unsigned  Size = 0 
)
SDValue SelectionDAG::getMemIntrinsicNode ( unsigned  Opcode,
SDLoc  dl,
SDVTList  VTList,
ArrayRef< SDValue Ops,
EVT  MemVT,
MachineMemOperand MMO 
)
SDValue SelectionDAG::getMemmove ( SDValue  Chain,
SDLoc  dl,
SDValue  Dst,
SDValue  Src,
SDValue  Size,
unsigned  Align,
bool  isVol,
MachinePointerInfo  DstPtrInfo,
MachinePointerInfo  SrcPtrInfo 
)
SDValue SelectionDAG::getMemset ( SDValue  Chain,
SDLoc  dl,
SDValue  Dst,
SDValue  Src,
SDValue  Size,
unsigned  Align,
bool  isVol,
MachinePointerInfo  DstPtrInfo 
)
SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
EVT  VT 
)

getNode - Gets or creates the specified node.

Definition at line 2655 of file SelectionDAG.cpp.

References AddNodeIDNode(), llvm::FoldingSet< T >::FindNodeOrInsertPos(), llvm::SDLoc::getDebugLoc(), llvm::SDLoc::getIROrder(), getVTList(), llvm::FoldingSetImpl::InsertNode(), and llvm::None.

Referenced by AddCombineTo64bitMLAL(), AddCombineToVPADDL(), addIPMSequence(), AddRequiredExtensionForVMULL(), llvm::TargetLowering::BuildExactSDIV(), buildFromShuffleMostly(), BuildIntrinsicOp(), llvm::TargetLowering::BuildSDIV(), BuildSplatI(), llvm::TargetLowering::BuildUDIV(), BuildVectorFromScalar(), BuildVSLDOI(), ChangeVSETULTtoVSETULE(), CMPEQCombine(), llvm::AMDGPUTargetLowering::CombineMinMax(), combineRedundantDWordShuffle(), combineRedundantHalfShuffle(), combineSelectAndUse(), combineShuffleToAddSub(), combineX86ShuffleChain(), Compact8x32ShuffleNode(), CompactSwizzlableVector(), convertLocVTToValVT(), ConvertSelectToConcatVector(), convertValVTToLocVT(), createCMovFP(), createFPCmp(), createLoadLR(), createStoreLR(), EltsFromConsecutiveLoads(), emitCLC(), EmitCMP(), emitCmp(), emitComparison(), emitMemMem(), emitSETCC(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForMemchr(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::ARMSelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForMemset(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemset(), llvm::ARMSelectionDAGInfo::EmitTargetCodeForMemset(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForStrcmp(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForStrcpy(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForStrnlen(), EmitVectorComparison(), Expand64BitShift(), ExpandBITCAST(), ExpandBVWithShuffles(), expandExp(), expandExp2(), expandf64Toi32(), llvm::TargetLowering::expandFP_TO_SINT(), ExpandHorizontalBinOp(), expandLog(), expandLog10(), expandLog2(), llvm::TargetLowering::expandMUL(), expandPow(), ExpandPowI(), ExpandUnalignedLoad(), ExpandUnalignedStore(), extractLOHI(), ExtractSubVector(), ExtractVectorElements(), FoldConstantArithmetic(), FoldMaskAndShiftToExtract(), FoldMaskAndShiftToScale(), FoldMaskedShiftToScaledMask(), genConstMult(), GeneratePerfectShuffle(), GenerateTBL(), getAArch64Cmp(), getAArch64XALUOOp(), getAbsolute(), llvm::MipsTargetLowering::getAddrGlobal(), llvm::MipsTargetLowering::getAddrGlobalLargeGOT(), llvm::MipsTargetLowering::getAddrLocal(), llvm::MipsTargetLowering::getAddrNonPIC(), getAnyExtendVectorInReg(), getAnyExtOrTrunc(), getBoolExtOrTrunc(), getBoundedStrlen(), getBuildVectorSplat(), getCALLSEQ_END(), getCALLSEQ_START(), getConstant(), getConstantFP(), llvm::SelectionDAGBuilder::getControlRoot(), getCopyFromParts(), getCopyFromPartsVector(), getCopyFromReg(), getCopyToParts(), getCopyToPartsVector(), getCopyToReg(), getCTPOP16BitCounts(), GetExponent(), getFLUSHW(), getFRAMEADDR(), getGatherNode(), getGLOBAL_OFFSET_TABLE(), getINSERTPS(), getLegalSplat(), getLogicalNOT(), getMemBasePlusOffset(), getMemcpyLoadsAndStores(), getMemmoveLoadsAndStores(), getMemsetStores(), getMemsetStringVal(), getMemsetValue(), getMergeValues(), getMOVDDup(), getMOVLowToHigh(), GetNegatedExpression(), getNode(), getNOT(), getOnesVector(), getPrefetchNode(), getPSHUFB(), getReadPerformanceCounter(), getReadTimeStampCounter(), GetRegistersForValue(), llvm::SelectionDAGBuilder::getRoot(), getScatterNode(), getSelect(), getSelectCC(), getSetCC(), getSExtOrTrunc(), getShiftAmountOperand(), getSignExtendVectorInReg(), GetSignificand(), getStackArgumentTokenFactor(), getTargetShuffleNode(), getTargetVShiftByConstNode(), getTargetVShiftNode(), GetTLSADDR(), getUNDEF(), getVAArg(), llvm::SelectionDAGBuilder::getValueImpl(), getVectorMaskingNode(), getVShift(), getVZextMovL(), getZeroExtendInReg(), getZeroExtendVectorInReg(), getZeroVector(), getZExtOrTrunc(), HandleMergeInputChains(), initAccumulator(), InsertFenceForAtomic(), InsertSubVector(), isLoadIncOrDecStore(), Lower256IntArith(), Lower256IntVSETCC(), LowerADDC_ADDE_SUBC_SUBE(), LowerAsSplatVectorLoad(), llvm::HexagonTargetLowering::LowerATOMIC_FENCE(), LowerATOMIC_FENCE(), LowerAVXExtend(), LowerBITCAST(), llvm::MSP430TargetLowering::LowerBlockAddress(), llvm::HexagonTargetLowering::LowerBlockAddress(), llvm::MSP430TargetLowering::LowerBR_CC(), LowerBR_CC(), llvm::HexagonTargetLowering::LowerBR_JT(), LowerBuildVectorv16i8(), LowerBuildVectorv4x32(), LowerBuildVectorv8i16(), llvm::HexagonTargetLowering::LowerCall(), llvm::SystemZTargetLowering::LowerCall(), llvm::NVPTXTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), LowerCallResult(), llvm::TargetLowering::LowerCallTo(), LowerCMP_SWAP(), LowerCONCAT_VECTORS(), llvm::HexagonTargetLowering::LowerConstantPool(), LowerConstantPool(), LowerCTLZ(), LowerCTLZ_ZERO_UNDEF(), lowerCTPOP16BitElements(), lowerCTPOP32BitElements(), LowerCTTZ(), llvm::AMDGPUTargetLowering::LowerDIVREM24(), lowerDSPIntr(), llvm::HexagonTargetLowering::LowerDYNAMIC_STACKALLOC(), LowerDYNAMIC_STACKALLOC(), llvm::HexagonTargetLowering::LowerEH_RETURN(), LowerExtendedLoad(), llvm::MSP430TargetLowering::LowerExternalSymbol(), LowerEXTRACT_VECTOR_ELT(), LowerEXTRACT_VECTOR_ELT_SSE4(), llvm::SparcTargetLowering::LowerF128Compare(), LowerF128Load(), LowerF128Store(), LowerF64Op(), LowerFABSorFNEG(), LowerFCOPYSIGN(), lowerFCOPYSIGN32(), lowerFCOPYSIGN64(), LowerFGETSIGN(), LowerFNEGorFABS(), llvm::SITargetLowering::LowerFormalArguments(), llvm::HexagonTargetLowering::LowerFormalArguments(), llvm::SystemZTargetLowering::LowerFormalArguments(), llvm::NVPTXTargetLowering::LowerFormalArguments(), llvm::SparcTargetLowering::LowerFormalArguments_32(), llvm::SparcTargetLowering::LowerFormalArguments_64(), LowerFP_EXTEND(), LowerFP_TO_SINT(), lowerFP_TO_SINT_STORE(), LowerFSINCOS(), llvm::MSP430TargetLowering::LowerGlobalAddress(), llvm::HexagonTargetLowering::LowerGLOBALADDRESS(), llvm::NVPTXTargetLowering::LowerGlobalAddress(), llvm::SparcTargetLowering::LowerGlobalTLSAddress(), lowerGR128Binary(), lowerIntegerElementInsertionVectorShuffle(), LowerInterruptReturn(), LowerINTRINSIC_W_CHAIN(), LowerINTRINSIC_WO_CHAIN(), llvm::AMDGPUTargetLowering::LowerIntrinsicIABS(), llvm::AMDGPUTargetLowering::LowerIntrinsicLRP(), LowerIntVSETCC_AVX512(), llvm::MSP430TargetLowering::LowerJumpTable(), LowerLabelRef(), llvm::AMDGPUTargetLowering::LowerLOAD(), llvm::MipsTargetLowering::lowerLOAD(), LowerLOAD_SUB(), LowerMemOpCallTo(), lowerMSABinaryBitImmIntr(), lowerMSABitClear(), lowerMSABitClearImm(), lowerMSACopyIntr(), lowerMSALoadIntr(), lowerMSASplatZExt(), lowerMSAStoreIntr(), LowerMUL(), LowerMUL_LOHI(), lowerMUL_LOHI32(), llvm::R600TargetLowering::LowerOperation(), LowerPREFETCH(), llvm::AMDGPUTargetLowering::LowerReturn(), llvm::HexagonTargetLowering::LowerReturn(), llvm::SystemZTargetLowering::LowerReturn(), llvm::NVPTXTargetLowering::LowerReturn(), llvm::SparcTargetLowering::LowerReturn_32(), llvm::SparcTargetLowering::LowerReturn_64(), llvm::MSP430TargetLowering::LowerRETURNADDR(), llvm::HexagonTargetLowering::LowerRETURNADDR(), LowerRETURNADDR(), LowerReverse_VECTOR_SHUFFLEv16i8_v8i16(), LowerSCALAR_TO_VECTOR(), LowerScalarImmediateShift(), LowerScalarVariableShift(), LowerSDIV(), LowerSDIV_v4i16(), LowerSDIV_v4i8(), llvm::AMDGPUTargetLowering::LowerSDIVREM(), llvm::MSP430TargetLowering::LowerSELECT_CC(), LowerSELECT_CC(), llvm::MSP430TargetLowering::LowerSETCC(), LowerShift(), LowerShiftParts(), llvm::MSP430TargetLowering::LowerShifts(), llvm::MSP430TargetLowering::LowerSIGN_EXTEND(), LowerSIGN_EXTEND(), LowerSIGN_EXTEND_AVX512(), LowerSINT_TO_FP(), llvm::AMDGPUTargetLowering::LowerSTORE(), LowerToTLSExecModel(), LowerToTLSGeneralDynamicModel32(), LowerToTLSLocalDynamicModel(), LowerUDIV(), LowerUMULO_SMULO(), lowerV16I8VectorShuffle(), lowerV2F64VectorShuffle(), lowerV2I64VectorShuffle(), lowerV4F32VectorShuffle(), lowerV4F64VectorShuffle(), lowerV4I32VectorShuffle(), lowerV4I64VectorShuffle(), lowerV8I16BasicBlendVectorShuffle(), lowerV8I16SingleInputVectorShuffle(), lowerV8I16VectorShuffle(), LowerVAARG(), LowerVASTART(), LowerVECTOR_SHUFFLE(), LowerVECTOR_SHUFFLE_256(), lowerVECTOR_SHUFFLE_ILVEV(), lowerVECTOR_SHUFFLE_ILVL(), lowerVECTOR_SHUFFLE_ILVOD(), lowerVECTOR_SHUFFLE_ILVR(), lowerVECTOR_SHUFFLE_PCKEV(), lowerVECTOR_SHUFFLE_PCKOD(), lowerVECTOR_SHUFFLE_SHF(), lowerVECTOR_SHUFFLE_VSHF(), LowerVECTOR_SHUFFLEtoBlend(), LowerVECTOR_SHUFFLEv16i8(), LowerVECTOR_SHUFFLEv8i16(), LowerVECTOR_SHUFFLEv8i8(), LowerVectorAllZeroTest(), LowerVectorBroadcast(), LowerVectorFP_TO_INT(), LowerVectorINT_TO_FP(), LowerVectorIntExtend(), lowerVectorShuffle(), lowerVectorShuffleAsBlend(), lowerVectorShuffleAsByteRotate(), LowerVSELECTtoBlend(), LowerVSETCC(), LowerXALUO(), LowerXOR(), LowerZERO_EXTEND_AVX512(), llvm::SparcTargetLowering::makeAddress(), llvm::SparcTargetLowering::makeHiLoPair(), matchAddSub(), MaterializeSETB(), MoveBelowOrigChain(), NarrowVectorLoadToElement(), NormalizeBuildVector(), NormalizeVectorShuffle(), OptimizeConditionalInDecrement(), partitionShuffleOfConcats(), PerformADCCombine(), performADDCombine(), PerformAddCombine(), PerformADDCombineWithOperands(), performAddSubLongCombine(), performANDCombine(), PerformANDCombine(), PerformAndCombine(), PerformARMBUILD_VECTORCombine(), PerformBFICombine(), performBitcastCombine(), performBRCONDCombine(), PerformBrCondCombine(), PerformBUILD_VECTORCombine(), llvm::ARMTargetLowering::PerformCMOVCombine(), PerformCMOVCombine(), performConcatVectorsCombine(), performCONDCombine(), llvm::R600TargetLowering::PerformDAGCombine(), llvm::SITargetLowering::PerformDAGCombine(), llvm::AMDGPUTargetLowering::PerformDAGCombine(), llvm::SystemZTargetLowering::PerformDAGCombine(), llvm::PPCTargetLowering::PerformDAGCombine(), performDivRemCombine(), performDSPShiftCombine(), performExtendCombine(), PerformExtendCombine(), PerformEXTRACT_VECTOR_ELTCombine(), PerformFADDCombine(), PerformFMACombine(), PerformFMinFMaxCombine(), PerformFSUBCombine(), PerformInsertEltCombine(), PerformINSERTPSCombine(), performIntegerAbsCombine(), PerformINTRINSIC_WO_CHAINCombine(), performIntrinsicCombine(), PerformIntrinsicCombine(), performIntToFpCombine(), PerformISDSETCCCombine(), PerformLOADCombine(), performMulCombine(), PerformMULCombine(), PerformMulCombine(), performORCombine(), PerformORCombine(), PerformOrCombine(), PerformSELECT_CCCombine(), performSELECTCombine(), performSelectCombine(), PerformSELECTCombine(), performSetccAddFolding(), performSETCCCombine(), PerformSETCCCombine(), PerformShiftCombine(), PerformSHLCombine(), PerformShuffleCombine(), PerformShuffleCombine256(), PerformSIGN_EXTEND_INREGCombine(), PerformSINT_TO_FPCombine(), performSRACombine(), performSTORECombine(), PerformSTORECombine(), PerformSubCombine(), PerformTargetShuffleCombine(), PerformVCVTCombine(), PerformVDIVCombine(), PerformVDUPLANECombine(), PerformVECTOR_SHUFFLECombine(), performVectorCompareAndMaskUnaryOpCombine(), PerformVMOVDRRCombine(), PerformVMULCombine(), performVSELECTCombine(), performVSelectCombine(), PerformVZEXT_MOVLCombine(), performVZEXTCombine(), performXORCombine(), PerformZExtCombine(), PrepareCall(), PrepareTailCall(), llvm::SystemZTargetLowering::prepareVolatileOrAtomicLoad(), PromoteSplat(), llvm::AArch64TargetLowering::ReconstructShuffle(), ReorganizeVector(), ReplaceAllUsesWith(), ReplaceBITCASTResults(), replaceInChain(), ReplaceINTRINSIC_W_CHAIN(), ReplaceLoadVector(), llvm::R600TargetLowering::ReplaceNodeResults(), llvm::PPCTargetLowering::ReplaceNodeResults(), ReplaceREADCYCLECOUNTER(), replaceSplatVectorStore(), RewriteAsNarrowerShuffle(), llvm::AMDGPUTargetLowering::ScalarizeVectorLoad(), llvm::AMDGPUTargetLowering::ScalarizeVectorStore(), selectMADD(), selectMSUB(), ShrinkLoadReplaceStoreWithStore(), llvm::TargetLowering::SimplifySetCC(), SkipExtensionForVMULL(), llvm::TargetLowering::softenSetCCOperands(), splitAndLower256BitVectorShuffle(), SplitVector(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), llvm::AMDGPUTargetLowering::SplitVectorStore(), SplitVSETCC(), tryCombineCRC32(), tryCombineFixedPointConvert(), tryCombineLongOpWithDup(), tryCombineShiftImm(), tryCombineToBSL(), tryCombineToEXTR(), tryExtendDUPToExtractHigh(), tryFormConcatFromShuffle(), tryLowerToSLI(), TryMULWIDECombine(), tryToFoldExtendOfConstant(), UnrollVectorOp(), llvm::SelectionDAGBuilder::visitBitTestCase(), llvm::SelectionDAGBuilder::visitBitTestHeader(), llvm::SelectionDAGBuilder::visitJumpTable(), llvm::SelectionDAGBuilder::visitJumpTableHeader(), llvm::SelectionDAGBuilder::visitSPDescriptorParent(), llvm::SelectionDAGBuilder::visitSwitchCase(), WidenMaskArithmetic(), WidenVector(), and XFormVExtractWithShuffleIntoLoad().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
EVT  VT,
SDValue  N 
)

Definition at line 2670 of file SelectionDAG.cpp.

References AddNodeIDNode(), llvm::ISD::ANY_EXTEND, llvm::lltok::APFloat, llvm::ISD::BITCAST, llvm::APFloat::bitcastToAPInt(), llvm::EVT::bitsGT(), llvm::EVT::bitsLE(), llvm::EVT::bitsLT(), llvm::ISD::BSWAP, llvm::ISD::BUILD_VECTOR, llvm::APInt::byteSwap(), llvm::CallingConv::C, llvm::APFloat::changeSign(), llvm::APFloat::clearSign(), llvm::ISD::CONCAT_VECTORS, llvm::APFloat::convert(), llvm::APFloat::convertFromAPInt(), llvm::APFloat::convertToInteger(), llvm::APInt::countLeadingZeros(), llvm::APInt::countPopulation(), llvm::APInt::countTrailingZeros(), llvm::ISD::CTLZ, llvm::ISD::CTLZ_ZERO_UNDEF, llvm::ISD::CTPOP, llvm::ISD::CTTZ, llvm::ISD::CTTZ_ZERO_UNDEF, EVTToAPFloatSemantics(), llvm::ISD::EXTRACT_VECTOR_ELT, llvm::MVT::f32, llvm::MVT::f64, llvm::ISD::FABS, llvm::ISD::FCEIL, llvm::ISD::FFLOOR, llvm::FoldingSet< T >::FindNodeOrInsertPos(), llvm::ISD::FNEG, llvm::ISD::FP_EXTEND, llvm::ISD::FP_ROUND, llvm::ISD::FP_TO_SINT, llvm::ISD::FP_TO_UINT, llvm::ISD::FSUB, llvm::ISD::FTRUNC, getConstant(), getConstantFP(), llvm::SDValue::getConstantOperandVal(), llvm::SDLoc::getDebugLoc(), llvm::SDLoc::getIROrder(), llvm::SDValue::getNode(), getNode(), llvm::APInt::getNullValue(), llvm::SDValue::getOpcode(), llvm::SDNode::getOpcode(), llvm::SDValue::getOperand(), llvm::SDNode::getOperand(), llvm::EVT::getScalarType(), llvm::EVT::getSizeInBits(), getTarget(), getUNDEF(), llvm::SDValue::getValueType(), llvm::EVT::getVectorElementType(), llvm::EVT::getVectorNumElements(), getVTList(), llvm::APInt::getZExtValue(), llvm::MVT::Glue, llvm::MVT::i32, llvm::MVT::i64, llvm::APFloat::IEEEdouble, llvm::APFloat::IEEEsingle, llvm::FoldingSetImpl::InsertNode(), llvm::integerPartWidth, llvm::EVT::isFloatingPoint(), llvm::EVT::isInteger(), llvm::EVT::isVector(), llvm_unreachable, llvm::ISD::MERGE_VALUES, llvm::APFloat::opInexact, llvm::APFloat::opInvalidOp, llvm::APFloat::opOK, llvm::SmallVectorTemplateBase< T, isPodLike >::push_back(), llvm::APFloat::rmNearestTiesToEven, llvm::APFloat::rmTowardNegative, llvm::APFloat::rmTowardPositive, llvm::APFloat::rmTowardZero, llvm::APFloat::roundToIntegral(), llvm::ISD::SCALAR_TO_VECTOR, llvm::APInt::sextOrTrunc(), llvm::ISD::SIGN_EXTEND, llvm::ISD::SINT_TO_FP, llvm::ISD::TokenFactor, llvm::ISD::TRUNCATE, llvm::ISD::UINT_TO_FP, llvm::ISD::UNDEF, llvm::ISD::ZERO_EXTEND, and llvm::APInt::zextOrTrunc().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
EVT  VT,
SDValue  N1,
SDValue  N2,
bool  nuw = false,
bool  nsw = false,
bool  exact = false 
)

Definition at line 3094 of file SelectionDAG.cpp.

References llvm::ISD::ADD, llvm::APFloat::add(), AddBinaryNodeIDCustom(), llvm::ISD::ADDC, llvm::ISD::ADDE, AddNodeIDNode(), llvm::ISD::AND, llvm::SmallVectorImpl< T >::append(), llvm::APInt::ashr(), llvm::ISD::AssertSext, llvm::ISD::AssertZext, llvm::EVT::bitsLE(), llvm::ISD::BUILD_PAIR, llvm::ISD::BUILD_VECTOR, llvm::CallingConv::C, llvm::ISD::CONCAT_VECTORS, llvm::APFloat::convert(), llvm::APFloat::copySign(), llvm::APFloat::divide(), llvm::dyn_cast(), llvm::ISD::EntryToken, EVTToAPFloatSemantics(), llvm::ISD::EXTRACT_ELEMENT, llvm::ISD::EXTRACT_SUBVECTOR, llvm::ISD::EXTRACT_VECTOR_ELT, llvm::ISD::FADD, llvm::ISD::FCOPYSIGN, llvm::ISD::FDIV, llvm::FoldingSet< T >::FindNodeOrInsertPos(), llvm::ISD::FMUL, FoldConstantArithmetic(), llvm::ISD::FP_ROUND, llvm::ISD::FP_ROUND_INREG, llvm::ISD::FREM, llvm::ISD::FSUB, llvm::APInt::getAllOnesValue(), getAnyExtOrTrunc(), llvm::ConstantSDNode::getAPIntValue(), llvm::APInt::getBitWidth(), getConstant(), getConstantFP(), llvm::SDValue::getNode(), getNode(), llvm::SDValue::getNumOperands(), llvm::SDValue::getOpcode(), llvm::SDValue::getOperand(), llvm::EVT::getScalarType(), getSExtOrTrunc(), llvm::SDValue::getSimpleValueType(), llvm::EVT::getSimpleVT(), llvm::EVT::getSizeInBits(), getTarget(), getUNDEF(), llvm::ConstantFPSDNode::getValueAPF(), llvm::SDValue::getValueType(), llvm::EVT::getVectorElementType(), llvm::EVT::getVectorNumElements(), getVTList(), llvm::ConstantSDNode::getZExtValue(), llvm::MVT::Glue, llvm::TargetLoweringBase::hasFloatingPointExceptions(), llvm::MVT::i1, llvm::ISD::INSERT_VECTOR_ELT, llvm::FoldingSetImpl::InsertNode(), llvm::isBinOpWithFlags(), isCommutativeBinOp(), llvm::ConstantFPSDNode::isExactlyValue(), llvm::EVT::isFloatingPoint(), llvm::EVT::isInteger(), llvm::EVT::isSimple(), llvm::EVT::isVector(), llvm::ConstantFPSDNode::isZero(), llvm::Log2_32_Ceil(), llvm::APFloat::mod(), llvm::ISD::MUL, llvm::ISD::MULHS, llvm::ISD::MULHU, llvm::APFloat::multiply(), llvm::SDNode::op_begin(), llvm::SDNode::op_end(), llvm::APFloat::opDivByZero, llvm::APFloat::opInvalidOp, llvm::TargetMachine::Options, llvm::ISD::OR, llvm::MVT::Other, llvm::APFloat::rmNearestTiesToEven, llvm::ISD::ROTL, llvm::ISD::ROTR, llvm::ISD::SDIV, llvm::ISD::SHL, llvm::ISD::SIGN_EXTEND_INREG, llvm::ISD::SRA, llvm::ISD::SREM, llvm::ISD::SRL, llvm::ISD::SUB, llvm::APFloat::subtract(), std::swap(), llvm::ISD::TokenFactor, llvm::APInt::trunc(), llvm::ISD::UDIV, llvm::ISD::UNDEF, llvm::TargetOptions::UnsafeFPMath, llvm::ISD::UREM, llvm::NVPTX::PTXLdStInstCode::V2, and llvm::ISD::XOR.

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
EVT  VT,
SDValue  N1,
SDValue  N2,
SDValue  N3 
)
SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
EVT  VT,
SDValue  N1,
SDValue  N2,
SDValue  N3,
SDValue  N4 
)

Definition at line 3669 of file SelectionDAG.cpp.

References getNode().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
EVT  VT,
SDValue  N1,
SDValue  N2,
SDValue  N3,
SDValue  N4,
SDValue  N5 
)

Definition at line 3676 of file SelectionDAG.cpp.

References getNode().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
EVT  VT,
ArrayRef< SDUse Ops 
)
SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
EVT  VT,
ArrayRef< SDValue Ops 
)
SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
ArrayRef< EVT ResultTys,
ArrayRef< SDValue Ops 
)

Definition at line 5017 of file SelectionDAG.cpp.

References getNode(), and getVTList().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
SDVTList  VTs,
ArrayRef< SDValue Ops 
)
SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
SDVTList  VTs 
)

Definition at line 5097 of file SelectionDAG.cpp.

References getNode(), and llvm::None.

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
SDVTList  VTs,
SDValue  N 
)

Definition at line 5101 of file SelectionDAG.cpp.

References getNode().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
SDVTList  VTs,
SDValue  N1,
SDValue  N2 
)

Definition at line 5107 of file SelectionDAG.cpp.

References getNode().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
SDVTList  VTs,
SDValue  N1,
SDValue  N2,
SDValue  N3 
)

Definition at line 5113 of file SelectionDAG.cpp.

References getNode().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
SDVTList  VTs,
SDValue  N1,
SDValue  N2,
SDValue  N3,
SDValue  N4 
)

Definition at line 5119 of file SelectionDAG.cpp.

References getNode().

SDValue SelectionDAG::getNode ( unsigned  Opcode,
SDLoc  DL,
SDVTList  VTs,
SDValue  N1,
SDValue  N2,
SDValue  N3,
SDValue  N4,
SDValue  N5 
)

Definition at line 5126 of file SelectionDAG.cpp.

References getNode().

SDNode * SelectionDAG::getNodeIfExists ( unsigned  Opcode,
SDVTList  VTList,
ArrayRef< SDValue Ops,
bool  nuw = false,
bool  nsw = false,
bool  exact = false 
)

getNodeIfExists - Get the specified node if it's already available, or else return NULL.

Definition at line 5749 of file SelectionDAG.cpp.

References AddBinaryNodeIDCustom(), AddNodeIDNode(), llvm::FoldingSet< T >::FindNodeOrInsertPos(), llvm::MVT::Glue, llvm::isBinOpWithFlags(), llvm::SDVTList::NumVTs, and llvm::SDVTList::VTs.

SDValue SelectionDAG::getNOT ( SDLoc  DL,
SDValue  Val,
EVT  VT 
)
SDValue SelectionDAG::getRegisterMask ( const uint32_t *  RegMask)
SDValue llvm::SelectionDAG::getSelect ( SDLoc  DL,
EVT  VT,
SDValue  Cond,
SDValue  LHS,
SDValue  RHS 
) [inline]
SDValue llvm::SelectionDAG::getSelectCC ( SDLoc  DL,
SDValue  LHS,
SDValue  RHS,
SDValue  True,
SDValue  False,
ISD::CondCode  Cond 
) [inline]

Definition at line 282 of file SelectionDAG.h.

SDValue llvm::SelectionDAG::getSetCC ( SDLoc  DL,
EVT  VT,
SDValue  LHS,
SDValue  RHS,
ISD::CondCode  Cond 
) [inline]

getSExtOrTrunc - Convert Op, which must be of integer type, to the integer type VT, by either sign-extending or truncating it.

Definition at line 982 of file SelectionDAG.cpp.

References llvm::EVT::bitsGT(), getNode(), llvm::SDValue::getValueType(), llvm::ISD::SIGN_EXTEND, and llvm::ISD::TRUNCATE.

Referenced by llvm::TargetLowering::expandFP_TO_SINT(), getNode(), llvm::AMDGPUTargetLowering::LowerDIVREM24(), and LowerExtendedLoad().

getSignExtendVectorInReg - Return an operation which will sign extend the low lanes of the operand into the specified vector type. For example, this can convert a v16i8 into a v4i32 by sign extending the low four lanes of the operand from i8 to i32.

Definition at line 1025 of file SelectionDAG.cpp.

References getNode(), llvm::EVT::getSizeInBits(), llvm::SDValue::getValueType(), llvm::EVT::getVectorNumElements(), llvm::EVT::isVector(), and llvm::ISD::SIGN_EXTEND_VECTOR_INREG.

std::pair< EVT, EVT > SelectionDAG::GetSplitDestVTs ( const EVT VT) const

GetSplitDestVTs - Compute the VTs needed for the low/hi parts of a type which is split (or expanded) into two not necessarily identical pieces.

Definition at line 6578 of file SelectionDAG.cpp.

References getContext(), llvm::TargetLoweringBase::getTypeToTransformTo(), llvm::EVT::getVectorElementType(), llvm::EVT::getVectorNumElements(), llvm::EVT::getVectorVT(), and llvm::EVT::isVector().

Referenced by SplitVector(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), llvm::AMDGPUTargetLowering::SplitVectorStore(), and SplitVSETCC().

getStackArgumentTokenFactor - Compute a TokenFactor to force all the incoming stack arguments to be loaded from the stack. This is used in tail call lowering to protect stack arguments from being clobbered.

getStackArgumentTokenFactor - Compute a TokenFactor to force all the incoming stack arguments to be loaded from the stack.

Definition at line 3685 of file SelectionDAG.cpp.

References getEntryNode(), getNode(), llvm::MVT::Other, llvm::SmallVectorTemplateBase< T, isPodLike >::push_back(), and llvm::ISD::TokenFactor.

SDValue SelectionDAG::getStore ( SDValue  Chain,
SDLoc  dl,
SDValue  Val,
SDValue  Ptr,
MachinePointerInfo  PtrInfo,
bool  isVolatile,
bool  isNonTemporal,
unsigned  Alignment,
const AAMDNodes AAInfo = AAMDNodes() 
)

getStore - Helper function to build ISD::STORE nodes.

Definition at line 4788 of file SelectionDAG.cpp.

References getEVTAlignment(), getMachineFunction(), llvm::MachineFunction::getMachineMemOperand(), llvm::EVT::getStoreSize(), llvm::SDValue::getValueType(), InferPointerInfo(), llvm::PointerUnion< PT1, PT2 >::isNull(), llvm::MachineMemOperand::MONonTemporal, llvm::MachineMemOperand::MOStore, llvm::MachineMemOperand::MOVolatile, llvm::MVT::Other, and llvm::MachinePointerInfo::V.

Referenced by EmitTailCallStoreFPAndRetAddr(), EmitTailCallStoreRetAddr(), llvm::ARMSelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForMemset(), ExpandUnalignedLoad(), ExpandUnalignedStore(), getMemcpyLoadsAndStores(), getMemmoveLoadsAndStores(), getMemsetStores(), getReadTimeStampCounter(), getTruncStore(), llvm::HexagonTargetLowering::LowerCall(), llvm::SystemZTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), llvm::HexagonTargetLowering::LowerEH_RETURN(), llvm::SparcTargetLowering::LowerF128_LibCallArg(), LowerF128Store(), llvm::SystemZTargetLowering::LowerFormalArguments(), llvm::SparcTargetLowering::LowerFormalArguments_32(), llvm::SparcTargetLowering::LowerFormalArguments_64(), lowerFP_TO_SINT_STORE(), LowerINTRINSIC_W_CHAIN(), LowerMemOpCallTo(), lowerMSAStoreIntr(), LowerVAARG(), llvm::MSP430TargetLowering::LowerVASTART(), llvm::HexagonTargetLowering::LowerVASTART(), LowerVASTART(), memsetStore(), PerformEXTRACT_VECTOR_ELTCombine(), performSTORECombine(), PerformSTORECombine(), replaceSplatVectorStore(), ShrinkLoadReplaceStoreWithStore(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), and StoreTailCallArgumentsToStackSlot().

SDValue SelectionDAG::getStore ( SDValue  Chain,
SDLoc  dl,
SDValue  Val,
SDValue  Ptr,
MachineMemOperand MMO 
)
SDValue llvm::SelectionDAG::getTargetBlockAddress ( const BlockAddress BA,
EVT  VT,
int64_t  Offset = 0,
unsigned char  TargetFlags = 0 
) [inline]
SDValue llvm::SelectionDAG::getTargetConstant ( uint64_t  Val,
EVT  VT,
bool  isOpaque = false 
) [inline]
SDValue llvm::SelectionDAG::getTargetConstant ( const APInt Val,
EVT  VT,
bool  isOpaque = false 
) [inline]

Definition at line 433 of file SelectionDAG.h.

References getConstant().

SDValue llvm::SelectionDAG::getTargetConstant ( const ConstantInt Val,
EVT  VT,
bool  isOpaque = false 
) [inline]

Definition at line 436 of file SelectionDAG.h.

References getConstant().

SDValue llvm::SelectionDAG::getTargetConstantFP ( double  Val,
EVT  VT 
) [inline]

Definition at line 445 of file SelectionDAG.h.

References getConstantFP().

Referenced by getZeroVector().

Definition at line 448 of file SelectionDAG.h.

References getConstantFP().

Definition at line 451 of file SelectionDAG.h.

References getConstantFP().

SDValue llvm::SelectionDAG::getTargetConstantPool ( const Constant C,
EVT  VT,
unsigned  Align = 0,
int  Offset = 0,
unsigned char  TargetFlags = 0 
) [inline]
SDValue llvm::SelectionDAG::getTargetConstantPool ( MachineConstantPoolValue C,
EVT  VT,
unsigned  Align = 0,
int  Offset = 0,
unsigned char  TargetFlags = 0 
) [inline]

Definition at line 482 of file SelectionDAG.h.

References Align(), and getConstantPool().

SDValue SelectionDAG::getTargetExternalSymbol ( const char *  Sym,
EVT  VT,
unsigned char  TargetFlags = 0 
)
SDValue SelectionDAG::getTargetExtractSubreg ( int  SRIdx,
SDLoc  DL,
EVT  VT,
SDValue  Operand 
)

getTargetExtractSubreg - A convenience function for creating TargetInstrInfo::EXTRACT_SUBREG nodes.

getTargetExtractSubreg - A convenience function for creating TargetOpcode::EXTRACT_SUBREG nodes.

Definition at line 5728 of file SelectionDAG.cpp.

References llvm::TargetOpcode::EXTRACT_SUBREG, getMachineNode(), getTargetConstant(), and llvm::MVT::i32.

Referenced by buildRSRC(), getAtomicLoadArithTargetConstant(), LowerF64Op(), LowerFNEGorFABS(), lowerGR128Binary(), llvm::R600TargetLowering::LowerOperation(), and NarrowVector().

Definition at line 463 of file SelectionDAG.h.

References getFrameIndex().

Referenced by addStackMapLiveVars(), and llvm::PPCTargetLowering::SelectAddressRegImm().

SDValue llvm::SelectionDAG::getTargetGlobalAddress ( const GlobalValue GV,
SDLoc  DL,
EVT  VT,
int64_t  offset = 0,
unsigned char  TargetFlags = 0 
) [inline]
SDValue SelectionDAG::getTargetIndex ( int  Index,
EVT  VT,
int64_t  Offset = 0,
unsigned char  TargetFlags = 0 
)
SDValue SelectionDAG::getTargetInsertSubreg ( int  SRIdx,
SDLoc  DL,
EVT  VT,
SDValue  Operand,
SDValue  Subreg 
)

getTargetInsertSubreg - A convenience function for creating TargetInstrInfo::INSERT_SUBREG nodes.

getTargetInsertSubreg - A convenience function for creating TargetOpcode::INSERT_SUBREG nodes.

Definition at line 5739 of file SelectionDAG.cpp.

References getMachineNode(), getTargetConstant(), llvm::MVT::i32, and llvm::TargetOpcode::INSERT_SUBREG.

Referenced by LowerF64Op(), and LowerFNEGorFABS().

SDValue llvm::SelectionDAG::getTargetJumpTable ( int  JTI,
EVT  VT,
unsigned char  TargetFlags = 0 
) [inline]

Definition at line 281 of file SelectionDAG.h.

Referenced by AddCombineToVPADDL(), addStackMapLiveVars(), buildFromShuffleMostly(), BuildVectorFromScalar(), EltsFromConsecutiveLoads(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemset(), ExpandBITCAST(), getCopyFromParts(), getCopyFromPartsVector(), getCopyToParts(), getCopyToPartsVector(), getMemcpyLoadsAndStores(), getMemmoveLoadsAndStores(), getMemsetStores(), GetNegatedExpression(), llvm::SDNode::getOperationName(), isBLACompatibleAddress(), isConsecutiveLSLoc(), isExtendedBUILD_VECTOR(), isNEONModifiedImm(), LowerADDC_ADDE_SUBC_SUBE(), LowerATOMIC_STORE(), LowerExtendedLoad(), LowerFABSorFNEG(), LowerFCOPYSIGN(), LowerFSINCOS(), lowerIntegerElementInsertionVectorShuffle(), LowerMemOpCallTo(), LowerMUL_LOHI(), LowerSIGN_EXTEND_AVX512(), LowerVASTART(), LowerVECTOR_SHUFFLEv16i8(), LowerVectorBroadcast(), LowerVectorIntExtend(), LowerXALUO(), LowerZERO_EXTEND_AVX512(), llvm::ScheduleDAGSDNodes::newSUnit(), PerformADDCombineWithOperands(), PerformANDCombine(), PerformARMBUILD_VECTORCombine(), PerformBTCombine(), llvm::SITargetLowering::PerformDAGCombine(), llvm::AMDGPUTargetLowering::PerformDAGCombine(), performExtendCombine(), PerformExtendCombine(), PerformEXTRACT_VECTOR_ELTCombine(), PerformFMACombine(), PerformLOADCombine(), performORCombine(), PerformORCombine(), PerformSELECTCombine(), PerformShiftCombine(), PerformShuffleCombine(), PerformSTORECombine(), PerformVECTOR_SHUFFLECombine(), PerformVMOVRRDCombine(), PerformXORCombine(), PrepareCall(), ShrinkLoadReplaceStoreWithStore(), simplifyI24(), SkipExtensionForVMULL(), WidenMaskArithmetic(), and XFormVExtractWithShuffleIntoLoad().

SDValue SelectionDAG::getTruncStore ( SDValue  Chain,
SDLoc  dl,
SDValue  Val,
SDValue  Ptr,
MachinePointerInfo  PtrInfo,
EVT  TVT,
bool  isNonTemporal,
bool  isVolatile,
unsigned  Alignment,
const AAMDNodes AAInfo = AAMDNodes() 
)
SDValue SelectionDAG::getTruncStore ( SDValue  Chain,
SDLoc  dl,
SDValue  Val,
SDValue  Ptr,
EVT  TVT,
MachineMemOperand MMO 
)

getUNDEF - Return an UNDEF node. UNDEF does not have a useful SDLoc.

Definition at line 649 of file SelectionDAG.h.

References getNode(), and llvm::ISD::UNDEF.

Referenced by buildFromShuffleMostly(), CompactSwizzlableVector(), Concat128BitVectors(), Concat256BitVectors(), ExpandBVWithShuffles(), ExpandHorizontalBinOp(), ExtractSubVector(), FoldSetCC(), getCopyFromPartsVector(), getCopyToPartsVector(), getExtLoad(), getLegalSplat(), getLoad(), getNode(), getShuffleScalarElt(), getShuffleVectorZeroOrUndef(), getStore(), getTargetVShiftNode(), getTruncStore(), llvm::SelectionDAGBuilder::getValueImpl(), getVectorShuffle(), isHorizontalBinOp(), LowerAsSplatVectorLoad(), LowerAVXExtend(), LowerBITCAST(), LowerBuildVectorv16i8(), LowerBuildVectorv8i16(), llvm::NVPTXTargetLowering::LowerCall(), LowerCONCAT_VECTORS(), LowerExtendedLoad(), llvm::R600TargetLowering::LowerFormalArguments(), llvm::SITargetLowering::LowerFormalArguments(), LowerFP_EXTEND(), lowerIntegerElementInsertionVectorShuffle(), llvm::MipsTargetLowering::lowerLOAD(), llvm::NVPTXTargetLowering::LowerReturn(), LowerSCALAR_TO_VECTOR(), LowerShift(), LowerSIGN_EXTEND(), lowerV16I8VectorShuffle(), lowerV4F32VectorShuffle(), lowerV4F64VectorShuffle(), lowerV8I16BasicBlendVectorShuffle(), lowerV8I16SingleInputVectorShuffle(), LowerVECTOR_SHUFFLE(), LowerVECTOR_SHUFFLE_256(), LowerVECTOR_SHUFFLEv8i16(), lowerVectorShuffle(), matchAddSub(), partitionShuffleOfConcats(), PerformARMBUILD_VECTORCombine(), llvm::R600TargetLowering::PerformDAGCombine(), PerformLOADCombine(), PerformShuffleCombine256(), PerformSTORECombine(), PerformVECTOR_SHUFFLECombine(), llvm::AArch64TargetLowering::ReconstructShuffle(), ReplaceBITCASTResults(), llvm::TargetLowering::SimplifyDemandedBits(), llvm::TargetLowering::SimplifySetCC(), tryToFoldExtendOfConstant(), UnrollVectorOp(), WidenVector(), and XFormVExtractWithShuffleIntoLoad().

SDValue SelectionDAG::getVAArg ( EVT  VT,
SDLoc  dl,
SDValue  Chain,
SDValue  Ptr,
SDValue  SV,
unsigned  Align 
)

getVAArg - VAArg produces a result and token chain, and takes a pointer and a source value as input.

Definition at line 4938 of file SelectionDAG.cpp.

References getNode(), getTargetConstant(), getVTList(), llvm::MVT::i32, llvm::MVT::Other, and llvm::ISD::VAARG.

SDValue SelectionDAG::getVectorShuffle ( EVT  VT,
SDLoc  dl,
SDValue  N1,
SDValue  N2,
const int MaskElts 
)

getVectorShuffle - Return an ISD::VECTOR_SHUFFLE node. The number of elements in VT, which must be a vector type, must match the number of mask elements NumElts. A integer mask element equal to -1 is treated as undefined.

Definition at line 1464 of file SelectionDAG.cpp.

References llvm::FoldingSetNodeID::AddInteger(), AddNodeIDNode(), llvm::BumpPtrAllocatorImpl< AllocatorT, SlabSize, SizeThreshold >::Allocate(), llvm::ISD::BITCAST, llvm::CallingConv::C, commuteShuffle(), llvm::FoldingSet< T >::FindNodeOrInsertPos(), llvm::SDLoc::getDebugLoc(), llvm::SDLoc::getIROrder(), llvm::SDValue::getOpcode(), llvm::SDNode::getOperand(), getUNDEF(), llvm::SDValue::getValueType(), llvm::EVT::getVectorNumElements(), getVTList(), llvm::FoldingSetImpl::InsertNode(), llvm::LibFunc::memcpy, llvm::BitVector::none(), llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back(), llvm::ISD::UNDEF, and llvm::ISD::VECTOR_SHUFFLE.

Referenced by buildFromShuffleMostly(), BuildVSLDOI(), Compact8x32ShuffleNode(), ExpandBVWithShuffles(), GeneratePerfectShuffle(), getCommutedVectorShuffle(), getLegalSplat(), getMOVL(), getShuffleVectorZeroOrUndef(), getUnpackh(), getUnpackl(), getVectorShuffle(), LowerAsSplatVectorLoad(), LowerExtendedLoad(), lowerIntegerElementInsertionVectorShuffle(), LowerMUL(), LowerMUL_LOHI(), LowerSIGN_EXTEND(), lowerV16I8VectorShuffle(), lowerV2I64VectorShuffle(), lowerV4F64VectorShuffle(), lowerV4I32VectorShuffle(), lowerV8I16BasicBlendVectorShuffle(), lowerV8I16SingleInputVectorShuffle(), lowerV8I16VectorShuffle(), LowerVECTOR_SHUFFLE_128v4(), LowerVECTOR_SHUFFLE_256(), LowerVECTOR_SHUFFLEv8i16(), lowerVectorShuffle(), LowerVSETCC(), performSelectCombine(), PerformShuffleCombine(), PerformSTORECombine(), PerformVECTOR_SHUFFLECombine(), llvm::AArch64TargetLowering::ReconstructShuffle(), RewriteAsNarrowerShuffle(), splitAndLower256BitVectorShuffle(), TransformVSELECTtoBlendVECTOR_SHUFFLE(), and XFormVExtractWithShuffleIntoLoad().

SDValue llvm::SelectionDAG::getVectorShuffle ( EVT  VT,
SDLoc  dl,
SDValue  N1,
SDValue  N2,
ArrayRef< int MaskElts 
) [inline]

getVTList - Return an SDVTList that represents the list of values specified.

Definition at line 5133 of file SelectionDAG.cpp.

References makeVTList().

Referenced by AddCombineTo64bitMLAL(), llvm::TargetLowering::BuildSDIV(), llvm::TargetLowering::BuildUDIV(), CloneNodeWithValues(), CombineBaseUpdate(), CombineVLDDUP(), createLoadLR(), createStoreLR(), EltsFromConsecutiveLoads(), emitCLC(), emitComparison(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForMemchr(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemset(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForStrcmp(), llvm::SystemZSelectionDAGInfo::EmitTargetCodeForStrcpy(), Expand64BitShift(), ExpandBITCAST(), llvm::TargetLowering::expandMUL(), GeneratePerfectShuffle(), getAArch64XALUOOp(), getAddrSpaceCast(), getAtomic(), getBasicBlock(), getBlockAddress(), getBoundedStrlen(), getCALLSEQ_END(), getCALLSEQ_START(), getConstant(), getConstantFP(), getConstantPool(), getConvertRndSat(), getCopyFromReg(), getCopyToReg(), getEHLabel(), getFrameIndex(), getGatherNode(), getGlobalAddress(), getIndexedStore(), getJumpTable(), getLoad(), getMachineNode(), getMDNode(), getMergeValues(), getNode(), getReadPerformanceCounter(), getReadTimeStampCounter(), getRegister(), getRegisterMask(), getScatterNode(), getSrcValue(), getStore(), getTargetIndex(), GetTLSADDR(), getTruncStore(), getVAArg(), getVectorShuffle(), LowerADDC_ADDE_SUBC_SUBE(), llvm::HexagonTargetLowering::LowerCall(), llvm::SystemZTargetLowering::LowerCall(), llvm::NVPTXTargetLowering::LowerCall(), llvm::SparcTargetLowering::LowerCall_32(), llvm::SparcTargetLowering::LowerCall_64(), LowerCallResult(), llvm::TargetLowering::LowerCallTo(), LowerCMP_SWAP(), LowerCTLZ(), LowerCTLZ_ZERO_UNDEF(), LowerCTTZ(), LowerFSINCOS(), llvm::SparcTargetLowering::LowerGlobalTLSAddress(), LowerINTRINSIC_W_CHAIN(), LowerINTRINSIC_WO_CHAIN(), llvm::NVPTXTargetLowering::LowerReturn(), llvm::AMDGPUTargetLowering::LowerSDIVREM(), llvm::MSP430TargetLowering::LowerSELECT_CC(), llvm::MSP430TargetLowering::LowerSETCC(), LowerVECTOR_SHUFFLE(), LowerXALUO(), performCONDCombine(), llvm::PPCTargetLowering::PerformDAGCombine(), performIntegerAbsCombine(), performNEONPostLDSTCombine(), performPostLD1Combine(), PerformShuffleCombine256(), PrepareCall(), ReplaceATOMIC_LOAD(), ReplaceINTRINSIC_W_CHAIN(), ReplaceLoadVector(), llvm::R600TargetLowering::ReplaceNodeResults(), llvm::PPCTargetLowering::ReplaceNodeResults(), ReplaceREADCYCLECOUNTER(), llvm::SelectionDAGISel::SelectCodeCommon(), and SelectNodeTo().

SDVTList SelectionDAG::getVTList ( EVT  VT1,
EVT  VT2,
EVT  VT3 
)
SDVTList SelectionDAG::getVTList ( EVT  VT1,
EVT  VT2,
EVT  VT3,
EVT  VT4 
)

getZeroExtendVectorInReg - Return an operation which will zero extend the low lanes of the operand into the specified vector type. For example, this can convert a v16i8 into a v4i32 by zero extending the low four lanes of the operand from i8 to i32.

Definition at line 1035 of file SelectionDAG.cpp.

References getNode(), llvm::EVT::getSizeInBits(), llvm::SDValue::getValueType(), llvm::EVT::getVectorNumElements(), llvm::EVT::isVector(), and llvm::ISD::ZERO_EXTEND_VECTOR_INREG.

hasDebugValues - Return true if there are any SDDbgValue nodes associated with this SelectionDAG.

Definition at line 1100 of file SelectionDAG.h.

References llvm::SDDbgInfo::empty().

Referenced by llvm::ScheduleDAGSDNodes::EmitSchedule().

init - Prepare this SelectionDAG to process code in the given MachineFunction.

Definition at line 919 of file SelectionDAG.cpp.

References llvm::Function::getContext(), and llvm::MachineFunction::getFunction().

Referenced by llvm::SelectionDAGISel::runOnMachineFunction().

isBaseWithConstantOffset - Return true if the specified operand is an ISD::ADD with a ConstantSDNode on the right-hand side, or if it is an ISD::OR with a ConstantSDNode that is guaranteed to have the same semantics as an ADD. This handles the equivalence: X|Cst == X+Cst iff X&Cst = 0.

Definition at line 2595 of file SelectionDAG.cpp.

References llvm::ISD::ADD, llvm::SDValue::getOpcode(), llvm::SDValue::getOperand(), MaskedValueIsZero(), llvm::ISD::OR, and OR.

Referenced by InferPtrAlignment(), isConsecutiveLoad(), isConsecutiveLSLoc(), and LowerAsSplatVectorLoad().

static bool llvm::SelectionDAG::isCommutativeBinOp ( unsigned  Opcode) [inline, static]
bool SelectionDAG::isConsecutiveLoad ( LoadSDNode LD,
LoadSDNode Base,
unsigned  Bytes,
int  Dist 
) const

isEqualTo - Test whether two SDValues are known to compare equal. This is true if they are the same value, or if one is negative zero and the other positive zero.

Definition at line 2640 of file SelectionDAG.cpp.

Referenced by matchIntegerMINMAX(), PerformSELECT_CCCombine(), and PerformSELECTCombine().

isKnownNeverNan - Test whether the given SDValue is known to never be NaN.

Definition at line 2609 of file SelectionDAG.cpp.

References llvm::CallingConv::C, and getTarget().

Referenced by PerformSELECT_CCCombine(), and PerformSELECTCombine().

isKnownNeverZero - Test whether the given SDValue is known to never be positive or negative Zero.

Definition at line 2623 of file SelectionDAG.cpp.

References llvm::CallingConv::C, llvm::SDValue::getOpcode(), llvm::SDValue::getOperand(), and llvm::ISD::OR.

Referenced by PerformCMOVCombine(), PerformSELECT_CCCombine(), and PerformSELECTCombine().

Legalize - This transforms the SelectionDAG into a SelectionDAG that is compatible with the target instruction selector, as indicated by the TargetLowering object.

Note that this is an involved process that may invalidate pointers into the graph.

Definition at line 4313 of file LegalizeDAG.cpp.

References allnodes_begin(), allnodes_end(), AssignTopologicalOrder(), DeleteNode(), llvm::SDValue::getNode(), getRoot(), llvm::SmallPtrSetImpl< PtrType >::insert(), N, RemoveDeadNodes(), and llvm::SDNode::use_empty().

bool SelectionDAG::LegalizeOp ( SDNode N,
SmallSetVector< SDNode *, 16 > &  UpdatedNodes 
)

Transforms a SelectionDAG node and any operands to it into a node that is compatible with the target instruction selector, as indicated by the TargetLowering object.

Returns:
true if N is a valid, legal node after calling this.

This essentially runs a single recursive walk of the Legalize process over the given node (and its operands). This can be used to incrementally legalize the DAG. All of the nodes which are directly replaced, potentially including N, are added to the output parameter UpdatedNodes so that the delta to the DAG can be understood by the caller.

When this returns false, N has been legalized in a way that make the pointer passed in no longer valid. It may have even been deleted from the DAG, and so it shouldn't be used further. When this returns true, the N passed in is a legal node, and can be immediately processed as such. This may still have done some work on the DAG, and will still populate UpdatedNodes with any new nodes replacing those originally in the DAG.

Definition at line 4354 of file LegalizeDAG.cpp.

References llvm::SmallPtrSetImpl< PtrType >::count(), and llvm::SmallPtrSetImpl< PtrType >::insert().

LegalizeTypes - This transforms the SelectionDAG into a SelectionDAG that only uses types natively supported by the target. Returns "true" if it made any changes.

Note that this is an involved process that may invalidate pointers into the graph.

Definition at line 1112 of file LegalizeTypes.cpp.

References llvm::DAGTypeLegalizer::run().

LegalizeVectors - This transforms the SelectionDAG into a SelectionDAG that only uses vector math operations supported by the target. This is necessary as a separate step from Legalize because unrolling a vector operation can introduce illegal types, which requires running LegalizeTypes again.

This returns true if it made any changes; in that case, LegalizeTypes is called again before Legalize.

Note that this is an involved process that may invalidate pointers into the graph.

Definition at line 992 of file LegalizeVectorOps.cpp.

bool SelectionDAG::MaskedValueIsZero ( SDValue  Op,
const APInt Mask,
unsigned  Depth = 0 
) const

MaskedValueIsZero - Return true if 'Op & Mask' is known to be zero. We use this predicate to simplify operations downstream. Op and Mask are known to be the same type.

MaskedValueIsZero - Return true if 'V & Mask' is known to be zero. We use this predicate to simplify operations downstream. Mask is known to be zero for bits that V cannot have.

Definition at line 1921 of file SelectionDAG.cpp.

References computeKnownBits().

Referenced by llvm::SelectionDAGISel::CheckAndMask(), llvm::XCoreSelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::TargetLowering::expandMUL(), isBaseWithConstantOffset(), isTruncWithZeroHighBitsInput(), llvm::PPCTargetLowering::PerformDAGCombine(), PerformORCombine(), PerformShiftCombine(), ShrinkLoadReplaceStoreWithStore(), SignBitIsZero(), and llvm::TargetLowering::SimplifySetCC().

SDNode * SelectionDAG::MorphNodeTo ( SDNode N,
unsigned  Opc,
SDVTList  VTs,
ArrayRef< SDValue Ops 
)

MorphNodeTo - This *mutates* the specified node to have the specified return type, opcode, and operands.

MorphNodeTo - This *mutates* the specified node to have the specified return type, opcode, and operands.

Note that MorphNodeTo returns the resultant node. If there is already a node of the specified opcode and operands, it returns that node instead of the current one. Note that the SDLoc need not be the same.

Using MorphNodeTo is faster than creating a new node and swapping it in with ReplaceAllUsesWith both because it often avoids allocating a new node, and because it doesn't require CSE recalculation for any of the node's users.

However, note that MorphNodeTo recursively deletes dead nodes from the DAG. As a consequence it isn't appropriate to use from within the DAG combiner or the legalizer which maintain worklists that would need to be updated when deleting things.

Definition at line 5484 of file SelectionDAG.cpp.

References AddNodeIDNode(), llvm::BumpPtrAllocatorImpl< AllocatorT, SlabSize, SizeThreshold >::Allocate(), llvm::array_lengthof(), llvm::ArrayRef< T >::data(), llvm::SmallPtrSetImplBase::empty(), llvm::FoldingSet< T >::FindNodeOrInsertPos(), llvm::SDUse::getNode(), llvm::MVT::Glue, I, llvm::SDNode::InitOperands(), llvm::SmallPtrSetImpl< PtrType >::insert(), llvm::FoldingSetImpl::InsertNode(), llvm::SDVTList::NumVTs, llvm::SDNode::op_begin(), llvm::SDNode::op_end(), llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back(), RemoveDeadNodes(), llvm::ArrayRef< T >::size(), llvm::SDNode::use_empty(), and llvm::SDVTList::VTs.

Referenced by CloneNodeWithValues(), and SelectNodeTo().

RemoveDeadNode - Remove the specified node from the system. If any of its operands then becomes dead, remove them as well. Inform UpdateListener for each node deleted.

Definition at line 660 of file SelectionDAG.cpp.

References llvm::NVPTXISD::Dummy, getRoot(), and RemoveDeadNodes().

RemoveDeadNodes - This method deletes the unreachable nodes in the given list, and any nodes that become unreachable as a result.

Definition at line 631 of file SelectionDAG.cpp.

References llvm::SmallVectorBase::empty(), llvm::SDUse::getNode(), I, N, llvm::SelectionDAG::DAGUpdateListener::Next, llvm::SDNode::op_begin(), llvm::SDNode::op_end(), llvm::SmallVectorImpl< T >::pop_back_val(), llvm::SmallVectorTemplateBase< T, isPodLike >::push_back(), and llvm::SDNode::use_empty().

ReplaceAllUsesOfValuesWith - Like ReplaceAllUsesOfValueWith, but for multiple values at once. This correctly handles the case where there is an overlap between the From values and the To values.

ReplaceAllUsesOfValuesWith - Replace any uses of From with To, leaving uses of other values produced by From.getNode() alone. The same value may appear in both the From and To list. The Deleted vector is handled the same way as for ReplaceAllUsesWith.

Definition at line 6028 of file SelectionDAG.cpp.

References llvm::SmallVectorTemplateCommon< T >::begin(), llvm::SmallVectorTemplateCommon< T >::end(), llvm::SDValue::getNode(), llvm::SDValue::getResNo(), llvm::SDUse::getResNo(), llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back(), ReplaceAllUsesOfValueWith(), llvm::SmallVectorTemplateCommon< T >::size(), llvm::SDNode::use_begin(), and llvm::SDNode::use_end().

Referenced by llvm::SelectionDAGISel::ReplaceUses().

ReplaceAllUsesWith - Modify anything using 'From' to use 'To' instead. This can cause recursive merging of nodes in the DAG. Use the first version if 'From' is known to have a single result, use the second if you have two nodes with identical results (or if 'To' has a superset of the results of 'From'), use the third otherwise.

These methods all take an optional UpdateListener, which (if not null) is informed about nodes that are deleted and modified due to recursive changes in the dag.

These functions only replace all existing uses. It's possible that as these replacements are being performed, CSE may cause the From node to be given new uses. These new uses of From are left in place, and not automatically transferred to To.

ReplaceAllUsesWith - Modify anything using 'From' to use 'To' instead. This can cause recursive merging of nodes in the DAG.

This version assumes From has a single result value.

Definition at line 5819 of file SelectionDAG.cpp.

References llvm::SDValue::getNode(), llvm::SDNode::getNumValues(), llvm::SDValue::getResNo(), getRoot(), setRoot(), llvm::SDNode::use_begin(), and llvm::SDNode::use_end().

Referenced by FoldMaskAndShiftToExtract(), FoldMaskAndShiftToScale(), FoldMaskedShiftToScaledMask(), performCONDCombine(), ReplaceAllUsesOfValueWith(), ReplaceAllUsesWith(), and llvm::SelectionDAGISel::ReplaceUses().

void SelectionDAG::ReplaceAllUsesWith ( SDNode From,
SDNode To 
)

ReplaceAllUsesWith - Modify anything using 'From' to use 'To' instead. This can cause recursive merging of nodes in the DAG.

This version assumes that for each value of From, there is a corresponding value in To in the same position with the same type.

Definition at line 5866 of file SelectionDAG.cpp.

References getNode(), llvm::SDNode::getNumValues(), getRoot(), llvm::SDNode::use_iterator::getUse(), llvm::SDNode::getValueType(), llvm::SDNode::hasAnyUseOfValue(), setRoot(), llvm::SDNode::use_begin(), and llvm::SDNode::use_end().

ReplaceAllUsesWith - Modify anything using 'From' to use 'To' instead. This can cause recursive merging of nodes in the DAG.

This version can replace From with any result values. To must match the number and types of values returned by From.

Definition at line 5913 of file SelectionDAG.cpp.

References getNode(), llvm::SDNode::getNumValues(), llvm::SDUse::getResNo(), getRoot(), llvm::SDNode::use_iterator::getUse(), ReplaceAllUsesWith(), setRoot(), llvm::SDNode::use_begin(), and llvm::SDNode::use_end().

void llvm::SelectionDAG::RepositionNode ( allnodes_iterator  Position,
SDNode N 
) [inline]

RepositionNode - Move node N in the AllNodes list to be immediately before the given iterator Position. This may be used to update the topological ordering when the list of nodes is modified.

Definition at line 1043 of file SelectionDAG.h.

References llvm::ilist< NodeTy >::insert(), and llvm::iplist< NodeTy, Traits >::remove().

Referenced by insertDAGNode(), and InsertDAGNode().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  MachineOpc,
EVT  VT 
)

SelectNodeTo - These are used for target selectors to *mutate* the specified node to have the specified return type, Target opcode, and operands. Note that target opcodes are stored as ~TargetOpcode in the node opcode field. The resultant node is returned.

SelectNodeTo - These are wrappers around MorphNodeTo that accept a machine opcode.

Definition at line 5347 of file SelectionDAG.cpp.

References getVTList(), and llvm::None.

Referenced by SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT,
SDValue  Op1 
)

Definition at line 5353 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT,
SDValue  Op1,
SDValue  Op2 
)

Definition at line 5360 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT,
SDValue  Op1,
SDValue  Op2,
SDValue  Op3 
)

Definition at line 5368 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT,
ArrayRef< SDValue Ops 
)

Definition at line 5376 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT1,
EVT  VT2 
)

Definition at line 5388 of file SelectionDAG.cpp.

References getVTList(), llvm::None, and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT1,
EVT  VT2,
ArrayRef< SDValue Ops 
)

Definition at line 5382 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT1,
EVT  VT2,
EVT  VT3,
ArrayRef< SDValue Ops 
)

Definition at line 5394 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  MachineOpc,
EVT  VT1,
EVT  VT2,
EVT  VT3,
EVT  VT4,
ArrayRef< SDValue Ops 
)

Definition at line 5401 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT1,
EVT  VT2,
SDValue  Op1 
)

Definition at line 5408 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT1,
EVT  VT2,
SDValue  Op1,
SDValue  Op2 
)

Definition at line 5416 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT1,
EVT  VT2,
SDValue  Op1,
SDValue  Op2,
SDValue  Op3 
)

Definition at line 5424 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
EVT  VT1,
EVT  VT2,
EVT  VT3,
SDValue  Op1,
SDValue  Op2,
SDValue  Op3 
)

Definition at line 5433 of file SelectionDAG.cpp.

References getVTList(), and SelectNodeTo().

SDNode * SelectionDAG::SelectNodeTo ( SDNode N,
unsigned  TargetOpc,
SDVTList  VTs,
ArrayRef< SDValue Ops 
)

Definition at line 5442 of file SelectionDAG.cpp.

References MorphNodeTo(), and llvm::SDNode::setNodeId().

void SelectionDAG::setGraphAttrs ( const SDNode N,
const char *  Attrs 
)

setGraphAttrs - Set graph attributes for a node. (eg. "color=red".)

Definition at line 177 of file SelectionDAGPrinter.cpp.

References llvm::errs(), and NodeGraphAttrs.

void SelectionDAG::setGraphColor ( const SDNode N,
const char *  Color 
)

setGraphColor - Convenience for setting node color attribute.

Definition at line 207 of file SelectionDAGPrinter.cpp.

References llvm::errs(), and NodeGraphAttrs.

void SelectionDAG::setSubgraphColor ( SDNode N,
const char *  Color 
)

setGraphColor - Convenience for setting subgraph color attribute.

setSubgraphColor - Convenience for setting subgraph color attribute.

Definition at line 251 of file SelectionDAGPrinter.cpp.

References llvm::errs(), and llvm::LibFunc::strcmp.

bool SelectionDAG::SignBitIsZero ( SDValue  Op,
unsigned  Depth = 0 
) const

SignBitIsZero - Return true if the sign bit of Op is known to be zero. We use this predicate to simplify operations downstream.

Definition at line 1909 of file SelectionDAG.cpp.

References llvm::EVT::getScalarType(), llvm::APInt::getSignBit(), llvm::EVT::getSizeInBits(), llvm::SDValue::getValueType(), llvm::EVT::isVector(), and MaskedValueIsZero().

Referenced by getCmp().

std::pair< SDValue, SDValue > SelectionDAG::SplitVector ( const SDValue N,
const SDLoc DL,
const EVT LoVT,
const EVT HiVT 
)

SplitVector - Split the vector with EXTRACT_SUBVECTOR using the provides VTs and return the low/high part.

SplitVector - Split the vector with EXTRACT_SUBVECTOR and return the low/high part.

Definition at line 6595 of file SelectionDAG.cpp.

References llvm::ISD::EXTRACT_SUBVECTOR, getConstant(), getNode(), llvm::SDValue::getValueType(), llvm::TargetLoweringBase::getVectorIdxTy(), llvm::EVT::getVectorNumElements(), llvm::HexagonISD::Hi, and llvm::HexagonISD::Lo.

Referenced by SplitVector(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), SplitVectorOperand(), and llvm::AMDGPUTargetLowering::SplitVectorStore().

std::pair<SDValue, SDValue> llvm::SelectionDAG::SplitVector ( const SDValue N,
const SDLoc DL 
) [inline]

SplitVector - Split the vector with EXTRACT_SUBVECTOR and return the low/high part.

Definition at line 1204 of file SelectionDAG.h.

References GetSplitDestVTs(), llvm::SDValue::getValueType(), and SplitVector().

std::pair<SDValue, SDValue> llvm::SelectionDAG::SplitVectorOperand ( const SDNode N,
unsigned  OpNo 
) [inline]

SplitVectorOperand - Split the node's operand with EXTRACT_SUBVECTOR and return the low/high part.

Definition at line 1212 of file SelectionDAG.h.

References llvm::SDNode::getOperand(), and SplitVector().

Referenced by SplitVSETCC().

UnrollVectorOp - Utility function used by legalize and lowering to "unroll" a vector operation by splitting out the scalars and operating on each element individually. If the ResNE is 0, fully unroll the vector op. If ResNE is less than the width of the vector op, unroll up to ResNE. If the ResNE is greater than the width of the vector op, unroll the vector op and fill the end of the resulting vector with UNDEFS.

Definition at line 6421 of file SelectionDAG.cpp.

References llvm::ISD::BUILD_VECTOR, llvm::ISD::EXTRACT_VECTOR_ELT, llvm::ISD::FP_ROUND_INREG, getConstant(), getContext(), getNode(), llvm::SDNode::getNumOperands(), llvm::SDNode::getNumValues(), llvm::SDNode::getOpcode(), llvm::SDNode::getOperand(), getShiftAmountOperand(), llvm::TargetMachine::getSubtargetImpl(), llvm::TargetSubtargetInfo::getTargetLowering(), getUNDEF(), llvm::SDValue::getValueType(), getValueType(), llvm::SDNode::getValueType(), llvm::EVT::getVectorElementType(), llvm::TargetLoweringBase::getVectorIdxTy(), llvm::EVT::getVectorVT(), llvm::EVT::isVector(), llvm::AArch64CC::NE, llvm::SmallVectorTemplateBase< T, isPodLike >::push_back(), llvm::ISD::ROTL, llvm::ISD::ROTR, llvm::ISD::SELECT, llvm::ISD::SHL, llvm::ISD::SIGN_EXTEND_INREG, llvm::ISD::SRA, llvm::ISD::SRL, and llvm::ISD::VSELECT.

Referenced by LowerVectorFP_TO_INT(), and LowerVectorINT_TO_FP().

UpdateNodeOperands - *Mutate* the specified node in-place to have the specified operands. If the resultant node already exists in the DAG, this does not modify the specified node, instead it returns the node that already exists. If the resultant node does not exist in the DAG, the input node is returned. As a degenerate case, if you specify the same input operands as the node already has, the input node is returned.

Definition at line 5223 of file SelectionDAG.cpp.

References llvm::SDNode::getNumOperands(), llvm::SDNode::getOperand(), and llvm::FoldingSetImpl::InsertNode().

Referenced by EltsFromConsecutiveLoads(), llvm::AMDGPUTargetLowering::LowerGlobalAddress(), MoveBelowOrigChain(), llvm::SITargetLowering::PerformDAGCombine(), PerformShuffleCombine256(), and UpdateNodeOperands().

Definition at line 5276 of file SelectionDAG.cpp.

References UpdateNodeOperands().

SDNode * SelectionDAG::UpdateNodeOperands ( SDNode N,
SDValue  Op1,
SDValue  Op2,
SDValue  Op3,
SDValue  Op4 
)

Definition at line 5282 of file SelectionDAG.cpp.

References UpdateNodeOperands().

SDNode * SelectionDAG::UpdateNodeOperands ( SDNode N,
SDValue  Op1,
SDValue  Op2,
SDValue  Op3,
SDValue  Op4,
SDValue  Op5 
)

Definition at line 5289 of file SelectionDAG.cpp.

References UpdateNodeOperands().

void SelectionDAG::viewGraph ( const std::string &  Title)

viewGraph - Pop up a GraphViz/gv window with the DAG rendered using 'dot'.

viewGraph - Pop up a ghostview window with the reachable parts of the DAG rendered using 'dot'.

Definition at line 146 of file SelectionDAGPrinter.cpp.

References llvm::errs(), getMachineFunction(), llvm::Intrinsic::getName(), and llvm::ViewGraph().

Definition at line 159 of file SelectionDAGPrinter.cpp.


Friends And Related Function Documentation

friend struct DAGUpdateListener [friend]

DAGUpdateListener is a friend so it can manipulate the listener stack.

Definition at line 248 of file SelectionDAG.h.


Member Data Documentation

NewNodesMustHaveLegalTypes - When true, additional steps are taken to ensure that getConstant() and similar functions return DAG nodes that have legal types. This is important after type legalization since any illegally typed nodes generated after this point will not experience type legalization.

Definition at line 244 of file SelectionDAG.h.

Referenced by getConstant().

Definition at line 291 of file SelectionDAG.h.

Referenced by clearGraphAttrs(), getGraphAttrs(), setGraphAttrs(), and setGraphColor().


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