LLVM API Documentation

llvm::X86TargetLowering Class Reference

#include <X86ISelLowering.h>

Inheritance diagram for llvm::X86TargetLowering:
[legend]
Collaboration diagram for llvm::X86TargetLowering:
[legend]

List of all members.

Public Member Functions

 X86TargetLowering (X86TargetMachine &TM)
SDValue getPICJumpTableRelocBase (SDValue Table, SelectionDAG &DAG) const
unsigned getBytesToPopOnReturn () const
unsigned getBytesCallerReserves () const
unsigned getStackPtrReg () const
virtual unsigned getByValTypeAlignment (const Type *Ty) const
virtual EVT getOptimalMemOpType (uint64_t Size, unsigned Align, bool isSrcConst, bool isSrcStr, SelectionDAG &DAG) const
virtual bool allowsUnalignedMemoryAccesses (EVT VT) const
virtual SDValue LowerOperation (SDValue Op, SelectionDAG &DAG)
virtual void ReplaceNodeResults (SDNode *N, SmallVectorImpl< SDValue > &Results, SelectionDAG &DAG)
virtual SDValue PerformDAGCombine (SDNode *N, DAGCombinerInfo &DCI) const
virtual MachineBasicBlock * EmitInstrWithCustomInserter (MachineInstr *MI, MachineBasicBlock *MBB) const
virtual const char * getTargetNodeName (unsigned Opcode) const
virtual MVT::SimpleValueType getSetCCResultType (EVT VT) const
 getSetCCResultType - Return the ISD::SETCC ValueType
virtual void computeMaskedBitsForTargetNode (const SDValue Op, const APInt &Mask, APInt &KnownZero, APInt &KnownOne, const SelectionDAG &DAG, unsigned Depth=0) const
virtual bool isGAPlusOffset (SDNode *N, GlobalValue *&GA, int64_t &Offset) const
SDValue getReturnAddressFrameIndex (SelectionDAG &DAG)
virtual bool ExpandInlineAsm (CallInst *CI) const
ConstraintType getConstraintType (const std::string &Constraint) const
std::vector< unsigned > getRegClassForInlineAsmConstraint (const std::string &Constraint, EVT VT) const
virtual const char * LowerXConstraint (EVT ConstraintVT) const
virtual void LowerAsmOperandForConstraint (SDValue Op, char ConstraintLetter, bool hasMemory, std::vector< SDValue > &Ops, SelectionDAG &DAG) const
std::pair< unsigned, const
TargetRegisterClass * > 
getRegForInlineAsmConstraint (const std::string &Constraint, EVT VT) const
virtual bool isLegalAddressingMode (const AddrMode &AM, const Type *Ty) const
virtual bool isTruncateFree (const Type *Ty1, const Type *Ty2) const
virtual bool isTruncateFree (EVT VT1, EVT VT2) const
virtual bool isZExtFree (const Type *Ty1, const Type *Ty2) const
virtual bool isZExtFree (EVT VT1, EVT VT2) const
virtual bool isNarrowingProfitable (EVT VT1, EVT VT2) const
virtual bool isShuffleMaskLegal (const SmallVectorImpl< int > &Mask, EVT VT) const
virtual bool isVectorClearMaskLegal (const SmallVectorImpl< int > &Mask, EVT VT) const
virtual bool ShouldShrinkFPConstant (EVT VT) const
virtual bool IsEligibleForTailCallOptimization (SDValue Callee, unsigned CalleeCC, bool isVarArg, const SmallVectorImpl< ISD::InputArg > &Ins, SelectionDAG &DAG) const
virtual const X86Subtarget * getSubtarget ()
bool isScalarFPTypeInSSEReg (EVT VT) const
virtual EVT getWidenVectorType (EVT VT) const
virtual FastISel * createFastISel (MachineFunction &mf, MachineModuleInfo *mmi, DwarfWriter *dw, DenseMap< const Value *, unsigned > &, DenseMap< const BasicBlock *, MachineBasicBlock * > &, DenseMap< const AllocaInst *, int > &, SmallSet< Instruction *, 8 > &)
virtual unsigned getFunctionAlignment (const Function *F) const
 getFunctionAlignment - Return the Log2 alignment of this function.


Detailed Description

Definition at line 353 of file X86ISelLowering.h.


Constructor & Destructor Documentation

X86TargetLowering::X86TargetLowering ( X86TargetMachine &  TM  )  [explicit]

Definition at line 69 of file X86ISelLowering.cpp.

