LLVM: include/llvm/CodeGen/SelectionDAGISel.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9
10
11
12
13
14#ifndef LLVM_CODEGEN_SELECTIONDAGISEL_H
15#define LLVM_CODEGEN_SELECTIONDAGISEL_H
16
22#include
23
24namespace llvm {
42
43
44
46public:
51 std::unique_ptr SwiftError;
57 mutable std::optional BatchAA;
67
68
69
71
72
73
74
75
76
79
83
84
90
92
95
97
99
100
101
103
104
105
107
108
110
111
112
113
114
115
116 virtual bool
119 std::vector &OutOps) {
120 return true;
121 }
122
123
124
126
127
128
129
130
133 bool IgnoreChains = false);
134
137
139
140
202
215
224
233
257
259
265
296
300
308
312
326
328 };
329
330 enum {
336 OPFL_Variadic0 = 1 << 4,
337 OPFL_Variadic1 = 2 << 4,
338 OPFL_Variadic2 = 3 << 4,
339 OPFL_Variadic3 = 4 << 4,
340 OPFL_Variadic4 = 5 << 4,
341 OPFL_Variadic5 = 6 << 4,
342 OPFL_Variadic6 = 7 << 4,
343 OPFL_Variadic7 = 8 << 4,
344
346 };
347
348
349
350
354
355
356protected:
357
358
360
361
362
364 CurDAG->ReplaceAllUsesOfValueWith(F, T);
366 }
367
368
369
371 CurDAG->ReplaceAllUsesOfValuesWith(F, T, Num);
372 for (unsigned i = 0; i < Num; ++i)
374 }
375
376
377
379 CurDAG->ReplaceAllUsesWith(F, T);
381 }
382
383
389
390
391
394
395
397 llvm_unreachable("Tblgen should generate the implementation of this!");
398 }
399
400
402 llvm_unreachable("Tblgen should generate the implementation of this!");
403 }
404
406 return CurDAG->shouldOptForSize();
407 }
408
409public:
410
412 int64_t DesiredMaskS) const;
414 int64_t DesiredMaskS) const;
415
416
417
418
419
420
422 llvm_unreachable("Tblgen should generate the implementation of this!");
423 }
424
425
426
427
428
430 llvm_unreachable("Tblgen should generate the implementation of this!");
431 }
432
433
434
435
436
437
438 virtual bool
441 llvm_unreachable("Tblgen should generate the implementation of this!");
442 }
443
445 unsigned PatternNo,
447 llvm_unreachable("Tblgen should generate the implementation of this!");
448 }
449
453
455 unsigned TableSize);
456
457
458
462
463
465
467
468private:
469
470
471 void Select_INLINEASM(SDNode *N);
472 void Select_READ_REGISTER(SDNode *Op);
473 void Select_WRITE_REGISTER(SDNode *Op);
474 void Select_UNDEF(SDNode *N);
475 void Select_FAKE_USE(SDNode *N);
476 void Select_RELOC_NONE(SDNode *N);
477 void CannotYetSelect(SDNode *N);
478
479 void Select_FREEZE(SDNode *N);
480 void Select_ARITH_FENCE(SDNode *N);
481 void Select_MEMBARRIER(SDNode *N);
482
483 void Select_CONVERGENCECTRL_ANCHOR(SDNode *N);
484 void Select_CONVERGENCECTRL_ENTRY(SDNode *N);
485 void Select_CONVERGENCECTRL_LOOP(SDNode *N);
486
489 void Select_STACKMAP(SDNode *N);
490 void Select_PATCHPOINT(SDNode *N);
491
492 void Select_JUMP_TABLE_DEBUG_INFO(SDNode *N);
493
494private:
495 void DoInstructionSelection();
498
499
500
501
502 bool PrepareEHLandingPad();
503
504
506
507
508 void SelectAllBasicBlocks(const Function &Fn);
509
510
511
512
515 bool &HadTailCall);
516 void FinishBasicBlock();
517
518 void CodeGenAndEmitDAG();
519
520
521
522 void LowerArguments(const Function &F);
523
524 void ComputeLiveOutVRegInfo();
525
526
527
528
529
531
532
533
534 std::vector OpcodeOffset;
535
536 void UpdateChains(SDNode *NodeToMatch, SDValue InputChain,
538 bool isMorphNodeTo);
539};
540
542 std::unique_ptr Selector;
543
544public:
546
548
550
552};
553
555 std::unique_ptr Selector;
556
557protected:
559 : Selector(std::move(Selector)) {}
560
561public:
565};
566}
567
568#endif
static msgpack::DocNode getNode(msgpack::DocNode DN, msgpack::Type Type, MCValue Val)
MachineBasicBlock MachineBasicBlock::iterator DebugLoc DL
const AbstractManglingParser< Derived, Alloc >::OperatorInfo AbstractManglingParser< Derived, Alloc >::Ops[]
Represent the analysis usage information of a pass.
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
A cache of @llvm.assume calls within a function.
InstListType::const_iterator const_iterator
This class is a wrapper over an AAResults, and it is intended to be used only when there are no IR ch...
FunctionLoweringInfo - This contains information that is global to a function that is used when lower...
Garbage collection metadata for a single function.
MachineFunctionPass - This class adapts the FunctionPass interface to allow convenient creation of pa...
MachineFunctionPass(char &ID)
This class contains meta information specific to a module.
MachineRegisterInfo - Keep track of information for virtual and physical registers,...
A set of analyses that are preserved following a run of a transformation pass.
Wrapper class for IR location info (IR ordering and DebugLoc) to be passed into SDNode creation funct...
Represents one node in the SelectionDAG.
Unlike LLVM values, Selection DAG nodes may return multiple values as the result of a computation.
ScheduleDAGSDNodes - A ScheduleDAG for scheduling SDNode-based DAGs.
SelectionDAGBuilder - This is the common target-independent lowering implementation that is parameter...
~SelectionDAGISelLegacy() override=default
bool runOnMachineFunction(MachineFunction &MF) override
runOnMachineFunction - This method must be overloaded to perform the desired machine code transformat...
void getAnalysisUsage(AnalysisUsage &AU) const override
getAnalysisUsage - Subclasses that override getAnalysisUsage must call this.
SelectionDAGISelLegacy(char &ID, std::unique_ptr< SelectionDAGISel > S)
SelectionDAGISelPass(std::unique_ptr< SelectionDAGISel > Selector)
Definition SelectionDAGISel.h:558
static bool isRequired()
Definition SelectionDAGISel.h:564
PreservedAnalyses run(MachineFunction &MF, MachineFunctionAnalysisManager &MFAM)
std::optional< BatchAAResults > BatchAA
Definition SelectionDAGISel.h:57
std::unique_ptr< FunctionLoweringInfo > FuncInfo
Definition SelectionDAGISel.h:50
SmallPtrSet< const Instruction *, 4 > ElidedArgCopyInstrs
Definition SelectionDAGISel.h:66
virtual bool SelectInlineAsmMemoryOperand(const SDValue &Op, InlineAsm::ConstraintCode ConstraintID, std::vector< SDValue > &OutOps)
SelectInlineAsmMemoryOperand - Select the specified address as a target addressing mode,...
Definition SelectionDAGISel.h:117
bool CheckOrMask(SDValue LHS, ConstantSDNode *RHS, int64_t DesiredMaskS) const
CheckOrMask - The isel is trying to match something like (or X, 255).
TargetMachine & TM
Definition SelectionDAGISel.h:47
AssumptionCache * AC
Definition SelectionDAGISel.h:58
void initializeAnalysisResults(MachineFunctionAnalysisManager &MFAM)
const TargetTransformInfo * TTI
Definition SelectionDAGISel.h:61
virtual bool CheckNodePredicate(SDValue Op, unsigned PredNo) const
CheckNodePredicate - This function is generated by tblgen in the target.
Definition SelectionDAGISel.h:429
MachineModuleInfo * MMI
Definition SelectionDAGISel.h:53
SSPLayoutInfo * SP
Definition SelectionDAGISel.h:60
virtual bool CheckNodePredicateWithOperands(SDValue Op, unsigned PredNo, ArrayRef< SDValue > Operands) const
CheckNodePredicateWithOperands - This function is generated by tblgen in the target.
Definition SelectionDAGISel.h:439
const TargetLowering * TLI
Definition SelectionDAGISel.h:64
virtual void PostprocessISelDAG()
PostprocessISelDAG() - This hook allows the target to hack on the graph right after selection.
Definition SelectionDAGISel.h:106
MachineFunction * MF
Definition SelectionDAGISel.h:52
std::unique_ptr< OptimizationRemarkEmitter > ORE
Current optimization remark emitter.
Definition SelectionDAGISel.h:70
SelectionDAG * CurDAG
Definition SelectionDAGISel.h:55
MachineRegisterInfo * RegInfo
Definition SelectionDAGISel.h:54
unsigned DAGSize
DAGSize - Size of DAG being instruction selected.
Definition SelectionDAGISel.h:359
BuiltinOpcodes
Definition SelectionDAGISel.h:141
@ OPC_MorphNodeTo2GlueOutput
Definition SelectionDAGISel.h:324
@ OPC_Scope
Definition SelectionDAGISel.h:142
@ OPC_RecordChild1
Definition SelectionDAGISel.h:145
@ OPC_CheckChild3Type
Definition SelectionDAGISel.h:210
@ OPC_CheckOrImm
Definition SelectionDAGISel.h:253
@ OPC_CheckComplexPat5
Definition SelectionDAGISel.h:249
@ OPC_CheckPatternPredicate5
Definition SelectionDAGISel.h:185
@ OPC_EmitCopyToRegTwoByte
Definition SelectionDAGISel.h:293
@ OPC_EmitInteger64
Definition SelectionDAGISel.h:263
@ OPC_CheckChild2Same
Definition SelectionDAGISel.h:177
@ OPC_CheckChild7TypeI64
Definition SelectionDAGISel.h:232
@ OPC_CheckTypeRes
Definition SelectionDAGISel.h:205
@ OPC_MoveChild
Definition SelectionDAGISel.h:155
@ OPC_SwitchType
Definition SelectionDAGISel.h:206
@ OPC_MorphNodeTo2GlueInput
Definition SelectionDAGISel.h:321
@ OPC_RecordChild7
Definition SelectionDAGISel.h:151
@ OPC_CheckChild6Type
Definition SelectionDAGISel.h:213
@ OPC_MoveChild4
Definition SelectionDAGISel.h:160
@ OPC_CheckChild2CondCode
Definition SelectionDAGISel.h:241
@ OPC_CheckComplexPat2
Definition SelectionDAGISel.h:246
@ OPC_EmitNode
Definition SelectionDAGISel.h:295
@ OPC_MoveParent
Definition SelectionDAGISel.h:173
@ OPC_MoveChild0
Definition SelectionDAGISel.h:156
@ OPC_MoveSibling5
Definition SelectionDAGISel.h:170
@ OPC_CheckChild7Type
Definition SelectionDAGISel.h:214
@ OPC_CheckPredicate7
Definition SelectionDAGISel.h:197
@ OPC_CaptureGlueInput
Definition SelectionDAGISel.h:153
@ OPC_CheckPatternPredicateTwoByte
Definition SelectionDAGISel.h:188
@ OPC_CheckValueType
Definition SelectionDAGISel.h:242
@ OPC_MorphNodeTo2
Definition SelectionDAGISel.h:311
@ OPC_CheckPatternPredicate1
Definition SelectionDAGISel.h:181
@ OPC_SwitchOpcode
Definition SelectionDAGISel.h:200
@ OPC_MorphNodeTo1GlueOutput
Definition SelectionDAGISel.h:323
@ OPC_CheckChild1TypeI64
Definition SelectionDAGISel.h:226
@ OPC_EmitCopyToReg5
Definition SelectionDAGISel.h:290
@ OPC_RecordChild3
Definition SelectionDAGISel.h:147
@ OPC_CaptureDeactivationSymbol
Definition SelectionDAGISel.h:154
@ OPC_CheckComplexPat6
Definition SelectionDAGISel.h:250
@ OPC_EmitNode0
Definition SelectionDAGISel.h:297
@ OPC_EmitMergeInputChains1_1
Definition SelectionDAGISel.h:282
@ OPC_CheckPatternPredicate2
Definition SelectionDAGISel.h:182
@ OPC_EmitCopyToReg
Definition SelectionDAGISel.h:284
@ OPC_CheckChild6TypeI64
Definition SelectionDAGISel.h:231
@ OPC_CheckChild5Type
Definition SelectionDAGISel.h:212
@ OPC_EmitConvertToTarget2
Definition SelectionDAGISel.h:274
@ OPC_CompleteMatch
Definition SelectionDAGISel.h:325
@ OPC_EmitConvertToTarget0
Definition SelectionDAGISel.h:272
@ OPC_EmitNode1None
Definition SelectionDAGISel.h:302
@ OPC_CheckPatternPredicate4
Definition SelectionDAGISel.h:184
@ OPC_CheckPredicate0
Definition SelectionDAGISel.h:190
@ OPC_CheckImmAllOnesV
Definition SelectionDAGISel.h:254
@ OPC_EmitCopyToReg0
Definition SelectionDAGISel.h:285
@ OPC_EmitConvertToTarget1
Definition SelectionDAGISel.h:273
@ OPC_EmitCopyToReg3
Definition SelectionDAGISel.h:288
@ OPC_CheckPatternPredicate
Definition SelectionDAGISel.h:179
@ OPC_MorphNodeTo0GlueInput
Definition SelectionDAGISel.h:319
@ OPC_MorphNodeTo0
Definition SelectionDAGISel.h:309
@ OPC_CheckPatternPredicate6
Definition SelectionDAGISel.h:186
@ OPC_MoveSibling2
Definition SelectionDAGISel.h:167
@ OPC_MorphNodeTo0GlueOutput
Definition SelectionDAGISel.h:322
@ OPC_CheckPatternPredicate7
Definition SelectionDAGISel.h:187
@ OPC_EmitInteger
Definition SelectionDAGISel.h:258
@ OPC_MorphNodeTo0Chain
Definition SelectionDAGISel.h:316
@ OPC_MorphNodeTo2None
Definition SelectionDAGISel.h:315
@ OPC_CheckChild5TypeI32
Definition SelectionDAGISel.h:221
@ OPC_MoveSibling6
Definition SelectionDAGISel.h:171
@ OPC_CheckPredicate4
Definition SelectionDAGISel.h:194
@ OPC_MoveSibling
Definition SelectionDAGISel.h:164
@ OPC_MorphNodeTo0None
Definition SelectionDAGISel.h:313
@ OPC_EmitMergeInputChains
Definition SelectionDAGISel.h:280
@ OPC_CheckChild1Type
Definition SelectionDAGISel.h:208
@ OPC_CheckChild3TypeI32
Definition SelectionDAGISel.h:219
@ OPC_EmitRegister
Definition SelectionDAGISel.h:267
@ OPC_EmitInteger16
Definition SelectionDAGISel.h:261
@ OPC_CheckPredicate6
Definition SelectionDAGISel.h:196
@ OPC_EmitMergeInputChains1_0
Definition SelectionDAGISel.h:281
@ OPC_RecordMemRef
Definition SelectionDAGISel.h:152
@ OPC_CheckChild2TypeI32
Definition SelectionDAGISel.h:218
@ OPC_CheckChild6TypeI32
Definition SelectionDAGISel.h:222
@ OPC_EmitNode2Chain
Definition SelectionDAGISel.h:306
@ OPC_CheckChild0TypeI64
Definition SelectionDAGISel.h:225
@ OPC_CheckChild3TypeI64
Definition SelectionDAGISel.h:228
@ OPC_CheckFoldableChainNode
Definition SelectionDAGISel.h:256
@ OPC_RecordChild6
Definition SelectionDAGISel.h:150
@ OPC_RecordChild5
Definition SelectionDAGISel.h:149
@ OPC_CheckAndImm
Definition SelectionDAGISel.h:252
@ OPC_CheckInteger
Definition SelectionDAGISel.h:234
@ OPC_CheckComplexPat0
Definition SelectionDAGISel.h:244
@ OPC_CheckPredicate3
Definition SelectionDAGISel.h:193
@ OPC_EmitRegisterI32
Definition SelectionDAGISel.h:268
@ OPC_EmitConvertToTarget3
Definition SelectionDAGISel.h:275
@ OPC_CheckChild2Type
Definition SelectionDAGISel.h:209
@ OPC_CheckComplexPat4
Definition SelectionDAGISel.h:248
@ OPC_CheckTypeI32
Definition SelectionDAGISel.h:203
@ OPC_EmitCopyToReg4
Definition SelectionDAGISel.h:289
@ OPC_MorphNodeTo
Definition SelectionDAGISel.h:307
@ OPC_RecordChild4
Definition SelectionDAGISel.h:148
@ OPC_MoveSibling1
Definition SelectionDAGISel.h:166
@ OPC_MoveChild7
Definition SelectionDAGISel.h:163
@ OPC_CheckPredicateWithOperands
Definition SelectionDAGISel.h:198
@ OPC_CheckChild0Type
Definition SelectionDAGISel.h:207
@ OPC_CheckChild4Type
Definition SelectionDAGISel.h:211
@ OPC_CheckCondCode
Definition SelectionDAGISel.h:240
@ OPC_CheckChild1Same
Definition SelectionDAGISel.h:176
@ OPC_EmitNode2
Definition SelectionDAGISel.h:299
@ OPC_EmitConvertToTarget4
Definition SelectionDAGISel.h:276
@ OPC_CheckChild7TypeI32
Definition SelectionDAGISel.h:223
@ OPC_MoveChild2
Definition SelectionDAGISel.h:158
@ OPC_CheckPredicate
Definition SelectionDAGISel.h:189
@ OPC_MoveChild6
Definition SelectionDAGISel.h:162
@ OPC_EmitCopyToReg2
Definition SelectionDAGISel.h:287
@ OPC_EmitStringInteger
Definition SelectionDAGISel.h:264
@ OPC_MoveSibling3
Definition SelectionDAGISel.h:168
@ OPC_MoveSibling0
Definition SelectionDAGISel.h:165
@ OPC_EmitNode2None
Definition SelectionDAGISel.h:303
@ OPC_EmitRegisterI64
Definition SelectionDAGISel.h:269
@ OPC_CheckImmAllZerosV
Definition SelectionDAGISel.h:255
@ OPC_CheckChild5TypeI64
Definition SelectionDAGISel.h:230
@ OPC_CheckComplexPat3
Definition SelectionDAGISel.h:247
@ OPC_EmitNode0None
Definition SelectionDAGISel.h:301
@ OPC_EmitCopyToReg1
Definition SelectionDAGISel.h:286
@ OPC_CheckChild3Same
Definition SelectionDAGISel.h:178
@ OPC_CheckPredicate2
Definition SelectionDAGISel.h:192
@ OPC_RecordNode
Definition SelectionDAGISel.h:143
@ OPC_MoveChild3
Definition SelectionDAGISel.h:159
@ OPC_EmitStringInteger32
Definition SelectionDAGISel.h:266
@ OPC_CheckChild4TypeI32
Definition SelectionDAGISel.h:220
@ OPC_MoveSibling4
Definition SelectionDAGISel.h:169
@ OPC_CheckChild2TypeI64
Definition SelectionDAGISel.h:227
@ OPC_CheckPredicate1
Definition SelectionDAGISel.h:191
@ OPC_EmitRegister2
Definition SelectionDAGISel.h:270
@ OPC_CheckChild4TypeI64
Definition SelectionDAGISel.h:229
@ OPC_CheckChild0Integer
Definition SelectionDAGISel.h:235
@ OPC_MoveChild1
Definition SelectionDAGISel.h:157
@ OPC_CheckChild2Integer
Definition SelectionDAGISel.h:237
@ OPC_CheckSame
Definition SelectionDAGISel.h:174
@ OPC_RecordChild0
Definition SelectionDAGISel.h:144
@ OPC_CheckPredicate5
Definition SelectionDAGISel.h:195
@ OPC_CheckChild0Same
Definition SelectionDAGISel.h:175
@ OPC_EmitInteger8
Definition SelectionDAGISel.h:260
@ OPC_CheckComplexPat1
Definition SelectionDAGISel.h:245
@ OPC_MorphNodeTo1Chain
Definition SelectionDAGISel.h:317
@ OPC_EmitConvertToTarget7
Definition SelectionDAGISel.h:279
@ OPC_EmitMergeInputChains1_2
Definition SelectionDAGISel.h:283
@ OPC_EmitConvertToTarget5
Definition SelectionDAGISel.h:277
@ OPC_EmitCopyToReg7
Definition SelectionDAGISel.h:292
@ OPC_CheckComplexPat7
Definition SelectionDAGISel.h:251
@ OPC_EmitNode0Chain
Definition SelectionDAGISel.h:304
@ OPC_CheckTypeI64
Definition SelectionDAGISel.h:204
@ OPC_CheckPatternPredicate0
Definition SelectionDAGISel.h:180
@ OPC_CheckChild1TypeI32
Definition SelectionDAGISel.h:217
@ OPC_MoveSibling7
Definition SelectionDAGISel.h:172
@ OPC_EmitNodeXForm
Definition SelectionDAGISel.h:294
@ OPC_MorphNodeTo2Chain
Definition SelectionDAGISel.h:318
@ OPC_EmitNode1
Definition SelectionDAGISel.h:298
@ OPC_MorphNodeTo1None
Definition SelectionDAGISel.h:314
@ OPC_CheckOpcode
Definition SelectionDAGISel.h:199
@ OPC_MoveChild5
Definition SelectionDAGISel.h:161
@ OPC_Coverage
Definition SelectionDAGISel.h:327
@ OPC_CheckChild0TypeI32
Definition SelectionDAGISel.h:216
@ OPC_CheckType
Definition SelectionDAGISel.h:201
@ OPC_CheckChild3Integer
Definition SelectionDAGISel.h:238
@ OPC_MorphNodeTo1GlueInput
Definition SelectionDAGISel.h:320
@ OPC_MorphNodeTo1
Definition SelectionDAGISel.h:310
@ OPC_EmitInteger32
Definition SelectionDAGISel.h:262
@ OPC_CheckChild1Integer
Definition SelectionDAGISel.h:236
@ OPC_EmitCopyToReg6
Definition SelectionDAGISel.h:291
@ OPC_CheckPatternPredicate3
Definition SelectionDAGISel.h:183
@ OPC_CheckComplexPat
Definition SelectionDAGISel.h:243
@ OPC_CheckChild4Integer
Definition SelectionDAGISel.h:239
@ OPC_EmitConvertToTarget
Definition SelectionDAGISel.h:271
@ OPC_EmitNode1Chain
Definition SelectionDAGISel.h:305
@ OPC_EmitConvertToTarget6
Definition SelectionDAGISel.h:278
@ OPC_RecordChild2
Definition SelectionDAGISel.h:146
bool isOrEquivalentToAdd(const SDNode *N) const
virtual bool CheckComplexPattern(SDNode *Root, SDNode *Parent, SDValue N, unsigned PatternNo, SmallVectorImpl< std::pair< SDValue, SDNode * > > &Result)
Definition SelectionDAGISel.h:444
virtual bool CheckPatternPredicate(unsigned PredNo) const
CheckPatternPredicate - This function is generated by tblgen in the target.
Definition SelectionDAGISel.h:421
static int getNumFixedFromVariadicInfo(unsigned Flags)
getNumFixedFromVariadicInfo - Transform an EmitNode flags word into the number of fixed arity values ...
Definition SelectionDAGISel.h:351
const TargetLibraryInfo * LibInfo
Definition SelectionDAGISel.h:48
static int getUninvalidatedNodeId(SDNode *N)
const TargetInstrInfo * TII
Definition SelectionDAGISel.h:63
CodeGenOptLevel OptLevel
Definition SelectionDAGISel.h:62
std::unique_ptr< SwiftErrorValueTracking > SwiftError
Definition SelectionDAGISel.h:51
GCFunctionInfo * GFI
Definition SelectionDAGISel.h:59
void SelectCodeCommon(SDNode *NodeToMatch, const unsigned char *MatcherTable, unsigned TableSize)
virtual void Select(SDNode *N)=0
Main hook for targets to transform nodes into machine nodes.
void ReplaceUses(const SDValue *F, const SDValue *T, unsigned Num)
ReplaceUses - replace all uses of the old nodes F with the use of the new nodes T.
Definition SelectionDAGISel.h:370
static void EnforceNodeIdInvariant(SDNode *N)
virtual void emitFunctionEntryCode()
Definition SelectionDAGISel.h:98
const RTLIB::RuntimeLibcallsInfo * RuntimeLibCallInfo
Definition SelectionDAGISel.h:49
void ReplaceUses(SDValue F, SDValue T)
ReplaceUses - replace all uses of the old node F with the use of the new node T.
Definition SelectionDAGISel.h:363
virtual bool IsProfitableToFold(SDValue N, SDNode *U, SDNode *Root) const
IsProfitableToFold - Returns true if it's profitable to fold the specific operand node N of U during ...
virtual SDValue RunSDNodeXForm(SDValue V, unsigned XFormNo)
Definition SelectionDAGISel.h:450
bool MatchFilterFuncName
True if the function currently processing is in the function printing list (i.e.
Definition SelectionDAGISel.h:77
void SelectInlineAsmMemoryOperands(std::vector< SDValue > &Ops, const SDLoc &DL)
SelectInlineAsmMemoryOperands - Calls to this are automatically generated by tblgen.
static bool IsLegalToFold(SDValue N, SDNode *U, SDNode *Root, CodeGenOptLevel OptLevel, bool IgnoreChains=false)
IsLegalToFold - Returns true if the specific operand node N of U can be folded during instruction sel...
virtual bool ComplexPatternFuncMutatesDAG() const
Return true if complex patterns for this target can mutate the DAG.
Definition SelectionDAGISel.h:459
void ReplaceUses(SDNode *F, SDNode *T)
ReplaceUses - replace all uses of the old node F with the use of the new node T.
Definition SelectionDAGISel.h:378
virtual void PreprocessISelDAG()
PreprocessISelDAG - This hook allows targets to hack on the graph before instruction selection starts...
Definition SelectionDAGISel.h:102
BatchAAResults * getBatchAA() const
Returns a (possibly null) pointer to the current BatchAAResults.
Definition SelectionDAGISel.h:85
bool CheckAndMask(SDValue LHS, ConstantSDNode *RHS, int64_t DesiredMaskS) const
CheckAndMask - The isel is trying to match something like (and X, 255).
virtual ~SelectionDAGISel()
StringRef FuncName
Definition SelectionDAGISel.h:78
virtual StringRef getPatternForIndex(unsigned index)
getPatternForIndex - Patterns selected by tablegen during ISEL
Definition SelectionDAGISel.h:396
bool mayRaiseFPException(SDNode *Node) const
Return whether the node may raise an FP exception.
std::unique_ptr< SelectionDAGBuilder > SDB
Definition SelectionDAGISel.h:56
@ OPFL_Variadic3
Definition SelectionDAGISel.h:339
@ OPFL_None
Definition SelectionDAGISel.h:331
@ OPFL_GlueInput
Definition SelectionDAGISel.h:333
@ OPFL_Variadic4
Definition SelectionDAGISel.h:340
@ OPFL_VariadicInfo
Definition SelectionDAGISel.h:345
@ OPFL_Variadic5
Definition SelectionDAGISel.h:341
@ OPFL_Chain
Definition SelectionDAGISel.h:332
@ OPFL_Variadic7
Definition SelectionDAGISel.h:343
@ OPFL_MemRefs
Definition SelectionDAGISel.h:335
@ OPFL_GlueOutput
Definition SelectionDAGISel.h:334
@ OPFL_Variadic0
Definition SelectionDAGISel.h:336
@ OPFL_Variadic6
Definition SelectionDAGISel.h:342
@ OPFL_Variadic2
Definition SelectionDAGISel.h:338
@ OPFL_Variadic1
Definition SelectionDAGISel.h:337
void ReplaceNode(SDNode *F, SDNode *T)
Replace all uses of F with T, then remove F from the DAG.
Definition SelectionDAGISel.h:384
SelectionDAGISel(TargetMachine &tm, CodeGenOptLevel OL=CodeGenOptLevel::Default)
virtual bool runOnMachineFunction(MachineFunction &mf)
static void InvalidateNodeId(SDNode *N)
const TargetLowering * getTargetLowering() const
Definition SelectionDAGISel.h:91
bool shouldOptForSize(const MachineFunction *MF) const
Definition SelectionDAGISel.h:405
virtual StringRef getIncludePathForIndex(unsigned index)
getIncludePathForIndex - get the td source location of pattern instantiation
Definition SelectionDAGISel.h:401
bool FastISelFailed
Definition SelectionDAGISel.h:65
This is used to represent a portion of an LLVM function in a low-level Data Dependence DAG representa...
SmallPtrSet - This class implements a set which is optimized for holding SmallSize or less elements.
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
StringRef - Represent a constant reference to a string, i.e.
TargetInstrInfo - Interface to description of machine instruction set.
Provides information about what library functions are available for the current target.
This class defines information used to lower LLVM code to legal SelectionDAG operators that the targe...
Primary interface to the complete machine description for the target machine.
This pass provides access to the codegen interfaces that are needed for IR-level transformations.
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
unsigned ID
LLVM IR allows to use arbitrary numbers as calling convention identifiers.
This is an optimization pass for GlobalISel generic memory operations.
AnalysisManager< MachineFunction > MachineFunctionAnalysisManager
CodeGenOptLevel
Code generation optimization level.
DWARFExpression::Operation Op
OutputIt move(R &&Range, OutputIt Out)
Provide wrappers to std::move which take ranges instead of having to pass begin/end explicitly.
Implement std::hash so that hash_code can be used in STL containers.
A CRTP mix-in to automatically provide informational APIs needed for passes.
A simple container for information about the supported runtime calls.
This represents a list of ValueType's that has been intern'd by a SelectionDAG.