|
LLVM
10.0.0
|
SelectionDAGBuilder - This is the common target-independent lowering implementation that is parameterized by a TargetLowering object. More...
#include "CodeGen/SelectionDAG/SelectionDAGBuilder.h"
Classes | |
| class | SDAGSwitchLowering |
| struct | StatepointLoweringInfo |
| Describes a gc.statepoint or a gc.statepoint like thing for the purposes of lowering into a STATEPOINT node. More... | |
Public Member Functions | |
| SelectionDAGBuilder (SelectionDAG &dag, FunctionLoweringInfo &funcinfo, SwiftErrorValueTracking &swifterror, CodeGenOpt::Level ol) | |
| void | init (GCFunctionInfo *gfi, AliasAnalysis *AA, const TargetLibraryInfo *li) |
| void | clear () |
| Clear out the current SelectionDAG and the associated state and prepare this SelectionDAGBuilder object to be used for a new block. More... | |
| void | clearDanglingDebugInfo () |
| Clear the dangling debug information map. More... | |
| SDValue | getMemoryRoot () |
| Return the current virtual root of the Selection DAG, flushing any PendingLoad items. More... | |
| SDValue | getRoot () |
| Similar to getMemoryRoot, but also flushes PendingConstrainedFP(Strict) items. More... | |
| SDValue | getControlRoot () |
| Similar to getRoot, but instead of flushing all the PendingLoad items, flush all the PendingExports (and PendingConstrainedFPStrict) items. More... | |
| SDLoc | getCurSDLoc () const |
| DebugLoc | getCurDebugLoc () const |
| void | CopyValueToVirtualRegister (const Value *V, unsigned Reg) |
| void | visit (const Instruction &I) |
| void | visit (unsigned Opcode, const User &I) |
| SDValue | getCopyFromRegs (const Value *V, Type *Ty) |
| If there was virtual register allocated for the value V emit CopyFromReg of the specified type Ty. More... | |
| void | dropDanglingDebugInfo (const DILocalVariable *Variable, const DIExpression *Expr) |
If we have dangling debug info that describes Variable, or an overlapping part of variable considering the Expr, then this method will drop that debug info as it isn't valid any longer. More... | |
| void | resolveDanglingDebugInfo (const Value *V, SDValue Val) |
| If we saw an earlier dbg_value referring to V, generate the debug data structures now that we've seen its definition. More... | |
| void | salvageUnresolvedDbgValue (DanglingDebugInfo &DDI) |
| For the given dangling debuginfo record, perform last-ditch efforts to resolve the debuginfo to something that is represented in this DAG. More... | |
| bool | handleDebugValue (const Value *V, DILocalVariable *Var, DIExpression *Expr, DebugLoc CurDL, DebugLoc InstDL, unsigned Order) |
| For a given Value, attempt to create and record a SDDbgValue in the SelectionDAG. More... | |
| void | resolveOrClearDbgInfo () |
| Evict any dangling debug information, attempting to salvage it first. More... | |
| SDValue | getValue (const Value *V) |
| getValue - Return an SDValue for the given Value. More... | |
| bool | findValue (const Value *V) const |
| SDNode * | getNodeForIRValue (const Value *V) |
| Return the SDNode for the specified IR value if it exists. More... | |
| SDValue | getNonRegisterValue (const Value *V) |
| getNonRegisterValue - Return an SDValue for the given Value, but don't look in FuncInfo.ValueMap for a virtual register. More... | |
| SDValue | getValueImpl (const Value *V) |
| getValueImpl - Helper function for getValue and getNonRegisterValue. More... | |
| void | setValue (const Value *V, SDValue NewN) |
| void | setUnusedArgValue (const Value *V, SDValue NewN) |
| void | FindMergedConditions (const Value *Cond, MachineBasicBlock *TBB, MachineBasicBlock *FBB, MachineBasicBlock *CurBB, MachineBasicBlock *SwitchBB, Instruction::BinaryOps Opc, BranchProbability TProb, BranchProbability FProb, bool InvertCond) |
| void | EmitBranchForMergedCondition (const Value *Cond, MachineBasicBlock *TBB, MachineBasicBlock *FBB, MachineBasicBlock *CurBB, MachineBasicBlock *SwitchBB, BranchProbability TProb, BranchProbability FProb, bool InvertCond) |
| EmitBranchForMergedCondition - Helper method for FindMergedConditions. More... | |
| bool | ShouldEmitAsBranches (const std::vector< SwitchCG::CaseBlock > &Cases) |
| If the set of cases should be emitted as a series of branches, return true. More... | |
| bool | isExportableFromCurrentBlock (const Value *V, const BasicBlock *FromBB) |
| void | CopyToExportRegsIfNeeded (const Value *V) |
| CopyToExportRegsIfNeeded - If the given value has virtual registers created for it, emit nodes to copy the value into the virtual registers. More... | |
| void | ExportFromCurrentBlock (const Value *V) |
| ExportFromCurrentBlock - If this condition isn't known to be exported from the current basic block, add it to ValueMap now so that we'll get a CopyTo/FromReg. More... | |
| void | LowerCallTo (ImmutableCallSite CS, SDValue Callee, bool IsTailCall, const BasicBlock *EHPadBB=nullptr) |
| SDValue | lowerRangeToAssertZExt (SelectionDAG &DAG, const Instruction &I, SDValue Op) |
| void | populateCallLoweringInfo (TargetLowering::CallLoweringInfo &CLI, const CallBase *Call, unsigned ArgIdx, unsigned NumArgs, SDValue Callee, Type *ReturnTy, bool IsPatchPoint) |
Populate a CallLowerinInfo (into CLI) based on the properties of the call being lowered. More... | |
| std::pair< SDValue, SDValue > | lowerInvokable (TargetLowering::CallLoweringInfo &CLI, const BasicBlock *EHPadBB=nullptr) |
| void | UpdateSplitBlock (MachineBasicBlock *First, MachineBasicBlock *Last) |
| When an MBB was split during scheduling, update the references that need to refer to the last resulting block. More... | |
| SDValue | LowerAsSTATEPOINT (StatepointLoweringInfo &SI) |
Lower SLI into a STATEPOINT instruction. More... | |
| void | LowerStatepoint (ImmutableStatepoint ISP, const BasicBlock *EHPadBB=nullptr) |
| void | LowerCallSiteWithDeoptBundle (const CallBase *Call, SDValue Callee, const BasicBlock *EHPadBB) |
| void | LowerDeoptimizeCall (const CallInst *CI) |
| void | LowerDeoptimizingReturn () |
| void | LowerCallSiteWithDeoptBundleImpl (const CallBase *Call, SDValue Callee, const BasicBlock *EHPadBB, bool VarArgDisallowed, bool ForceVoidReturnTy) |
| MVT | getFrameIndexTy () |
| Returns the type of FrameIndex and TargetFrameIndex nodes. More... | |
| void | visitSwitchCase (SwitchCG::CaseBlock &CB, MachineBasicBlock *SwitchBB) |
| visitSwitchCase - Emits the necessary code to represent a single node in the binary search tree resulting from lowering a switch instruction. More... | |
| void | visitSPDescriptorParent (StackProtectorDescriptor &SPD, MachineBasicBlock *ParentBB) |
| Codegen a new tail for a stack protector check ParentMBB which has had its tail spliced into a stack protector check success bb. More... | |
| void | visitSPDescriptorFailure (StackProtectorDescriptor &SPD) |
| Codegen the failure basic block for a stack protector check. More... | |
| void | visitBitTestHeader (SwitchCG::BitTestBlock &B, MachineBasicBlock *SwitchBB) |
| visitBitTestHeader - This function emits necessary code to produce value suitable for "bit tests" More... | |
| void | visitBitTestCase (SwitchCG::BitTestBlock &BB, MachineBasicBlock *NextMBB, BranchProbability BranchProbToNext, unsigned Reg, SwitchCG::BitTestCase &B, MachineBasicBlock *SwitchBB) |
| visitBitTestCase - this function produces one "bit test" More... | |
| void | visitJumpTable (SwitchCG::JumpTable &JT) |
| visitJumpTable - Emit JumpTable node in the current MBB More... | |
| void | visitJumpTableHeader (SwitchCG::JumpTable &JT, SwitchCG::JumpTableHeader &JTH, MachineBasicBlock *SwitchBB) |
| visitJumpTableHeader - This function emits necessary code to produce index in the JumpTable from switch case. More... | |
Public Attributes | |
| SmallVector< SDValue, 8 > | PendingLoads |
| Loads are not emitted to the program immediately. More... | |
| StatepointLoweringState | StatepointLowering |
| State used while lowering a statepoint sequence (gc_statepoint, gc_relocate, and gc_result). More... | |
| SelectionDAG & | DAG |
| const DataLayout * | DL = nullptr |
| AliasAnalysis * | AA = nullptr |
| const TargetLibraryInfo * | LibInfo |
| std::unique_ptr< SDAGSwitchLowering > | SL |
| StackProtectorDescriptor | SPDescriptor |
| A StackProtectorDescriptor structure used to communicate stack protector information in between SelectBasicBlock and FinishBasicBlock. More... | |
| DenseMap< const Constant *, unsigned > | ConstantsOut |
| FunctionLoweringInfo & | FuncInfo |
| Information about the function as a whole. More... | |
| SwiftErrorValueTracking & | SwiftError |
| Information about the swifterror values used throughout the function. More... | |
| GCFunctionInfo * | GFI |
| Garbage collection metadata for the function. More... | |
| DenseMap< MachineBasicBlock *, SmallVector< unsigned, 4 > > | LPadToCallSiteMap |
| Map a landing pad to the call site indexes. More... | |
| bool | HasTailCall = false |
| This is set to true if a call in the current block has been translated as a tail call. More... | |
| LLVMContext * | Context |
Static Public Attributes | |
| static const unsigned | LowestSDNodeOrder = 1 |
| Lowest valid SDNodeOrder. More... | |
SelectionDAGBuilder - This is the common target-independent lowering implementation that is parameterized by a TargetLowering object.
Definition at line 96 of file SelectionDAGBuilder.h.
|
inline |
Definition at line 440 of file SelectionDAGBuilder.h.
References clear(), clearDanglingDebugInfo(), getControlRoot(), getMemoryRoot(), getRoot(), and init().
| void SelectionDAGBuilder::clear | ( | ) |
Clear out the current SelectionDAG and the associated state and prepare this SelectionDAGBuilder object to be used for a new block.
This doesn't clear out information about additional blocks that are needed to complete switch lowering or PHI node updating; that information is cleared out as it is consumed.
Definition at line 1023 of file SelectionDAGBuilder.cpp.
Referenced by SelectionDAGBuilder().
| void SelectionDAGBuilder::clearDanglingDebugInfo | ( | ) |
Clear the dangling debug information map.
This function is separated from the clear so that debug information that is dangling in a basic block can be properly resolved in a different basic block. This allows the SelectionDAG to resolve dangling debug information attached to PHI nodes.
Definition at line 1036 of file SelectionDAGBuilder.cpp.
References assert(), llvm::SmallVectorImpl< T >::clear(), llvm::numbers::e, llvm::SmallVectorBase::empty(), llvm::ISD::EntryToken, llvm::SDValue::getOpcode(), llvm::SelectionDAG::getRoot(), llvm::SelectionDAG::getTokenFactor(), llvm::SmallVectorTemplateBase< T >::push_back(), llvm::SelectionDAG::setRoot(), and llvm::SmallVectorBase::size().
Referenced by SelectionDAGBuilder().
CopyToExportRegsIfNeeded - If the given value has virtual registers created for it, emit nodes to copy the value into the virtual registers.
Definition at line 1962 of file SelectionDAGBuilder.cpp.
References assert(), llvm::DenseMapBase< DenseMap< KeyT, ValueT, KeyInfoT, BucketT >, KeyT, ValueT, KeyInfoT, BucketT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::find(), llvm::Value::getType(), llvm::Type::isEmptyTy(), and llvm::Value::use_empty().
Definition at line 9423 of file SelectionDAGBuilder.cpp.
References llvm::ISD::ANY_EXTEND, assert(), llvm::ISD::CopyFromReg, llvm::Value::getContext(), llvm::SelectionDAG::getDataLayout(), llvm::SelectionDAG::getEntryNode(), llvm::SDValue::getOpcode(), llvm::SDValue::getOperand(), getReg(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::Value::getType(), llvm::Register::isPhysicalRegister(), llvm::None, and Reg.
Referenced by getCurDebugLoc().
| void SelectionDAGBuilder::dropDanglingDebugInfo | ( | const DILocalVariable * | Variable, |
| const DIExpression * | Expr | ||
| ) |
If we have dangling debug info that describes Variable, or an overlapping part of variable considering the Expr, then this method will drop that debug info as it isn't valid any longer.
Definition at line 1162 of file SelectionDAGBuilder.cpp.
References llvm::dbgs(), llvm::DIExpression::fragmentsOverlap(), llvm::DbgVariableIntrinsic::getExpression(), llvm::DbgVariableIntrinsic::getVariable(), LLVM_DEBUG, and llvm::remove_if().
Referenced by getCurDebugLoc().
| void SelectionDAGBuilder::EmitBranchForMergedCondition | ( | const Value * | Cond, |
| MachineBasicBlock * | TBB, | ||
| MachineBasicBlock * | FBB, | ||
| MachineBasicBlock * | CurBB, | ||
| MachineBasicBlock * | SwitchBB, | ||
| BranchProbability | TProb, | ||
| BranchProbability | FProb, | ||
| bool | InvertCond | ||
| ) |
EmitBranchForMergedCondition - Helper method for FindMergedConditions.
This function emits a branch and is used at the leaves of an OR or an AND operator tree.
Definition at line 2053 of file SelectionDAGBuilder.cpp.
ExportFromCurrentBlock - If this condition isn't known to be exported from the current basic block, add it to ValueMap now so that we'll get a CopyTo/FromReg.
Definition at line 1977 of file SelectionDAGBuilder.cpp.
References Reg.
Referenced by lowerStatepointMetaArgs().
| void SelectionDAGBuilder::FindMergedConditions | ( | const Value * | Cond, |
| MachineBasicBlock * | TBB, | ||
| MachineBasicBlock * | FBB, | ||
| MachineBasicBlock * | CurBB, | ||
| MachineBasicBlock * | SwitchBB, | ||
| Instruction::BinaryOps | Opc, | ||
| BranchProbability | TProb, | ||
| BranchProbability | FProb, | ||
| bool | InvertCond | ||
| ) |
Definition at line 2100 of file SelectionDAGBuilder.cpp.
Referenced by setUnusedArgValue().
Definition at line 1441 of file SelectionDAGBuilder.cpp.
Referenced by getCurDebugLoc(), and getUniformBase().
| SDValue SelectionDAGBuilder::getControlRoot | ( | ) |
Similar to getRoot, but instead of flushing all the PendingLoad items, flush all the PendingExports (and PendingConstrainedFPStrict) items.
It is necessary to do this before emitting a terminator instruction.
Definition at line 1091 of file SelectionDAGBuilder.cpp.
Referenced by SelectionDAGBuilder().
If there was virtual register allocated for the value V emit CopyFromReg of the specified type Ty.
getCopyFromRegs - If there was virtual register allocated for the value V emit CopyFromReg of the specified type Ty.
Return empty SDValue() otherwise.
Definition at line 1401 of file SelectionDAGBuilder.cpp.
References llvm::DenseMapBase< DenseMap< KeyT, ValueT, KeyInfoT, BucketT >, KeyT, ValueT, KeyInfoT, BucketT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::find(), llvm::SelectionDAG::getContext(), llvm::SelectionDAG::getDataLayout(), llvm::SelectionDAG::getEntryNode(), llvm::SelectionDAG::getTargetLoweringInfo(), and llvm::None.
Referenced by llvm::RegsForValue::append(), and getCurDebugLoc().
|
inline |
Definition at line 482 of file SelectionDAGBuilder.h.
References CopyValueToVirtualRegister(), dropDanglingDebugInfo(), findValue(), getCopyFromRegs(), llvm::Instruction::getDebugLoc(), getValue(), handleDebugValue(), I, Reg, resolveDanglingDebugInfo(), resolveOrClearDbgInfo(), salvageUnresolvedDbgValue(), and visit().
|
inline |
Definition at line 478 of file SelectionDAGBuilder.h.
Referenced by getMemCmpLoad(), getUniformBase(), pushStackMapConstant(), and spillIncomingStatepointValue().
|
inline |
Returns the type of FrameIndex and TargetFrameIndex nodes.
Definition at line 645 of file SelectionDAGBuilder.h.
References llvm::ISD::ADD, llvm::ISD::AND, B, llvm::ISD::FADD, llvm::ISD::FDIV, llvm::ISD::FMUL, llvm::ISD::FNEG, llvm::ISD::FREM, llvm::SelectionDAG::getDataLayout(), llvm::TargetLoweringBase::getFrameIndexTy(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::BranchProbability::getUnknown(), llvm::HexagonISD::JT, llvm_unreachable, llvm::ISD::MUL, N, llvm::ISD::OR, llvm::ISD::SHL, llvm::ISD::SRA, llvm::ISD::SREM, llvm::ISD::SRL, llvm::ISD::SUB, llvm::ISD::UDIV, llvm::ISD::UREM, visitBitTestCase(), visitBitTestHeader(), visitJumpTable(), visitJumpTableHeader(), visitSPDescriptorFailure(), visitSPDescriptorParent(), visitSwitchCase(), and llvm::ISD::XOR.
Referenced by lowerIncomingStatepointValue(), lowerStatepointMetaArgs(), reservePreviousStackSlotForValue(), and spillIncomingStatepointValue().
| SDValue SelectionDAGBuilder::getMemoryRoot | ( | ) |
Return the current virtual root of the Selection DAG, flushing any PendingLoad items.
This must be done before emitting a store or any other memory node that may need to be ordered after any prior load instructions.
Definition at line 1071 of file SelectionDAGBuilder.cpp.
Referenced by SelectionDAGBuilder().
Return the SDNode for the specified IR value if it exists.
Definition at line 524 of file SelectionDAGBuilder.h.
References llvm::DenseMapBase< DenseMap< KeyT, ValueT, KeyInfoT, BucketT >, KeyT, ValueT, KeyInfoT, BucketT >::end(), llvm::DenseMapBase< DenseMap< KeyT, ValueT, KeyInfoT, BucketT >, KeyT, ValueT, KeyInfoT, BucketT >::find(), getNonRegisterValue(), and getValueImpl().
getNonRegisterValue - Return an SDValue for the given Value, but don't look in FuncInfo.ValueMap for a virtual register.
Definition at line 1448 of file SelectionDAGBuilder.cpp.
References llvm::SDValue::getNode(), N, and llvm::SDNode::setDebugLoc().
Referenced by getNodeForIRValue().
| SDValue SelectionDAGBuilder::getRoot | ( | ) |
Similar to getMemoryRoot, but also flushes PendingConstrainedFP(Strict) items.
This must be done before emitting any call other any other node that may need to be ordered after FP instructions due to other side effects.
Definition at line 1075 of file SelectionDAGBuilder.cpp.
Referenced by lowerIncomingStatepointValue(), and SelectionDAGBuilder().
getValue - Return an SDValue for the given Value.
Definition at line 1421 of file SelectionDAGBuilder.cpp.
References llvm::RegsForValue::getCopyFromRegs(), llvm::SDValue::getNode(), llvm::Value::getType(), and N.
Referenced by addStackMapLiveVars(), getCurDebugLoc(), getMemCmpLoad(), getUniformBase(), lowerStatepointMetaArgs(), removeDuplicateGCPtrs(), and reservePreviousStackSlotForValue().
getValueImpl - Helper function for getValue and getNonRegisterValue.
Create an SDValue for the given value.
Definition at line 1471 of file SelectionDAGBuilder.cpp.
References llvm::MachineBasicBlock::addSuccessor(), assert(), llvm::SmallVectorImpl< T >::assign(), llvm::ISD::BR, C, llvm::ISD::CATCHPAD, llvm::ISD::CATCHRET, llvm::classifyEHPersonality(), llvm::ComputeValueVTs(), llvm::CoreCLR, llvm::numbers::e, getABIRegCopyCC(), llvm::SelectionDAG::getBasicBlock(), llvm::SelectionDAG::getBlockAddress(), llvm::SelectionDAG::getBuildVector(), llvm::CatchReturnInst::getCatchSwitchParentPad(), llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getConstantFP(), llvm::SelectionDAG::getContext(), llvm::SelectionDAG::getDataLayout(), llvm::SequentialType::getElementType(), llvm::SelectionDAG::getEntryNode(), llvm::SelectionDAG::getFrameIndex(), llvm::TargetLoweringBase::getFrameIndexTy(), llvm::SelectionDAG::getGlobalAddress(), llvm::SelectionDAG::getMergeValues(), llvm::SDValue::getNode(), llvm::SelectionDAG::getNode(), llvm::SequentialType::getNumElements(), llvm::SDNode::getNumValues(), getParent(), llvm::Type::getPointerAddressSpace(), llvm::TargetLoweringBase::getPointerTy(), llvm::CatchReturnInst::getSuccessor(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::Value::getType(), llvm::SelectionDAG::getUNDEF(), llvm::TargetLoweringBase::getValueType(), I, llvm::Type::isAggregateType(), llvm::Type::isArrayTy(), llvm::isAsynchronousEHPersonality(), llvm::EVT::isFloatingPoint(), llvm::Type::isStructTy(), llvm_unreachable, llvm::MSVC_CXX, llvm::CodeGenOpt::None, llvm::User::op_begin(), llvm::User::op_end(), llvm::MVT::Other, llvm::SmallVectorTemplateBase< T >::push_back(), llvm::MipsISD::Ret, llvm::MachineBasicBlock::setIsEHFuncletEntry(), llvm::MachineBasicBlock::setIsEHScopeEntry(), llvm::SelectionDAG::setRoot(), SI, llvm::SmallVectorBase::size(), llvm::SystemZISD::TM, llvm::RegsForValue::ValueVTs, and llvm::Wasm_CXX.
Referenced by getNodeForIRValue().
| bool SelectionDAGBuilder::handleDebugValue | ( | const Value * | V, |
| DILocalVariable * | Var, | ||
| DIExpression * | Expr, | ||
| DebugLoc | CurDL, | ||
| DebugLoc | InstDL, | ||
| unsigned | Order | ||
| ) |
For a given Value, attempt to create and record a SDDbgValue in the SelectionDAG.
Definition at line 1299 of file SelectionDAGBuilder.cpp.
References llvm::SelectionDAG::AddDbgValue(), llvm::DIExpression::createFragmentExpression(), for(), llvm::SelectionDAG::getConstantDbgValue(), llvm::Value::getContext(), llvm::SelectionDAG::getDataLayout(), llvm::DIExpression::getFragmentInfo(), llvm::SelectionDAG::getFrameIndexDbgValue(), llvm::DebugLoc::getInlinedAt(), llvm::SDValue::getNode(), llvm::DIVariable::getSizeInBits(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::Value::getType(), llvm::SelectionDAG::getVRegDbgValue(), llvm::DILocalVariable::isParameter(), N, llvm::None, Reg, and SI.
Referenced by getCurDebugLoc().
| void SelectionDAGBuilder::init | ( | GCFunctionInfo * | gfi, |
| AliasAnalysis * | AA, | ||
| const TargetLibraryInfo * | li | ||
| ) |
Definition at line 1012 of file SelectionDAGBuilder.cpp.
References aa, Context, llvm::SelectionDAG::getContext(), llvm::SelectionDAG::getDataLayout(), llvm::SelectionDAG::getTargetLoweringInfo(), and llvm::SystemZISD::TM.
Referenced by SelectionDAGBuilder().
| bool SelectionDAGBuilder::isExportableFromCurrentBlock | ( | const Value * | V, |
| const BasicBlock * | FromBB | ||
| ) |
Definition at line 1988 of file SelectionDAGBuilder.cpp.
References llvm::MachineBasicBlock::addSuccessor(), llvm::MachineBasicBlock::addSuccessorWithoutProb(), llvm::MachineBasicBlock::getBasicBlock(), llvm::BranchProbabilityInfo::getEdgeProbability(), llvm::Function::getEntryBlock(), llvm::BasicBlock::getParent(), llvm::BranchProbability::isUnknown(), llvm::succ_size(), and VI.
| SDValue SelectionDAGBuilder::LowerAsSTATEPOINT | ( | SelectionDAGBuilder::StatepointLoweringInfo & | SI | ) |
Lower SLI into a STATEPOINT instruction.
Definition at line 635 of file StatepointLowering.cpp.
References assert(), llvm::SelectionDAGBuilder::StatepointLoweringInfo::Bases, llvm::TargetLowering::CallLoweringInfo::CallConv, llvm::SelectionDAGBuilder::StatepointLoweringInfo::CLI, llvm::SmallVectorTemplateCommon< T >::end(), llvm::ISD::GC_TRANSITION_END, llvm::ISD::GC_TRANSITION_START, llvm::SelectionDAGBuilder::StatepointLoweringInfo::GCRelocates, llvm::GCTransition, llvm::SelectionDAGBuilder::StatepointLoweringInfo::GCTransitionArgs, llvm::SDNode::getGluedNode(), llvm::SDValue::getNode(), llvm::SDNode::getNumOperands(), llvm::SDNode::getOperand(), llvm::Instruction::getParent(), llvm::Value::getType(), llvm::SDValue::getValue(), llvm::MVT::Glue, llvm::MVT::i32, llvm::MVT::i64, llvm::SelectionDAGBuilder::StatepointLoweringInfo::ID, llvm::SmallVectorImpl< T >::insert(), llvm::Type::isPointerTy(), lowerCallFromStatepointLoweringInfo(), lowerStatepointMetaArgs(), llvm::MaskAll, llvm::SelectionDAGBuilder::StatepointLoweringInfo::NumPatchBytes, llvm::SDNode::op_begin(), llvm::SDNode::op_end(), llvm::MVT::Other, llvm::SelectionDAGBuilder::StatepointLoweringInfo::Ptrs, llvm::SmallVectorTemplateBase< T >::push_back(), pushStackMapConstant(), removeDuplicateGCPtrs(), llvm::TargetLowering::CallLoweringInfo::setChain(), llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointFlags, and llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointInstr.
Referenced by llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointLoweringInfo().
| void SelectionDAGBuilder::LowerCallSiteWithDeoptBundle | ( | const CallBase * | Call, |
| SDValue | Callee, | ||
| const BasicBlock * | EHPadBB | ||
| ) |
Definition at line 959 of file StatepointLowering.cpp.
References assert(), llvm::ISD::CopyFromReg, llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getCalledValue(), llvm::GCRelocateInst::getDerivedPtr(), llvm::PointerType::getElementType(), llvm::MachinePointerInfo::getFixedStack(), llvm::SDValue::getNode(), llvm::Instruction::getParent(), llvm::Type::getScalarType(), llvm::GCProjectionInst::getStatepoint(), llvm::Value::getType(), llvm::SDValue::getValue(), I, and llvm::MachineMemOperand::MOLoad.
Referenced by llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointLoweringInfo().
| void SelectionDAGBuilder::LowerCallSiteWithDeoptBundleImpl | ( | const CallBase * | Call, |
| SDValue | Callee, | ||
| const BasicBlock * | EHPadBB, | ||
| bool | VarArgDisallowed, | ||
| bool | ForceVoidReturnTy | ||
| ) |
Definition at line 926 of file StatepointLowering.cpp.
References llvm::CallBase::arg_begin(), Callee, llvm::SelectionDAGBuilder::StatepointLoweringInfo::CLI, llvm::StatepointDirectives::DeoptBundleStatepointID, llvm::SelectionDAGBuilder::StatepointLoweringInfo::DeoptState, llvm::SelectionDAGBuilder::StatepointLoweringInfo::EHPadBB, llvm::CallBase::getAttributes(), llvm::CallBase::getFunctionType(), llvm::CallBase::getNumArgOperands(), llvm::CallBase::getOperandBundle(), llvm::Value::getType(), llvm::Type::getVoidTy(), llvm::SelectionDAGBuilder::StatepointLoweringInfo::ID, llvm::FunctionType::isVarArg(), llvm::TargetLowering::CallLoweringInfo::IsVarArg, llvm::None, llvm::SelectionDAGBuilder::StatepointLoweringInfo::NumPatchBytes, llvm::LLVMContext::OB_deopt, llvm::User::op_begin(), llvm::parseStatepointDirectivesFromAttrs(), SI, and llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointFlags.
Referenced by llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointLoweringInfo().
| void SelectionDAGBuilder::LowerCallTo | ( | ImmutableCallSite | CS, |
| SDValue | Callee, | ||
| bool | IsTailCall, | ||
| const BasicBlock * | EHPadBB = nullptr |
||
| ) |
Definition at line 7149 of file SelectionDAGBuilder.cpp.
References llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, CallBrTy, IterTy >::arg_begin(), llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, CallBrTy, IterTy >::arg_end(), llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, CallBrTy, IterTy >::arg_size(), llvm::AMDGPU::HSAMD::Kernel::Key::Args, llvm::numbers::e, llvm::SelectionDAG::getDataLayout(), llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, CallBrTy, IterTy >::getFunctionType(), llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, CallBrTy, IterTy >::getInstruction(), llvm::Instruction::getParent(), llvm::BasicBlock::getParent(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, CallBrTy, IterTy >::getType(), and llvm::TargetLowering::supportSwiftError().
Definition at line 1048 of file StatepointLowering.cpp.
References Callee.
Referenced by llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointLoweringInfo().
| void SelectionDAGBuilder::LowerDeoptimizingReturn | ( | ) |
Definition at line 1061 of file StatepointLowering.cpp.
References llvm::MVT::Other, and llvm::ISD::TRAP.
Referenced by llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointLoweringInfo().
| std::pair< SDValue, SDValue > SelectionDAGBuilder::lowerInvokable | ( | TargetLowering::CallLoweringInfo & | CLI, |
| const BasicBlock * | EHPadBB = nullptr |
||
| ) |
Definition at line 7077 of file SelectionDAGBuilder.cpp.
References llvm::MachineFunction::addInvoke(), llvm::WinEHFuncInfo::addIPToStateRange(), assert(), llvm::classifyEHPersonality(), llvm::MCContext::createTempSymbol(), llvm::TargetLowering::CallLoweringInfo::CS, llvm::MachineModuleInfo::getContext(), llvm::MachineModuleInfo::getCurrentCallSite(), llvm::SelectionDAG::getEHLabel(), llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, CallBrTy, IterTy >::getInstruction(), llvm::SelectionDAG::getMachineFunction(), llvm::MachineFunction::getMMI(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::MachineFunction::getWinEHFuncInfo(), llvm::MachineFunction::hasEHFunclets(), llvm::isFuncletEHPersonality(), llvm::isScopedEHPersonality(), llvm::TargetLowering::CallLoweringInfo::IsTailCall, llvm::TargetLowering::LowerCallTo(), llvm::MachineFunction::setCallSiteBeginLabel(), llvm::TargetLowering::CallLoweringInfo::setChain(), llvm::MachineModuleInfo::setCurrentCallSite(), and llvm::SelectionDAG::setRoot().
Referenced by lowerCallFromStatepointLoweringInfo().
| SDValue SelectionDAGBuilder::lowerRangeToAssertZExt | ( | SelectionDAG & | DAG, |
| const Instruction & | I, | ||
| SDValue | Op | ||
| ) |
Definition at line 8628 of file SelectionDAGBuilder.cpp.
References llvm::ISD::AssertZext, llvm::tgtok::Bits, llvm::APInt::getActiveBits(), llvm::getConstantRangeFromMetadata(), llvm::SelectionDAG::getContext(), llvm::EVT::getIntegerVT(), llvm::SelectionDAG::getMergeValues(), llvm::Instruction::getMetadata(), llvm::SDValue::getNode(), llvm::SelectionDAG::getNode(), llvm::SDNode::getNumValues(), llvm::ConstantRange::getUnsignedMax(), llvm::ConstantRange::getUnsignedMin(), llvm::SDValue::getValue(), llvm::SDValue::getValueType(), llvm::SelectionDAG::getValueType(), llvm::MipsISD::Hi, I, llvm::ConstantRange::isEmptySet(), llvm::ConstantRange::isFullSet(), llvm::APInt::isMinValue(), llvm::ConstantRange::isUpperWrapped(), llvm::MipsISD::Lo, llvm::max(), llvm::IntegerType::MIN_INT_BITS, and llvm::SmallVectorTemplateBase< T >::push_back().
| void SelectionDAGBuilder::LowerStatepoint | ( | ImmutableStatepoint | ISP, |
| const BasicBlock * | EHPadBB = nullptr |
||
| ) |
Definition at line 833 of file StatepointLowering.cpp.
References llvm::CallingConv::AnyReg, assert(), llvm::StatepointBase< const Function, const Instruction, const Value, const CallBase >::CallArgsBeginPos, llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::deopt_begin(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::deopt_end(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::gc_args_begin(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::gc_args_end(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getActualReturnType(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getCall(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getCalledValue(), llvm::CallBase::getCallingConv(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getFlags(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getGCResult(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getID(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getInstruction(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getNumCallArgs(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getNumPatchBytes(), llvm::Instruction::getParent(), llvm::Type::getPointerAddressSpace(), llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::getRelocates(), llvm::Value::getType(), llvm::Type::isVoidTy(), Reg, SI, and llvm::StatepointBase< FunTy, InstructionTy, ValueTy, CallBaseTy >::verify().
Referenced by llvm::SelectionDAGBuilder::StatepointLoweringInfo::StatepointLoweringInfo().
| void SelectionDAGBuilder::populateCallLoweringInfo | ( | TargetLowering::CallLoweringInfo & | CLI, |
| const CallBase * | Call, | ||
| unsigned | ArgIdx, | ||
| unsigned | NumArgs, | ||
| SDValue | Callee, | ||
| Type * | ReturnTy, | ||
| bool | IsPatchPoint | ||
| ) |
Populate a CallLowerinInfo (into CLI) based on the properties of the call being lowered.
This is a helper for lowering intrinsics that follow a target calling convention or require stack pointer adjustment. Only a subset of the intrinsic's operands need to participate in the calling convention.
Definition at line 8672 of file SelectionDAGBuilder.cpp.
References llvm::AMDGPU::HSAMD::Kernel::Key::Args, assert(), llvm::User::getOperand(), llvm::Value::getType(), and llvm::Type::isEmptyTy().
If we saw an earlier dbg_value referring to V, generate the debug data structures now that we've seen its definition.
Definition at line 1190 of file SelectionDAGBuilder.cpp.
References llvm::SelectionDAG::AddDbgValue(), assert(), llvm::dbgs(), llvm::SDValue::dump(), llvm::UndefValue::get(), llvm::SelectionDAG::getConstantDbgValue(), llvm::DbgVariableIntrinsic::getExpression(), llvm::SDNode::getIROrder(), llvm::SDValue::getNode(), llvm::DbgVariableIntrinsic::getVariable(), llvm::DILocalVariable::isValidLocationForIntrinsic(), LLVM_DEBUG, llvm::max(), and llvm::RegState::Undef.
Referenced by getCurDebugLoc().
| void SelectionDAGBuilder::resolveOrClearDbgInfo | ( | ) |
Evict any dangling debug information, attempting to salvage it first.
Definition at line 1391 of file SelectionDAGBuilder.cpp.
Referenced by getCurDebugLoc().
| void SelectionDAGBuilder::salvageUnresolvedDbgValue | ( | DanglingDebugInfo & | DDI | ) |
For the given dangling debuginfo record, perform last-ditch efforts to resolve the debuginfo to something that is represented in this DAG.
If this cannot be done, produce an Undef debug value record.
Definition at line 1244 of file SelectionDAGBuilder.cpp.
References llvm::SelectionDAG::AddDbgValue(), assert(), llvm::dbgs(), llvm::UndefValue::get(), llvm::SelectionDAG::getConstantDbgValue(), llvm::User::getOperand(), LLVM_DEBUG, llvm::salvageDebugInfoImpl(), and llvm::RegState::Undef.
Referenced by getCurDebugLoc().
Definition at line 539 of file SelectionDAGBuilder.h.
References assert(), FindMergedConditions(), llvm::SDValue::getNode(), and N.
Definition at line 533 of file SelectionDAGBuilder.h.
References assert(), llvm::SDValue::getNode(), and N.
| bool SelectionDAGBuilder::ShouldEmitAsBranches | ( | const std::vector< SwitchCG::CaseBlock > & | Cases | ) |
If the set of cases should be emitted as a series of branches, return true.
If we should emit this as a bunch of and/or'd together conditions, return false.
Definition at line 2226 of file SelectionDAGBuilder.cpp.
References llvm::MachineBasicBlock::addSuccessor(), assert(), llvm::ISD::BR, llvm::numbers::e, llvm::SelectionDAG::getBasicBlock(), llvm::BranchInst::getCondition(), llvm::SelectionDAG::getContext(), llvm::SelectionDAG::getNode(), llvm::BranchInst::getSuccessor(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::ConstantInt::getTrue(), llvm::Instruction::hasMetadata(), llvm::TargetLoweringBase::isJumpExpensive(), llvm::BranchInst::isUnconditional(), llvm::CodeGenOpt::None, llvm::MVT::Other, llvm::ISD::SETEQ, llvm::ISD::SETNE, llvm::SelectionDAG::setRoot(), and llvm::SystemZISD::TM.
| void SelectionDAGBuilder::UpdateSplitBlock | ( | MachineBasicBlock * | First, |
| MachineBasicBlock * | Last | ||
| ) |
When an MBB was split during scheduling, update the references that need to refer to the last resulting block.
Definition at line 2938 of file SelectionDAGBuilder.cpp.
References llvm::ISD::BRIND, llvm::numbers::e, llvm::ISD::FNEG, llvm::BasicBlock::front(), llvm::ISD::FSUB, llvm::IndirectBrInst::getAddress(), llvm::SelectionDAG::getNode(), llvm::IndirectBrInst::getNumSuccessors(), llvm::User::getOperand(), llvm::Instruction::getParent(), llvm::SelectionDAG::getRoot(), llvm::IndirectBrInst::getSuccessor(), llvm::SelectionDAG::getTarget(), llvm::Value::getType(), llvm::SDValue::getValueType(), llvm::ConstantFP::getZeroValueForNegation(), llvm::SmallSet< T, N, C >::insert(), llvm::MachineBasicBlock::normalizeSuccProbs(), llvm::TargetOptions::NoTrapAfterNoreturn, llvm::TargetMachine::Options, llvm::MVT::Other, llvm::SelectionDAG::setRoot(), llvm::ISD::TRAP, and llvm::TargetOptions::TrapUnreachable.
| void SelectionDAGBuilder::visit | ( | const Instruction & | I | ) |
Definition at line 1100 of file SelectionDAGBuilder.cpp.
References llvm::Instruction::getOpcode(), llvm::Instruction::getParent(), I, and llvm::Instruction::isTerminator().
Referenced by getCurDebugLoc().
Definition at line 1150 of file SelectionDAGBuilder.cpp.
References llvm_unreachable.
| void SelectionDAGBuilder::visitBitTestCase | ( | SwitchCG::BitTestBlock & | BB, |
| MachineBasicBlock * | NextMBB, | ||
| BranchProbability | BranchProbToNext, | ||
| unsigned | Reg, | ||
| SwitchCG::BitTestCase & | B, | ||
| MachineBasicBlock * | SwitchBB | ||
| ) |
visitBitTestCase - this function produces one "bit test"
Definition at line 2711 of file SelectionDAGBuilder.cpp.
References llvm::ISD::AND, assert(), llvm::ISD::BR, llvm::ISD::BRCOND, Callee, llvm::ComputeValueVTs(), llvm::CallBase::countOperandBundlesOfType(), llvm::countPopulation(), llvm::countTrailingOnes(), llvm::countTrailingZeros(), llvm::dyn_cast(), llvm::numbers::e, findUnwindDestinations(), llvm::MachineBasicBlock::getBasicBlock(), llvm::SelectionDAG::getBasicBlock(), llvm::CallBase::getCalledValue(), llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getContext(), llvm::SelectionDAG::getCopyFromReg(), llvm::SelectionDAG::getDataLayout(), llvm::CallBrInst::getDefaultDest(), llvm::BranchProbabilityInfo::getEdgeProbability(), llvm::SelectionDAG::getEntryNode(), llvm::CallBrInst::getIndirectDest(), llvm::SelectionDAG::getNode(), llvm::CallBrInst::getNumIndirectDests(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getSetCC(), llvm::TargetLoweringBase::getSetCCResultType(), llvm::InvokeInst::getSuccessor(), llvm::SelectionDAG::getTargetConstant(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::Value::getType(), llvm::SelectionDAG::getVTList(), llvm::BranchProbability::getZero(), llvm::SelectionDAG::getZExtOrTrunc(), llvm::CallBase::hasOperandBundlesOtherThan(), llvm::ISD::INTRINSIC_VOID, llvm::isStatepoint(), llvm::Type::isTokenTy(), llvm_unreachable, llvm::ISD::MERGE_VALUES, llvm::MachineBasicBlock::normalizeSuccProbs(), llvm::LLVMContext::OB_deopt, llvm::MVT::Other, llvm::SmallVectorTemplateBase< T >::push_back(), llvm::MCID::Return, llvm::ISD::SETEQ, llvm::ISD::SETNE, llvm::SelectionDAG::setRoot(), llvm::ISD::SHL, llvm::SmallVectorBase::size(), and llvm::RegsForValue::ValueVTs.
Referenced by getFrameIndexTy().
| void SelectionDAGBuilder::visitBitTestHeader | ( | SwitchCG::BitTestBlock & | B, |
| MachineBasicBlock * | SwitchBB | ||
| ) |
visitBitTestHeader - This function emits necessary code to produce value suitable for "bit tests"
Definition at line 2649 of file SelectionDAGBuilder.cpp.
References llvm::ISD::BR, llvm::ISD::BRCOND, llvm::numbers::e, llvm::SelectionDAG::getBasicBlock(), llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getContext(), llvm::SelectionDAG::getCopyToReg(), llvm::SelectionDAG::getDataLayout(), llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getSetCC(), llvm::TargetLoweringBase::getSetCCResultType(), llvm::EVT::getSimpleVT(), llvm::EVT::getSizeInBits(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::SDValue::getValueType(), llvm::SelectionDAG::getZExtOrTrunc(), llvm::TargetLoweringBase::isTypeLegal(), llvm::isUIntN(), llvm::MachineBasicBlock::normalizeSuccProbs(), llvm::MVT::Other, llvm::SelectionDAG::setRoot(), llvm::ISD::SETUGT, and llvm::ISD::SUB.
Referenced by getFrameIndexTy().
| void SelectionDAGBuilder::visitJumpTable | ( | SwitchCG::JumpTable & | JT | ) |
visitJumpTable - Emit JumpTable node in the current MBB
Definition at line 2434 of file SelectionDAGBuilder.cpp.
References assert(), llvm::ISD::BR_JT, llvm::SelectionDAG::getCopyFromReg(), llvm::SelectionDAG::getDataLayout(), llvm::SelectionDAG::getJumpTable(), llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::SDValue::getValue(), llvm::SwitchCG::JumpTable::JTI, llvm::MVT::Other, llvm::SwitchCG::JumpTable::Reg, and llvm::SelectionDAG::setRoot().
Referenced by getFrameIndexTy().
| void SelectionDAGBuilder::visitJumpTableHeader | ( | SwitchCG::JumpTable & | JT, |
| SwitchCG::JumpTableHeader & | JTH, | ||
| MachineBasicBlock * | SwitchBB | ||
| ) |
visitJumpTableHeader - This function emits necessary code to produce index in the JumpTable from switch case.
Definition at line 2449 of file SelectionDAGBuilder.cpp.
References llvm::ISD::BR, llvm::ISD::BRCOND, llvm::ARCISD::CMP, llvm::SwitchCG::JumpTable::Default, llvm::SelectionDAG::getBasicBlock(), llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getContext(), llvm::SelectionDAG::getCopyToReg(), llvm::SelectionDAG::getDataLayout(), llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getPointerTy(), llvm::SelectionDAG::getSetCC(), llvm::TargetLoweringBase::getSetCCResultType(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::SDValue::getValueType(), llvm::SelectionDAG::getZExtOrTrunc(), llvm::SwitchCG::JumpTable::MBB, llvm::MVT::Other, llvm::SwitchCG::JumpTable::Reg, llvm::SelectionDAG::setRoot(), llvm::ISD::SETUGT, and llvm::ISD::SUB.
Referenced by getFrameIndexTy().
| void SelectionDAGBuilder::visitSPDescriptorFailure | ( | StackProtectorDescriptor & | SPD | ) |
Codegen the failure basic block for a stack protector check.
A failure stack protector machine basic block consists simply of a call to __stack_chk_fail().
For a high level explanation of how this fits into the stack protector generation see the comment on the declaration of class StackProtectorDescriptor.
Definition at line 2631 of file SelectionDAGBuilder.cpp.
References llvm::SelectionDAG::getNode(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::MVT::isVoid, llvm::TargetLowering::makeLibCall(), llvm::None, llvm::MVT::Other, llvm::TargetLowering::MakeLibCallOptions::setDiscardResult(), llvm::SelectionDAG::setRoot(), llvm::SystemZISD::TM, and llvm::ISD::TRAP.
Referenced by getFrameIndexTy().
| void SelectionDAGBuilder::visitSPDescriptorParent | ( | StackProtectorDescriptor & | SPD, |
| MachineBasicBlock * | ParentBB | ||
| ) |
Codegen a new tail for a stack protector check ParentMBB which has had its tail spliced into a stack protector check success bb.
For a high level explanation of how this fits into the stack protector generation see the comment on the declaration of class StackProtectorDescriptor.
Definition at line 2533 of file SelectionDAGBuilder.cpp.
References llvm::AMDGPU::HSAMD::Kernel::Key::Args, assert(), llvm::TargetLowering::emitStackGuardXorFP(), llvm::Module::getContext(), llvm::SelectionDAG::getDataLayout(), llvm::SelectionDAG::getEntryNode(), llvm::MachinePointerInfo::getFixedStack(), llvm::SelectionDAG::getFrameIndex(), llvm::MachineFunction::getFrameInfo(), llvm::MachineFunction::getFunction(), llvm::Type::getInt8PtrTy(), llvm::SelectionDAG::getLoad(), llvm::SelectionDAG::getMachineFunction(), llvm::FunctionType::getNumParams(), llvm::MachineBasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::TargetLoweringBase::getPointerMemTy(), llvm::TargetLoweringBase::getPointerTy(), llvm::TargetLoweringBase::getSSPStackGuardCheck(), llvm::MachineFrameInfo::getStackProtectorIndex(), llvm::SelectionDAG::getTargetLoweringInfo(), llvm::MachineMemOperand::MOVolatile, and llvm::TargetLoweringBase::useStackGuardXorFP().
Referenced by getFrameIndexTy().
| void SelectionDAGBuilder::visitSwitchCase | ( | SwitchCG::CaseBlock & | CB, |
| MachineBasicBlock * | SwitchBB | ||
| ) |
visitSwitchCase - Emits the necessary code to represent a single node in the binary search tree resulting from lowering a switch instruction.
Definition at line 2341 of file SelectionDAGBuilder.cpp.
Referenced by getFrameIndexTy().
| AliasAnalysis* llvm::SelectionDAGBuilder::AA = nullptr |
Definition at line 394 of file SelectionDAGBuilder.h.
Referenced by getMemCmpLoad().
Definition at line 420 of file SelectionDAGBuilder.h.
| LLVMContext* llvm::SelectionDAGBuilder::Context |
Definition at line 438 of file SelectionDAGBuilder.h.
| SelectionDAG& llvm::SelectionDAGBuilder::DAG |
Definition at line 392 of file SelectionDAGBuilder.h.
Referenced by addStackMapLiveVars(), llvm::StatepointLoweringState::allocateStackSlot(), getMemCmpLoad(), getUniformBase(), lowerIncomingStatepointValue(), lowerStatepointMetaArgs(), pushStackMapConstant(), reservePreviousStackSlotForValue(), and spillIncomingStatepointValue().
| const DataLayout* llvm::SelectionDAGBuilder::DL = nullptr |
Definition at line 393 of file SelectionDAGBuilder.h.
Referenced by getMemCmpLoad().
| FunctionLoweringInfo& llvm::SelectionDAGBuilder::FuncInfo |
Information about the function as a whole.
Definition at line 423 of file SelectionDAGBuilder.h.
Referenced by llvm::StatepointLoweringState::allocateStackSlot(), llvm::RegsForValue::append(), findPreviousSpillSlot(), lowerStatepointMetaArgs(), reservePreviousStackSlotForValue(), and llvm::StatepointLoweringState::startNewStatepoint().
| GCFunctionInfo* llvm::SelectionDAGBuilder::GFI |
Garbage collection metadata for the function.
Definition at line 429 of file SelectionDAGBuilder.h.
Referenced by lowerStatepointMetaArgs().
This is set to true if a call in the current block has been translated as a tail call.
In this case, no subsequent DAG nodes should be created.
Definition at line 436 of file SelectionDAGBuilder.h.
| const TargetLibraryInfo* llvm::SelectionDAGBuilder::LibInfo |
Definition at line 395 of file SelectionDAGBuilder.h.
Lowest valid SDNodeOrder.
The special case 0 is reserved for scheduling nodes without a corresponding SDNode.
Definition at line 390 of file SelectionDAGBuilder.h.
| DenseMap<MachineBasicBlock *, SmallVector<unsigned, 4> > llvm::SelectionDAGBuilder::LPadToCallSiteMap |
Map a landing pad to the call site indexes.
Definition at line 432 of file SelectionDAGBuilder.h.
| SmallVector<SDValue, 8> llvm::SelectionDAGBuilder::PendingLoads |
Loads are not emitted to the program immediately.
We bunch them up and then emit token factor nodes when possible. This allows us to get simple disambiguation between loads without worrying about alias analysis.
Definition at line 133 of file SelectionDAGBuilder.h.
Referenced by getMemCmpLoad().
| std::unique_ptr<SDAGSwitchLowering> llvm::SelectionDAGBuilder::SL |
Definition at line 412 of file SelectionDAGBuilder.h.
| StackProtectorDescriptor llvm::SelectionDAGBuilder::SPDescriptor |
A StackProtectorDescriptor structure used to communicate stack protector information in between SelectBasicBlock and FinishBasicBlock.
Definition at line 416 of file SelectionDAGBuilder.h.
| StatepointLoweringState llvm::SelectionDAGBuilder::StatepointLowering |
State used while lowering a statepoint sequence (gc_statepoint, gc_relocate, and gc_result).
See StatepointLowering.hpp/cpp for details.
Definition at line 137 of file SelectionDAGBuilder.h.
Referenced by lowerStatepointMetaArgs(), reservePreviousStackSlotForValue(), and spillIncomingStatepointValue().
| SwiftErrorValueTracking& llvm::SelectionDAGBuilder::SwiftError |
Information about the swifterror values used throughout the function.
Definition at line 426 of file SelectionDAGBuilder.h.
1.8.13