References llvm::ISD::ADD, llvm::TargetLowering::addLegalFPImmediate(), llvm::TargetLowering::AddPromotedToType(), llvm::TargetLowering::addRegisterClass(), llvm::ISD::AND, llvm::lltok::APFloat, llvm::ISD::ATOMIC_CMP_SWAP, llvm::ISD::ATOMIC_LOAD_ADD, llvm::ISD::ATOMIC_LOAD_AND, llvm::ISD::ATOMIC_LOAD_NAND, llvm::ISD::ATOMIC_LOAD_OR, llvm::ISD::ATOMIC_LOAD_SUB, llvm::ISD::ATOMIC_LOAD_XOR, llvm::ISD::ATOMIC_SWAP, llvm::TargetLowering::benefitFromCodePlacementOpt, llvm::ISD::BIT_CONVERT, llvm::ISD::BR_CC, llvm::ISD::BR_JT, llvm::ISD::BRCOND, llvm::ISD::BSWAP, llvm::ISD::BUILD_VECTOR, llvm::APFloat::changeSign(), llvm::TargetLowering::computeRegisterProperties(), llvm::ISD::ConstantPool, llvm::APFloat::convert(), llvm::ISD::CTLZ, llvm::ISD::CTPOP, llvm::ISD::CTTZ, llvm::TargetLowering::Custom, llvm::ISD::DBG_LABEL, llvm::ISD::DBG_STOPPOINT, DisableMMX, llvm::ISD::DYNAMIC_STACKALLOC, llvm::N86::EAX, llvm::N86::EDX, llvm::ISD::EH_LABEL, llvm::ISD::EH_RETURN, llvm::ISD::EHSELECTION, llvm::N86::ESP, llvm::ISD::EXCEPTIONADDR, llvm::TargetLowering::Expand, llvm::ISD::ExternalSymbol, llvm::ISD::EXTRACT_SUBVECTOR, llvm::ISD::EXTRACT_VECTOR_ELT, llvm::MVT::f32, llvm::MVT::f64, llvm::MVT::f80, llvm::ISD::FABS, llvm::ISD::FADD, llvm::ISD::FCOPYSIGN, llvm::ISD::FCOS, llvm::ISD::FDIV, llvm::ISD::FEXP, llvm::ISD::FEXP2, llvm::MVT::FIRST_VECTOR_VALUETYPE, llvm::ISD::FLOG, llvm::ISD::FLOG10, llvm::ISD::FLOG2, llvm::ISD::FLT_ROUNDS_, llvm::ISD::FMUL, llvm::ISD::FNEG, llvm::ISD::FP_ROUND_INREG, llvm::ISD::FP_TO_SINT, llvm::ISD::FP_TO_UINT, llvm::ISD::FPOW, llvm::ISD::FPOWI, llvm::ISD::FRAME_TO_ARGS_OFFSET, llvm::ISD::FREM, llvm::ISD::FSIN, llvm::ISD::FSQRT, llvm::ISD::FSUB, llvm::X86TargetMachine::getRegisterInfo(), llvm::EVT::getSimpleVT(), llvm::TargetMachine::getSubtarget(), llvm::TargetLowering::getTargetData(), llvm::EVT::getVectorNumElements(), llvm::ISD::GlobalAddress, llvm::ISD::GlobalTLSAddress, llvm::X86Subtarget::hasAVX(), llvm::X86Subtarget::hasMMX(), llvm::X86Subtarget::hasSSE1(), llvm::X86Subtarget::hasSSE2(), llvm::X86Subtarget::hasSSE3(), llvm::X86Subtarget::hasSSE41(), llvm::X86Subtarget::hasSSE42(), llvm::MVT::i1, llvm::MVT::i16, llvm::MVT::i32, llvm::MVT::i64, llvm::MVT::i8, llvm::ISD::INSERT_VECTOR_ELT, llvm::ISD::INTRINSIC_WO_CHAIN, llvm::EVT::is128BitVector(), llvm::EVT::is256BitVector(), llvm::X86Subtarget::is64Bit(), llvm::isPowerOf2_32(), llvm::X86Subtarget::isTargetCygMing(), llvm::X86Subtarget::isTargetDarwin(), llvm::X86Subtarget::isTargetELF(), llvm::X86Subtarget::isTargetMingw(), llvm::ISD::JumpTable, llvm::MVT::LAST_VECTOR_VALUETYPE, llvm::TargetLowering::Legal, llvm::ISD::LOAD, llvm::TargetLowering::maxStoresPerMemcpy, llvm::TargetLowering::maxStoresPerMemmove, llvm::TargetLowering::maxStoresPerMemset, llvm::ISD::MEMBARRIER, llvm::ISD::MUL, llvm::ISD::MULHS, llvm::ISD::MULHU, llvm::ISD::OR, llvm::MVT::Other, llvm::ISD::PREFETCH, llvm::TargetLowering::Promote, llvm::ISD::READCYCLECOUNTER, llvm::APFloat::rmNearestTiesToEven, llvm::ISD::ROTL, llvm::ISD::ROTR, llvm::ISD::SADDO, llvm::ISD::SCALAR_TO_VECTOR, llvm::TargetLowering::SchedulingForRegPressure, llvm::ISD::SDIV, llvm::ISD::SDIVREM, llvm::ISD::SELECT, llvm::ISD::SELECT_CC, llvm::TargetLowering::setBooleanContents(), llvm::ISD::SETCC, llvm::TargetLowering::setCondCodeAction(), llvm::TargetLowering::setExceptionPointerRegister(), llvm::TargetLowering::setExceptionSelectorRegister(), llvm::TargetLowering::setLibcallName(), llvm::TargetLowering::setLoadExtAction(), llvm::ISD::SETOEQ, llvm::TargetLowering::setOperationAction(), llvm::TargetLowering::setPrefLoopAlignment(), llvm::TargetLowering::setSchedulingPreference(), llvm::TargetLowering::setShiftAmountType(), llvm::TargetLowering::setStackPointerRegisterToSaveRestore(), llvm::TargetLowering::setTargetDAGCombine(), llvm::TargetLowering::setTruncStoreAction(), llvm::ISD::SETUNE, llvm::TargetLowering::setUseUnderscoreLongJmp(), llvm::TargetLowering::setUseUnderscoreSetJmp(), llvm::ISD::SEXTLOAD, llvm::ISD::SHL, llvm::RTLIB::SHL_I128, llvm::ISD::SHL_PARTS, llvm::ISD::SIGN_EXTEND_INREG, llvm::MVT::SimpleTy, llvm::ISD::SINT_TO_FP, llvm::ISD::SMUL_LOHI, llvm::ISD::SMULO, llvm::ISD::SRA, llvm::RTLIB::SRA_I128, llvm::ISD::SRA_PARTS, llvm::ISD::SREM, llvm::ISD::SRL, llvm::RTLIB::SRL_I128, llvm::ISD::SRL_PARTS, llvm::ISD::SSUBO, llvm::ISD::STACKRESTORE, llvm::ISD::STACKSAVE, llvm::ISD::STORE, llvm::ISD::SUB, llvm::ISD::TRAMPOLINE, llvm::ISD::TRAP, llvm::ISD::TRUNCATE, llvm::ISD::UADDO, llvm::ISD::UDIV, llvm::ISD::UDIVREM, llvm::ISD::UINT_TO_FP, llvm::ISD::UMUL_LOHI, llvm::ISD::UNDEF, llvm::UnsafeFPMath, llvm::ISD::UREM, llvm::UseSoftFloat, llvm::ISD::USUBO, llvm::MVT::v16i8, llvm::MVT::v1i64, llvm::MVT::v2f32, llvm::MVT::v2f64, llvm::MVT::v2i32, llvm::MVT::v2i64, llvm::MVT::v4f32, llvm::MVT::v4f64, llvm::MVT::v4i16, llvm::MVT::v4i32, llvm::MVT::v4i64, llvm::MVT::v8f32, llvm::MVT::v8i16, llvm::MVT::v8i32, llvm::MVT::v8i8, llvm::ISD::VAARG, llvm::ISD::VACOPY, llvm::ISD::VAEND, llvm::ISD::VASTART, llvm::ISD::VECTOR_SHUFFLE, llvm::ISD::VSETCC, VT, llvm::APFloat::x87DoubleExtended, llvm::ISD::XOR, and llvm::TargetLowering::ZeroOrOneBooleanContent.


Member Function Documentation

SDValue X86TargetLowering::getPICJumpTableRelocBase ( SDValue  Table,
SelectionDAG &  DAG 
) const [virtual]

getPICJumpTableRelocaBase - Returns relocation base for the given PIC jumptable.

getPICJumpTableRelocaBase - Returns relocation base for the given PIC jumptable.

Reimplemented from llvm::TargetLowering.

Definition at line 1041 of file X86ISelLowering.cpp.

References llvm::SelectionDAG::getGLOBAL_OFFSET_TABLE(), llvm::SelectionDAG::getNode(), llvm::TargetLowering::getPointerTy(), llvm::DebugLoc::getUnknownLoc(), llvm::X86ISD::GlobalBaseReg, llvm::X86Subtarget::is64Bit(), and llvm::TargetLowering::usesGlobalOffsetTable().

unsigned llvm::X86TargetLowering::getBytesToPopOnReturn (  )  const [inline]

Definition at line 372 of file X86ISelLowering.h.

unsigned llvm::X86TargetLowering::getBytesCallerReserves (  )  const [inline]

Definition at line 376 of file X86ISelLowering.h.

unsigned llvm::X86TargetLowering::getStackPtrReg (  )  const [inline]

getStackPtrReg - Return the stack pointer register we are using: either ESP or RSP.

Definition at line 380 of file X86ISelLowering.h.

unsigned X86TargetLowering::getByValTypeAlignment ( const Type *  Ty  )  const [virtual]

getByValTypeAlignment - Return the desired alignment for ByVal aggregate function arguments in the caller parameter area. For X86, aggregates that contains are placed at 16-byte boundaries while the rest are at 4-byte boundaries.

getByValTypeAlignment - Return the desired alignment for ByVal aggregate function arguments in the caller parameter area. For X86, aggregates that contain SSE vectors are placed at 16-byte boundaries while the rest are at 4-byte boundaries.

Reimplemented from llvm::TargetLowering.

Definition at line 1000 of file X86ISelLowering.cpp.

References Align, llvm::TargetData::getABITypeAlignment(), getMaxByValAlign(), llvm::X86Subtarget::hasSSE1(), and llvm::X86Subtarget::is64Bit().

EVT X86TargetLowering::getOptimalMemOpType ( uint64_t  Size,
unsigned  Align,
bool  isSrcConst,
bool  isSrcStr,
SelectionDAG &  DAG 
) const [virtual]

getOptimalMemOpType - Returns the target specific optimal type for load and store operations as a result of memset, memcpy, and memmove lowering. It returns EVT::iAny if SelectionDAG should be responsible for determining it.

getOptimalMemOpType - Returns the target specific optimal type for load and store operations as a result of memset, memcpy, and memmove lowering. It returns MVT::iAny if SelectionDAG should be responsible for determining it.

Reimplemented from llvm::TargetLowering.

Definition at line 1020 of file X86ISelLowering.cpp.

References F, llvm::MachineFunction::getFunction(), llvm::SelectionDAG::getMachineFunction(), llvm::X86Subtarget::getStackAlignment(), llvm::Function::hasFnAttr(), llvm::X86Subtarget::hasSSE1(), llvm::X86Subtarget::hasSSE2(), llvm::MVT::i32, llvm::MVT::i64, llvm::X86Subtarget::is64Bit(), llvm::Attribute::NoImplicitFloat, llvm::MVT::v4f32, and llvm::MVT::v4i32.

virtual bool llvm::X86TargetLowering::allowsUnalignedMemoryAccesses ( EVT  VT  )  const [inline, virtual]

allowsUnalignedMemoryAccesses - Returns true if the target allows unaligned memory accesses. of the specified type.

Reimplemented from llvm::TargetLowering.

Definition at line 398 of file X86ISelLowering.h.

SDValue X86TargetLowering::LowerOperation ( SDValue  Op,
SelectionDAG &  DAG 
) [virtual]

void X86TargetLowering::ReplaceNodeResults ( SDNode *  N,
SmallVectorImpl< SDValue > &  Results,
SelectionDAG &  DAG 
) [virtual]

SDValue X86TargetLowering::PerformDAGCombine ( SDNode *  N,
DAGCombinerInfo &  DCI 
) const [virtual]

PerformDAGCombine - This method will be invoked for all target nodes and for any target-independent nodes that the target has registered with invoke it for.

The semantics are as follows: Return Value: SDValue.Val == 0 - No change was made SDValue.Val == N - N was replaced, is dead, and is already handled. otherwise - N should be replaced by the returned Operand.

In addition, methods provided by DAGCombinerInfo may be used to perform more complex transformations.

Reimplemented from llvm::TargetLowering.

Definition at line 8822 of file X86ISelLowering.cpp.

References llvm::X86ISD::BT, llvm::X86ISD::CMOV, llvm::TargetLowering::DAGCombinerInfo::DAG, llvm::X86ISD::FAND, llvm::X86ISD::FOR, llvm::X86ISD::FXOR, llvm::SDNode::getOpcode(), llvm::ISD::MEMBARRIER, llvm::ISD::MUL, PerformBTCombine(), PerformCMOVCombine(), PerformFANDCombine(), PerformFORCombine(), PerformMEMBARRIERCombine(), PerformMulCombine(), PerformSELECTCombine(), PerformShiftCombine(), PerformShuffleCombine(), PerformSTORECombine(), PerformVZEXT_MOVLCombine(), llvm::ISD::SELECT, llvm::ISD::SHL, llvm::ISD::SRA, llvm::ISD::SRL, llvm::ISD::STORE, llvm::ISD::VECTOR_SHUFFLE, and llvm::X86ISD::VZEXT_MOVL.

MachineBasicBlock * X86TargetLowering::EmitInstrWithCustomInserter ( MachineInstr *  MI,
MachineBasicBlock *  MBB 
) const [virtual]

Reimplemented from llvm::TargetLowering.

Definition at line 7704 of file X86ISelLowering.cpp.

References llvm::addFrameReference(), llvm::addFullAddress(), llvm::MachineInstrBuilder::addImm(), llvm::MachineInstrBuilder::addReg(), llvm::MachineBasicBlock::addSuccessor(), llvm::ARMCC::AL, llvm::X86AddressMode::Base, llvm::X86AddressMode::BaseType, llvm::BuildMI(), llvm::MachineFunction::CreateMachineBasicBlock(), llvm::MachineFrameInfo::CreateStackObject(), llvm::MachineRegisterInfo::createVirtualRegister(), llvm::MachineFunction::DeleteMachineInstr(), llvm::X86AddressMode::Disp, llvm::N86::EAX, llvm::X86ISD::FNSTCW16m, llvm::X86AddressMode::FrameIndex, llvm::X86AddressMode::FrameIndexBase, llvm::TargetInstrInfo::get(), llvm::MachineBasicBlock::getBasicBlock(), GetCondBranchFromCond(), llvm::MachineInstr::getDebugLoc(), llvm::MachineFunction::getFrameInfo(), llvm::MachineOperand::getGlobal(), llvm::MachineOperand::getImm(), llvm::MachineOperand::getIndex(), llvm::TargetMachine::getInstrInfo(), llvm::MachineInstr::getOpcode(), llvm::MachineInstr::getOperand(), llvm::MachineBasicBlock::getParent(), llvm::MachineOperand::getReg(), llvm::MachineFunction::getRegInfo(), llvm::TargetLowering::getTargetMachine(), llvm::X86AddressMode::GV, llvm::X86AddressMode::IndexReg, llvm::MachineFunction::insert(), llvm::MachineOperand::isGlobal(), llvm::MachineOperand::isImm(), llvm::MachineOperand::isReg(), llvm_unreachable, PHI, llvm::X86AddressMode::Reg, llvm::X86AddressMode::RegBase, llvm::X86AddressMode::Scale, llvm::MachineBasicBlock::transferSuccessors(), and llvm::X86ISD::VASTART_SAVE_XMM_REGS.

const char * X86TargetLowering::getTargetNodeName ( unsigned  Opcode  )  const [virtual]

getTargetNodeName - This method returns the name of a target specific DAG node.

Reimplemented from llvm::TargetLowering.

Definition at line 7024 of file X86ISelLowering.cpp.

References llvm::X86ISD::ADD, llvm::X86ISD::ATOMADD64_DAG, llvm::X86ISD::ATOMAND64_DAG, llvm::X86ISD::ATOMNAND64_DAG, llvm::X86ISD::ATOMOR64_DAG, llvm::X86ISD::ATOMSUB64_DAG, llvm::X86ISD::ATOMXOR64_DAG, llvm::X86ISD::BRCOND, llvm::X86ISD::BSF, llvm::X86ISD::BSR, llvm::X86ISD::BT, llvm::X86ISD::CALL, llvm::X86ISD::CMOV, llvm::X86ISD::CMP, llvm::X86ISD::CMPPD, llvm::X86ISD::CMPPS, llvm::X86ISD::COMI, llvm::X86ISD::DEC, llvm::X86ISD::EH_RETURN, llvm::X86ISD::FAND, llvm::X86ISD::FILD_FLAG, llvm::X86ISD::FLD, llvm::X86ISD::FMAX, llvm::X86ISD::FMIN, llvm::X86ISD::FNSTCW16m, llvm::X86ISD::FOR, llvm::X86ISD::FP_TO_INT16_IN_MEM, llvm::X86ISD::FP_TO_INT32_IN_MEM, llvm::X86ISD::FP_TO_INT64_IN_MEM, llvm::X86ISD::FRCP, llvm::X86ISD::FRSQRT, llvm::X86ISD::FSRL, llvm::X86ISD::FST, llvm::X86ISD::FXOR, llvm::X86ISD::GlobalBaseReg, llvm::X86ISD::INC, llvm::X86ISD::INSERTPS, llvm::X86ISD::LCMPXCHG8_DAG, llvm::X86ISD::LCMPXCHG_DAG, llvm::X86ISD::MUL_IMM, llvm::X86ISD::PCMPEQB, llvm::X86ISD::PCMPEQD, llvm::X86ISD::PCMPEQQ, llvm::X86ISD::PCMPEQW, llvm::X86ISD::PCMPGTB, llvm::X86ISD::PCMPGTD, llvm::X86ISD::PCMPGTQ, llvm::X86ISD::PCMPGTW, llvm::X86ISD::PEXTRB, llvm::X86ISD::PEXTRW, llvm::X86ISD::PINSRB, llvm::X86ISD::PINSRW, llvm::X86ISD::PSHUFB, llvm::X86ISD::PTEST, llvm::X86ISD::RDTSC_DAG, llvm::X86ISD::REP_MOVS, llvm::X86ISD::REP_STOS, llvm::X86ISD::RET_FLAG, llvm::X86ISD::SegmentBaseAddress, llvm::X86ISD::SETCC, llvm::X86ISD::SHLD, llvm::X86ISD::SHRD, llvm::X86ISD::SMUL, llvm::X86ISD::SUB, llvm::X86ISD::TC_RETURN, llvm::X86ISD::TLSADDR, llvm::X86ISD::UCOMI, llvm::X86ISD::UMUL, llvm::X86ISD::VASTART_SAVE_XMM_REGS, llvm::X86ISD::VSHL, llvm::X86ISD::VSRL, llvm::X86ISD::VZEXT_LOAD, llvm::X86ISD::VZEXT_MOVL, llvm::X86ISD::Wrapper, and llvm::X86ISD::WrapperRIP.

MVT::SimpleValueType X86TargetLowering::getSetCCResultType ( EVT  VT  )  const [virtual]

getSetCCResultType - Return the ISD::SETCC ValueType

Reimplemented from llvm::TargetLowering.

Definition at line 965 of file X86ISelLowering.cpp.

References llvm::MVT::i8.

void X86TargetLowering::computeMaskedBitsForTargetNode ( const SDValue  Op,
const APInt &  Mask,
APInt &  KnownZero,
APInt &  KnownOne,
const SelectionDAG &  DAG,
unsigned  Depth = 0 
) const [virtual]

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

Reimplemented from llvm::TargetLowering.

Definition at line 8025 of file X86ISelLowering.cpp.

References llvm::X86ISD::ADD, llvm::ISD::BUILTIN_OP_END, llvm::X86ISD::DEC, llvm::APInt::getBitWidth(), llvm::APInt::getHighBitsSet(), llvm::SDValue::getOpcode(), llvm::SDValue::getResNo(), llvm::X86ISD::INC, llvm::ISD::INTRINSIC_VOID, llvm::ISD::INTRINSIC_W_CHAIN, llvm::ISD::INTRINSIC_WO_CHAIN, llvm::X86ISD::SETCC, llvm::X86ISD::SMUL, llvm::X86ISD::SUB, and llvm::X86ISD::UMUL.

bool X86TargetLowering::isGAPlusOffset ( SDNode *  N,
GlobalValue *&  GA,
int64_t &  Offset 
) const [virtual]

isGAPlusOffset - Returns true (and the GlobalValue and the offset) if the node is a GlobalAddress + offset.

Reimplemented from llvm::TargetLowering.

Definition at line 8061 of file X86ISelLowering.cpp.

References llvm::SDNode::getOpcode(), llvm::SDNode::getOperand(), llvm::TargetLowering::isGAPlusOffset(), and llvm::X86ISD::Wrapper.

SDValue X86TargetLowering::getReturnAddressFrameIndex ( SelectionDAG &  DAG  ) 

bool X86TargetLowering::ExpandInlineAsm ( CallInst *  CI  )  const [virtual]

ExpandInlineAsm - This hook allows the target to expand an inline asm call to be explicit llvm code if it wants to. This is useful for turning simple inline asms into LLVM intrinsics, which gives the compiler more information about the behavior of the code.

Reimplemented from llvm::TargetLowering.

Definition at line 8879 of file X86ISelLowering.cpp.

References Constraints, llvm::InlineAsm::getAsmString(), llvm::CallInst::getCalledValue(), llvm::InlineAsm::getConstraintString(), llvm::Value::getContext(), llvm::Type::getInt16Ty(), llvm::Type::getInt64Ty(), llvm::Value::getType(), LowerToBSwap(), llvm::InlineAsm::ParseConstraints(), and llvm::SplitString().

X86TargetLowering::ConstraintType X86TargetLowering::getConstraintType ( const std::string &  Constraint  )  const [virtual]

getConstraintType - Given a constraint letter, return the type of constraint it is for this target.

Reimplemented from llvm::TargetLowering.

Definition at line 8948 of file X86ISelLowering.cpp.

References llvm::TargetLowering::C_Other, llvm::TargetLowering::C_Register, llvm::TargetLowering::C_RegisterClass, and llvm::TargetLowering::getConstraintType().

std::vector< unsigned > X86TargetLowering::getRegClassForInlineAsmConstraint ( const std::string &  Constraint,
EVT  VT 
) const [virtual]

getRegClassForInlineAsmConstraint - Given a constraint letter (e.g. "r"), return a list of registers that can be used to satisfy the constraint. This should only be used for C_RegisterClass constraints.

Reimplemented from llvm::TargetLowering.

Definition at line 9123 of file X86ISelLowering.cpp.

References llvm::ARMCC::AL, llvm::XCoreISD::BL, llvm::N86::EAX, llvm::N86::EBP, llvm::N86::EBX, llvm::N86::EDI, llvm::N86::EDX, llvm::N86::ESI, llvm::N86::ESP, llvm::MVT::i16, llvm::MVT::i32, llvm::MVT::i8, and llvm::X86Subtarget::is64Bit().

const char * X86TargetLowering::LowerXConstraint ( EVT  ConstraintVT  )  const [virtual]

LowerXConstraint - try to replace an X constraint, which matches anything, with another that has more specific requirements based on the type of the corresponding operand.

Reimplemented from llvm::TargetLowering.

Definition at line 8977 of file X86ISelLowering.cpp.

References llvm::X86Subtarget::hasSSE1(), llvm::X86Subtarget::hasSSE2(), llvm::EVT::isFloatingPoint(), and llvm::TargetLowering::LowerXConstraint().

void X86TargetLowering::LowerAsmOperandForConstraint ( SDValue  Op,
char  Constraint,
bool  hasMemory,
std::vector< SDValue > &  Ops,
SelectionDAG &  DAG 
) const [virtual]

LowerAsmOperandForConstraint - Lower the specified operand into the Ops vector. If it is invalid, don't add anything to Ops. If hasMemory is true it means one of the asm constraint of the inline asm instruction being processed is 'm'.

LowerAsmOperandForConstraint - Lower the specified operand into the Ops vector. If it is invalid, don't add anything to Ops.

Reimplemented from llvm::TargetLowering.

Definition at line 8992 of file X86ISelLowering.cpp.

References llvm::ISD::ADD, llvm::X86Subtarget::ClassifyGlobalReference(), llvm::SelectionDAG::getContext(), llvm::SDValue::getDebugLoc(), llvm::GlobalAddressSDNode::getGlobal(), llvm::Type::getInt32Ty(), llvm::SDValue::getNode(), llvm::GlobalAddressSDNode::getOffset(), llvm::SDValue::getOpcode(), llvm::SDValue::getOperand(), llvm::SelectionDAG::getTargetConstant(), llvm::SelectionDAG::getTargetGlobalAddress(), llvm::TargetLowering::getTargetMachine(), llvm::SDNode::getValueType(), llvm::SDValue::getValueType(), llvm::isGlobalStubReference(), llvm::ConstantInt::isValueValidForType(), llvm::TargetLowering::LowerAsmOperandForConstraint(), and llvm::ISD::SUB.

std::pair< unsigned, const TargetRegisterClass * > X86TargetLowering::getRegForInlineAsmConstraint ( const std::string &  Constraint,
EVT  VT 
) const [virtual]

bool X86TargetLowering::isLegalAddressingMode ( const AddrMode &  AM,
const Type *  Ty 
) const [virtual]

bool X86TargetLowering::isTruncateFree ( const Type *  Ty1,
const Type *  Ty2 
) const [virtual]

isTruncateFree - Return true if it's free to truncate a value of type Ty1 to type Ty2. e.g. On x86 it's free to truncate a i32 value in register EAX to i16 by referencing its sub-register AX.

Reimplemented from llvm::TargetLowering.

Definition at line 7159 of file X86ISelLowering.cpp.

References llvm::Type::getPrimitiveSizeInBits(), llvm::X86Subtarget::is64Bit(), and llvm::Type::isInteger().

bool X86TargetLowering::isTruncateFree ( EVT  VT1,
EVT  VT2 
) const [virtual]

bool X86TargetLowering::isZExtFree ( const Type *  Ty1,
const Type *  Ty2 
) const [virtual]

isZExtFree - Return true if any actual instruction that defines a value of type Ty1 implicit zero-extends the value to Ty2 in the result register. This does not necessarily include registers defined in unknown ways, such as incoming arguments, or copies from unknown virtual registers. Also, if isTruncateFree(Ty2, Ty1) is true, this does not necessarily apply to truncate instructions. e.g. on x86-64, all instructions that define 32-bit values implicit zero-extend the result out to 64 bits.

Reimplemented from llvm::TargetLowering.

Definition at line 7179 of file X86ISelLowering.cpp.

References llvm::Type::getContext(), llvm::Type::getInt32Ty(), llvm::Type::getInt64Ty(), and llvm::X86Subtarget::is64Bit().

bool X86TargetLowering::isZExtFree ( EVT  VT1,
EVT  VT2 
) const [virtual]

Reimplemented from llvm::TargetLowering.

Definition at line 7185 of file X86ISelLowering.cpp.

References llvm::MVT::i32, and llvm::X86Subtarget::is64Bit().

bool X86TargetLowering::isNarrowingProfitable ( EVT  VT1,
EVT  VT2 
) const [virtual]

isNarrowingProfitable - Return true if it's profitable to narrow operations of type VT1 to VT2. e.g. on x86, it's profitable to narrow from i32 to i8 but not from i32 to i16.

Reimplemented from llvm::TargetLowering.

Definition at line 7190 of file X86ISelLowering.cpp.

References llvm::MVT::i16, and llvm::MVT::i32.

bool X86TargetLowering::isShuffleMaskLegal ( const SmallVectorImpl< int > &  M,
EVT  VT 
) const [virtual]

isShuffleMaskLegal - Targets can use this to indicate that they only support *some* VECTOR_SHUFFLE operations, those with specific masks. By default, if a target supports the VECTOR_SHUFFLE node, all mask values are assumed to be legal.

isShuffleMaskLegal - Targets can use this to indicate that they only support *some* VECTOR_SHUFFLE operations, those with specific masks. By default, if a target supports the VECTOR_SHUFFLE node, all mask values are assumed to be legal.

Reimplemented from llvm::TargetLowering.

Definition at line 7200 of file X86ISelLowering.cpp.

References llvm::EVT::getSizeInBits(), llvm::EVT::getVectorNumElements(), isMOVLMask(), isPSHUFDMask(), isPSHUFHWMask(), isPSHUFLWMask(), isSHUFPMask(), llvm::ShuffleVectorSDNode::isSplatMask(), isUNPCKH_v_undef_Mask(), isUNPCKHMask(), isUNPCKL_v_undef_Mask(), and isUNPCKLMask().

bool X86TargetLowering::isVectorClearMaskLegal ( const SmallVectorImpl< int > &  Mask,
EVT  VT 
) const [virtual]

isVectorClearMaskLegal - Similar to isShuffleMaskLegal. This is used by Targets can use this to indicate if there is a suitable VECTOR_SHUFFLE that can be used to replace a VAND with a constant pool entry.

Reimplemented from llvm::TargetLowering.

Definition at line 7221 of file X86ISelLowering.cpp.

References llvm::EVT::getSizeInBits(), llvm::EVT::getVectorNumElements(), isCommutedMOVLMask(), isCommutedSHUFPMask(), isMOVLMask(), and isSHUFPMask().

virtual bool llvm::X86TargetLowering::ShouldShrinkFPConstant ( EVT  VT  )  const [inline, virtual]

ShouldShrinkFPConstant - If true, then instruction selection should seek to shrink the FP constant of the specified type to a smaller type in order to save space and / or reduce runtime.

Reimplemented from llvm::TargetLowering.

Definition at line 512 of file X86ISelLowering.h.

References llvm::MVT::f80.

bool X86TargetLowering::IsEligibleForTailCallOptimization ( SDValue  Callee,
unsigned  CalleeCC,
bool  isVarArg,
const SmallVectorImpl< ISD::InputArg > &  Ins,
SelectionDAG &  DAG 
) const [virtual]

IsEligibleForTailCallOptimization - Check whether the call is eligible for tail call optimization. Targets which want to do tail call optimization should implement this function.

IsEligibleForTailCallOptimization - Check whether the call is eligible for tail call optimization. Targets which want to do tail call optimization should implement this function.

Reimplemented from llvm::TargetLowering.

Definition at line 2099 of file X86ISelLowering.cpp.

References llvm::CallingConv::Fast, llvm::Function::getCallingConv(), llvm::MachineFunction::getFunction(), and llvm::SelectionDAG::getMachineFunction().

virtual const X86Subtarget* llvm::X86TargetLowering::getSubtarget (  )  [inline, virtual]

Reimplemented from llvm::TargetLowering.

Definition at line 529 of file X86ISelLowering.h.

Referenced by LowerVECTOR_SHUFFLEv16i8(), and LowerVECTOR_SHUFFLEv8i16().

bool llvm::X86TargetLowering::isScalarFPTypeInSSEReg ( EVT  VT  )  const [inline]

isScalarFPTypeInSSEReg - Return true if the specified scalar FP type is computed in an SSE register, not on the X87 floating point stack.

Definition at line 535 of file X86ISelLowering.h.

References llvm::MVT::f32, and llvm::MVT::f64.

Referenced by getRegForInlineAsmConstraint().

EVT X86TargetLowering::getWidenVectorType ( EVT  VT  )  const [virtual]

getWidenVectorType: given a vector type, returns the type to widen to (e.g., v7i8 to v8i8). If the vector type is legal, it returns itself. If there is no vector type that we want to widen to, returns EVT::Other When and were to widen is target dependent based on the cost of scalarizing vs using the wider vector type.

getWidenVectorType: given a vector type, returns the type to widen to (e.g., v7i8 to v8i8). If the vector type is legal, it returns itself. If there is no vector type that we want to widen to, returns MVT::Other When and where to widen is target dependent based on the cost of scalarizing vs using the wider vector type.

Reimplemented from llvm::TargetLowering.

Definition at line 9341 of file X86ISelLowering.cpp.

References llvm::MVT::FIRST_VECTOR_VALUETYPE, llvm::EVT::getVectorElementType(), llvm::EVT::getVectorNumElements(), llvm::TargetLowering::isTypeLegal(), llvm::EVT::isVector(), llvm::MVT::LAST_VECTOR_VALUETYPE, and llvm::MVT::Other.

FastISel * X86TargetLowering::createFastISel ( MachineFunction &  mf,
MachineModuleInfo *  mmi,
DwarfWriter *  dw,
DenseMap< const Value *, unsigned > &  vm,
DenseMap< const BasicBlock *, MachineBasicBlock * > &  bm,
DenseMap< const AllocaInst *, int > &  am,
SmallSet< Instruction *, 8 > &  cil 
) [virtual]

createFastISel - This method returns a target specific FastISel object, or null if the target does not support "fast" ISel.

Reimplemented from llvm::TargetLowering.

Definition at line 2110 of file X86ISelLowering.cpp.

References llvm::X86::createFastISel().

unsigned X86TargetLowering::getFunctionAlignment ( const Function *  F  )  const [virtual]

getFunctionAlignment - Return the Log2 alignment of this function.

Implements llvm::TargetLowering.

Definition at line 1054 of file X86ISelLowering.cpp.

References llvm::Function::hasFnAttr(), and llvm::Attribute::OptimizeForSize.


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