LLVM  5.0.0
ARMLegalizerInfo.cpp
Go to the documentation of this file.
1 //===- ARMLegalizerInfo.cpp --------------------------------------*- C++ -*-==//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 /// \file
10 /// This file implements the targeting of the Machinelegalizer class for ARM.
11 /// \todo This should be generated by TableGen.
12 //===----------------------------------------------------------------------===//
13 
14 #include "ARMLegalizerInfo.h"
15 #include "ARMCallLowering.h"
16 #include "ARMSubtarget.h"
21 #include "llvm/IR/DerivedTypes.h"
22 #include "llvm/IR/Type.h"
24 
25 using namespace llvm;
26 
27 #ifndef LLVM_BUILD_GLOBAL_ISEL
28 #error "You shouldn't build this"
29 #endif
30 
31 static bool AEABI(const ARMSubtarget &ST) {
32  return ST.isTargetAEABI() || ST.isTargetGNUAEABI() || ST.isTargetMuslAEABI();
33 }
34 
36  using namespace TargetOpcode;
37 
38  const LLT p0 = LLT::pointer(0, 32);
39 
40  const LLT s1 = LLT::scalar(1);
41  const LLT s8 = LLT::scalar(8);
42  const LLT s16 = LLT::scalar(16);
43  const LLT s32 = LLT::scalar(32);
44  const LLT s64 = LLT::scalar(64);
45 
46  setAction({G_FRAME_INDEX, p0}, Legal);
47 
48  for (unsigned Op : {G_LOAD, G_STORE}) {
49  for (auto Ty : {s1, s8, s16, s32, p0})
50  setAction({Op, Ty}, Legal);
51  setAction({Op, 1, p0}, Legal);
52  }
53 
54  for (unsigned Op : {G_ADD, G_SUB, G_MUL, G_AND, G_OR, G_XOR}) {
55  for (auto Ty : {s1, s8, s16})
56  setAction({Op, Ty}, WidenScalar);
57  setAction({Op, s32}, Legal);
58  }
59 
60  for (unsigned Op : {G_SDIV, G_UDIV}) {
61  for (auto Ty : {s8, s16})
62  setAction({Op, Ty}, WidenScalar);
63  if (ST.hasDivideInARMMode())
64  setAction({Op, s32}, Legal);
65  else
66  setAction({Op, s32}, Libcall);
67  }
68 
69  for (unsigned Op : {G_SREM, G_UREM}) {
70  for (auto Ty : {s8, s16})
71  setAction({Op, Ty}, WidenScalar);
72  if (ST.hasDivideInARMMode())
73  setAction({Op, s32}, Lower);
74  else if (AEABI(ST))
75  setAction({Op, s32}, Custom);
76  else
77  setAction({Op, s32}, Libcall);
78  }
79 
80  for (unsigned Op : {G_SEXT, G_ZEXT}) {
81  setAction({Op, s32}, Legal);
82  for (auto Ty : {s1, s8, s16})
83  setAction({Op, 1, Ty}, Legal);
84  }
85 
86  setAction({G_GEP, p0}, Legal);
87  setAction({G_GEP, 1, s32}, Legal);
88 
89  setAction({G_SELECT, s32}, Legal);
90  setAction({G_SELECT, p0}, Legal);
91  setAction({G_SELECT, 1, s1}, Legal);
92 
93  setAction({G_BRCOND, s1}, Legal);
94 
95  setAction({G_CONSTANT, s32}, Legal);
96  for (auto Ty : {s1, s8, s16})
97  setAction({G_CONSTANT, Ty}, WidenScalar);
98 
99  setAction({G_ICMP, s1}, Legal);
100  for (auto Ty : {s8, s16})
101  setAction({G_ICMP, 1, Ty}, WidenScalar);
102  for (auto Ty : {s32, p0})
103  setAction({G_ICMP, 1, Ty}, Legal);
104 
105  if (!ST.useSoftFloat() && ST.hasVFP2()) {
106  setAction({G_FADD, s32}, Legal);
107  setAction({G_FADD, s64}, Legal);
108 
109  setAction({G_LOAD, s64}, Legal);
110  setAction({G_STORE, s64}, Legal);
111 
112  setAction({G_FCMP, s1}, Legal);
113  setAction({G_FCMP, 1, s32}, Legal);
114  setAction({G_FCMP, 1, s64}, Legal);
115  } else {
116  for (auto Ty : {s32, s64})
117  setAction({G_FADD, Ty}, Libcall);
118 
119  setAction({G_FCMP, s1}, Legal);
120  setAction({G_FCMP, 1, s32}, Custom);
121  setAction({G_FCMP, 1, s64}, Custom);
122 
123  if (AEABI(ST))
124  setFCmpLibcallsAEABI();
125  else
126  setFCmpLibcallsGNU();
127  }
128 
129  for (unsigned Op : {G_FREM, G_FPOW})
130  for (auto Ty : {s32, s64})
131  setAction({Op, Ty}, Libcall);
132 
133  computeTables();
134 }
135 
136 void ARMLegalizerInfo::setFCmpLibcallsAEABI() {
137  // FCMP_TRUE and FCMP_FALSE don't need libcalls, they should be
138  // default-initialized.
139  FCmp32Libcalls.resize(CmpInst::LAST_FCMP_PREDICATE + 1);
140  FCmp32Libcalls[CmpInst::FCMP_OEQ] = {
142  FCmp32Libcalls[CmpInst::FCMP_OGE] = {
144  FCmp32Libcalls[CmpInst::FCMP_OGT] = {
146  FCmp32Libcalls[CmpInst::FCMP_OLE] = {
148  FCmp32Libcalls[CmpInst::FCMP_OLT] = {
150  FCmp32Libcalls[CmpInst::FCMP_ORD] = {{RTLIB::O_F32, CmpInst::ICMP_EQ}};
151  FCmp32Libcalls[CmpInst::FCMP_UGE] = {{RTLIB::OLT_F32, CmpInst::ICMP_EQ}};
152  FCmp32Libcalls[CmpInst::FCMP_UGT] = {{RTLIB::OLE_F32, CmpInst::ICMP_EQ}};
153  FCmp32Libcalls[CmpInst::FCMP_ULE] = {{RTLIB::OGT_F32, CmpInst::ICMP_EQ}};
154  FCmp32Libcalls[CmpInst::FCMP_ULT] = {{RTLIB::OGE_F32, CmpInst::ICMP_EQ}};
155  FCmp32Libcalls[CmpInst::FCMP_UNE] = {{RTLIB::UNE_F32, CmpInst::ICMP_EQ}};
156  FCmp32Libcalls[CmpInst::FCMP_UNO] = {
158  FCmp32Libcalls[CmpInst::FCMP_ONE] = {
161  FCmp32Libcalls[CmpInst::FCMP_UEQ] = {
164 
165  FCmp64Libcalls.resize(CmpInst::LAST_FCMP_PREDICATE + 1);
166  FCmp64Libcalls[CmpInst::FCMP_OEQ] = {
168  FCmp64Libcalls[CmpInst::FCMP_OGE] = {
170  FCmp64Libcalls[CmpInst::FCMP_OGT] = {
172  FCmp64Libcalls[CmpInst::FCMP_OLE] = {
174  FCmp64Libcalls[CmpInst::FCMP_OLT] = {
176  FCmp64Libcalls[CmpInst::FCMP_ORD] = {{RTLIB::O_F64, CmpInst::ICMP_EQ}};
177  FCmp64Libcalls[CmpInst::FCMP_UGE] = {{RTLIB::OLT_F64, CmpInst::ICMP_EQ}};
178  FCmp64Libcalls[CmpInst::FCMP_UGT] = {{RTLIB::OLE_F64, CmpInst::ICMP_EQ}};
179  FCmp64Libcalls[CmpInst::FCMP_ULE] = {{RTLIB::OGT_F64, CmpInst::ICMP_EQ}};
180  FCmp64Libcalls[CmpInst::FCMP_ULT] = {{RTLIB::OGE_F64, CmpInst::ICMP_EQ}};
181  FCmp64Libcalls[CmpInst::FCMP_UNE] = {{RTLIB::UNE_F64, CmpInst::ICMP_EQ}};
182  FCmp64Libcalls[CmpInst::FCMP_UNO] = {
184  FCmp64Libcalls[CmpInst::FCMP_ONE] = {
187  FCmp64Libcalls[CmpInst::FCMP_UEQ] = {
190 }
191 
192 void ARMLegalizerInfo::setFCmpLibcallsGNU() {
193  // FCMP_TRUE and FCMP_FALSE don't need libcalls, they should be
194  // default-initialized.
195  FCmp32Libcalls.resize(CmpInst::LAST_FCMP_PREDICATE + 1);
196  FCmp32Libcalls[CmpInst::FCMP_OEQ] = {{RTLIB::OEQ_F32, CmpInst::ICMP_EQ}};
197  FCmp32Libcalls[CmpInst::FCMP_OGE] = {{RTLIB::OGE_F32, CmpInst::ICMP_SGE}};
198  FCmp32Libcalls[CmpInst::FCMP_OGT] = {{RTLIB::OGT_F32, CmpInst::ICMP_SGT}};
199  FCmp32Libcalls[CmpInst::FCMP_OLE] = {{RTLIB::OLE_F32, CmpInst::ICMP_SLE}};
200  FCmp32Libcalls[CmpInst::FCMP_OLT] = {{RTLIB::OLT_F32, CmpInst::ICMP_SLT}};
201  FCmp32Libcalls[CmpInst::FCMP_ORD] = {{RTLIB::O_F32, CmpInst::ICMP_EQ}};
202  FCmp32Libcalls[CmpInst::FCMP_UGE] = {{RTLIB::OLT_F32, CmpInst::ICMP_SGE}};
203  FCmp32Libcalls[CmpInst::FCMP_UGT] = {{RTLIB::OLE_F32, CmpInst::ICMP_SGT}};
204  FCmp32Libcalls[CmpInst::FCMP_ULE] = {{RTLIB::OGT_F32, CmpInst::ICMP_SLE}};
205  FCmp32Libcalls[CmpInst::FCMP_ULT] = {{RTLIB::OGE_F32, CmpInst::ICMP_SLT}};
206  FCmp32Libcalls[CmpInst::FCMP_UNE] = {{RTLIB::UNE_F32, CmpInst::ICMP_NE}};
207  FCmp32Libcalls[CmpInst::FCMP_UNO] = {{RTLIB::UO_F32, CmpInst::ICMP_NE}};
208  FCmp32Libcalls[CmpInst::FCMP_ONE] = {{RTLIB::OGT_F32, CmpInst::ICMP_SGT},
210  FCmp32Libcalls[CmpInst::FCMP_UEQ] = {{RTLIB::OEQ_F32, CmpInst::ICMP_EQ},
212 
213  FCmp64Libcalls.resize(CmpInst::LAST_FCMP_PREDICATE + 1);
214  FCmp64Libcalls[CmpInst::FCMP_OEQ] = {{RTLIB::OEQ_F64, CmpInst::ICMP_EQ}};
215  FCmp64Libcalls[CmpInst::FCMP_OGE] = {{RTLIB::OGE_F64, CmpInst::ICMP_SGE}};
216  FCmp64Libcalls[CmpInst::FCMP_OGT] = {{RTLIB::OGT_F64, CmpInst::ICMP_SGT}};
217  FCmp64Libcalls[CmpInst::FCMP_OLE] = {{RTLIB::OLE_F64, CmpInst::ICMP_SLE}};
218  FCmp64Libcalls[CmpInst::FCMP_OLT] = {{RTLIB::OLT_F64, CmpInst::ICMP_SLT}};
219  FCmp64Libcalls[CmpInst::FCMP_ORD] = {{RTLIB::O_F64, CmpInst::ICMP_EQ}};
220  FCmp64Libcalls[CmpInst::FCMP_UGE] = {{RTLIB::OLT_F64, CmpInst::ICMP_SGE}};
221  FCmp64Libcalls[CmpInst::FCMP_UGT] = {{RTLIB::OLE_F64, CmpInst::ICMP_SGT}};
222  FCmp64Libcalls[CmpInst::FCMP_ULE] = {{RTLIB::OGT_F64, CmpInst::ICMP_SLE}};
223  FCmp64Libcalls[CmpInst::FCMP_ULT] = {{RTLIB::OGE_F64, CmpInst::ICMP_SLT}};
224  FCmp64Libcalls[CmpInst::FCMP_UNE] = {{RTLIB::UNE_F64, CmpInst::ICMP_NE}};
225  FCmp64Libcalls[CmpInst::FCMP_UNO] = {{RTLIB::UO_F64, CmpInst::ICMP_NE}};
226  FCmp64Libcalls[CmpInst::FCMP_ONE] = {{RTLIB::OGT_F64, CmpInst::ICMP_SGT},
228  FCmp64Libcalls[CmpInst::FCMP_UEQ] = {{RTLIB::OEQ_F64, CmpInst::ICMP_EQ},
230 }
231 
233 ARMLegalizerInfo::getFCmpLibcalls(CmpInst::Predicate Predicate,
234  unsigned Size) const {
235  assert(CmpInst::isFPPredicate(Predicate) && "Unsupported FCmp predicate");
236  if (Size == 32)
237  return FCmp32Libcalls[Predicate];
238  if (Size == 64)
239  return FCmp64Libcalls[Predicate];
240  llvm_unreachable("Unsupported size for FCmp predicate");
241 }
242 
245  MachineIRBuilder &MIRBuilder) const {
246  using namespace TargetOpcode;
247 
248  MIRBuilder.setInstr(MI);
249 
250  switch (MI.getOpcode()) {
251  default:
252  return false;
253  case G_SREM:
254  case G_UREM: {
255  unsigned OriginalResult = MI.getOperand(0).getReg();
256  auto Size = MRI.getType(OriginalResult).getSizeInBits();
257  if (Size != 32)
258  return false;
259 
260  auto Libcall =
262 
263  // Our divmod libcalls return a struct containing the quotient and the
264  // remainder. We need to create a virtual register for it.
265  auto &Ctx = MIRBuilder.getMF().getFunction()->getContext();
266  Type *ArgTy = Type::getInt32Ty(Ctx);
267  StructType *RetTy = StructType::get(Ctx, {ArgTy, ArgTy}, /* Packed */ true);
268  auto RetVal = MRI.createGenericVirtualRegister(
269  getLLTForType(*RetTy, MIRBuilder.getMF().getDataLayout()));
270 
271  auto Status = createLibcall(MIRBuilder, Libcall, {RetVal, RetTy},
272  {{MI.getOperand(1).getReg(), ArgTy},
273  {MI.getOperand(2).getReg(), ArgTy}});
274  if (Status != LegalizerHelper::Legalized)
275  return false;
276 
277  // The remainder is the second result of divmod. Split the return value into
278  // a new, unused register for the quotient and the destination of the
279  // original instruction for the remainder.
280  MIRBuilder.buildUnmerge(
281  {MRI.createGenericVirtualRegister(LLT::scalar(32)), OriginalResult},
282  RetVal);
283  break;
284  }
285  case G_FCMP: {
286  assert(MRI.getType(MI.getOperand(2).getReg()) ==
287  MRI.getType(MI.getOperand(3).getReg()) &&
288  "Mismatched operands for G_FCMP");
289  auto OpSize = MRI.getType(MI.getOperand(2).getReg()).getSizeInBits();
290 
291  auto OriginalResult = MI.getOperand(0).getReg();
292  auto Predicate =
293  static_cast<CmpInst::Predicate>(MI.getOperand(1).getPredicate());
294  auto Libcalls = getFCmpLibcalls(Predicate, OpSize);
295 
296  if (Libcalls.empty()) {
297  assert((Predicate == CmpInst::FCMP_TRUE ||
298  Predicate == CmpInst::FCMP_FALSE) &&
299  "Predicate needs libcalls, but none specified");
300  MIRBuilder.buildConstant(OriginalResult,
301  Predicate == CmpInst::FCMP_TRUE ? 1 : 0);
302  MI.eraseFromParent();
303  return true;
304  }
305 
306  auto &Ctx = MIRBuilder.getMF().getFunction()->getContext();
307  assert((OpSize == 32 || OpSize == 64) && "Unsupported operand size");
308  auto *ArgTy = OpSize == 32 ? Type::getFloatTy(Ctx) : Type::getDoubleTy(Ctx);
309  auto *RetTy = Type::getInt32Ty(Ctx);
310 
312  for (auto Libcall : Libcalls) {
313  auto LibcallResult = MRI.createGenericVirtualRegister(LLT::scalar(32));
314  auto Status =
315  createLibcall(MIRBuilder, Libcall.LibcallID, {LibcallResult, RetTy},
316  {{MI.getOperand(2).getReg(), ArgTy},
317  {MI.getOperand(3).getReg(), ArgTy}});
318 
319  if (Status != LegalizerHelper::Legalized)
320  return false;
321 
322  auto ProcessedResult =
323  Libcalls.size() == 1
324  ? OriginalResult
325  : MRI.createGenericVirtualRegister(MRI.getType(OriginalResult));
326 
327  // We have a result, but we need to transform it into a proper 1-bit 0 or
328  // 1, taking into account the different peculiarities of the values
329  // returned by the comparison functions.
330  CmpInst::Predicate ResultPred = Libcall.Predicate;
331  if (ResultPred == CmpInst::BAD_ICMP_PREDICATE) {
332  // We have a nice 0 or 1, and we just need to truncate it back to 1 bit
333  // to keep the types consistent.
334  MIRBuilder.buildTrunc(ProcessedResult, LibcallResult);
335  } else {
336  // We need to compare against 0.
337  assert(CmpInst::isIntPredicate(ResultPred) && "Unsupported predicate");
339  MIRBuilder.buildConstant(Zero, 0);
340  MIRBuilder.buildICmp(ResultPred, ProcessedResult, LibcallResult, Zero);
341  }
342  Results.push_back(ProcessedResult);
343  }
344 
345  if (Results.size() != 1) {
346  assert(Results.size() == 2 && "Unexpected number of results");
347  MIRBuilder.buildOr(OriginalResult, Results[0], Results[1]);
348  }
349  break;
350  }
351  }
352 
353  MI.eraseFromParent();
354  return true;
355 }
void push_back(const T &Elt)
Definition: SmallVector.h:211
static Type * getDoubleTy(LLVMContext &C)
Definition: Type.cpp:165
LLVMContext & getContext() const
getContext - Return a reference to the LLVMContext associated with this function. ...
Definition: Function.cpp:194
LLT getType(unsigned VReg) const
Get the low-level type of VReg or LLT{} if VReg is not a generic (target independent) virtual registe...
static bool AEABI(const ARMSubtarget &ST)
0 1 0 0 True if ordered and less than
Definition: InstrTypes.h:866
Function Alias Analysis Results
1 1 1 0 True if unordered or not equal
Definition: InstrTypes.h:876
MachineInstrBuilder buildTrunc(unsigned Res, unsigned Op)
Build and insert Res<def> = G_TRUNC Op.
const Function * getFunction() const
getFunction - Return the LLVM function that this machine code represents
unsigned createGenericVirtualRegister(LLT Ty)
Create and return a new generic virtual register with low-level type Ty.
1 0 0 1 True if unordered or equal
Definition: InstrTypes.h:871
bool isTargetAEABI() const
Definition: ARMSubtarget.h:600
1 0 0 0 True if unordered: isnan(X) | isnan(Y)
Definition: InstrTypes.h:870
bool useSoftFloat() const
Definition: ARMSubtarget.h:648
static Type * getFloatTy(LLVMContext &C)
Definition: Type.cpp:164
Class to represent struct types.
Definition: DerivedTypes.h:201
void eraseFromParent()
Unlink 'this' from the containing basic block and delete it.
0 1 0 1 True if ordered and less than or equal
Definition: InstrTypes.h:867
LegalizerHelper::LegalizeResult createLibcall(MachineIRBuilder &MIRBuilder, RTLIB::Libcall Libcall, const CallLowering::ArgInfo &Result, ArrayRef< CallLowering::ArgInfo > Args)
Helper function that creates the given libcall.
void computeTables()
Compute any ancillary tables needed to quickly decide how an operation should be handled.
MachineFunction & getMF()
Getter for the function we currently build.
bool legalizeCustom(MachineInstr &MI, MachineRegisterInfo &MRI, MachineIRBuilder &MIRBuilder) const override
static LLT scalar(unsigned SizeInBits)
Get a low-level scalar or aggregate "bag of bits".
const DataLayout & getDataLayout() const
Return the DataLayout attached to the Module associated to this MF.
unsigned getOpcode() const
Returns the opcode of this MachineInstr.
Definition: MachineInstr.h:279
The target wants to do something special with this combination of operand and type.
Definition: LegalizerInfo.h:92
unsigned const MachineRegisterInfo * MRI
The instances of the Type class are immutable: once they are created, they are never changed...
Definition: Type.h:46
static unsigned getSizeInBits(unsigned Reg, const MachineRegisterInfo &MRI, const TargetRegisterInfo &TRI)
Get the size in bits of Reg.
This file declares the targeting of the Machinelegalizer class for ARM.
const MachineOperand & getOperand(unsigned i) const
Definition: MachineInstr.h:284
Helper class to build MachineInstr.
bool isIntPredicate() const
Definition: InstrTypes.h:952
MachineInstrBuilder buildICmp(CmpInst::Predicate Pred, unsigned Res, unsigned Op0, unsigned Op1)
Build and insert a Res = G_ICMP Pred, Op0, Op1.
void setInstr(MachineInstr &MI)
Set the insertion point to before MI.
Predicate
This enumeration lists the possible predicates for CmpInst subclasses.
Definition: InstrTypes.h:860
void resize(typename StorageT::size_type s)
Definition: IndexedMap.h:60
size_t size() const
Definition: Function.h:585
ARMLegalizerInfo(const ARMSubtarget &ST)
0 1 1 1 True if ordered (no nans)
Definition: InstrTypes.h:869
MachineInstrBuilder buildOr(unsigned Res, unsigned Op0, unsigned Op1)
Build and insert Res<def> = G_OR Op0, Op1.
1 1 1 1 Always true (always folded)
Definition: InstrTypes.h:877
1 1 0 1 True if unordered, less than, or equal
Definition: InstrTypes.h:875
signed greater than
Definition: InstrTypes.h:887
LLT getLLTForType(Type &Ty, const DataLayout &DL)
Construct a low-level type based on an LLVM type.
0 0 1 0 True if ordered and greater than
Definition: InstrTypes.h:864
The operation should be implemented as a call to some kind of runtime support library.
Definition: LegalizerInfo.h:88
static StructType * get(LLVMContext &Context, ArrayRef< Type * > Elements, bool isPacked=false)
This static method is the primary way to create a literal StructType.
Definition: Type.cpp:336
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small...
Definition: SmallVector.h:861
1 1 0 0 True if unordered or less than
Definition: InstrTypes.h:874
The operation should be implemented in terms of a wider scalar base-type.
Definition: LegalizerInfo.h:68
Predicate
Predicate - These are "(BI << 5) | BO" for various predicates.
Definition: PPCPredicates.h:27
signed less than
Definition: InstrTypes.h:889
bool hasVFP2() const
Definition: ARMSubtarget.h:509
unsigned getPredicate() const
signed less or equal
Definition: InstrTypes.h:890
The operation itself must be expressed in terms of simpler actions on this target.
Definition: LegalizerInfo.h:83
The operation is expected to be selectable directly by the target, and no transformation is necessary...
Definition: LegalizerInfo.h:58
bool isTargetGNUAEABI() const
Definition: ARMSubtarget.h:605
bool isFPPredicate() const
Definition: InstrTypes.h:951
constexpr char Size[]
Key for Kernel::Arg::Metadata::mSize.
llvm_unreachable("Unknown RegBank!")
MachineRegisterInfo - Keep track of information for virtual and physical registers, including vreg register classes, use/def chains for registers, etc.
Representation of each machine instruction.
Definition: MachineInstr.h:59
Instruction has been legalized and the MachineFunction changed.
static IntegerType * getInt32Ty(LLVMContext &C)
Definition: Type.cpp:176
MachineInstrBuilder buildConstant(unsigned Res, const ConstantInt &Val)
Build and insert Res = G_CONSTANT Val.
0 1 1 0 True if ordered and operands are unequal
Definition: InstrTypes.h:868
static volatile int Zero
1 0 1 0 True if unordered or greater than
Definition: InstrTypes.h:872
MachineInstrBuilder buildUnmerge(ArrayRef< unsigned > Res, unsigned Op)
Build and insert Res0<def>, ...
unsigned getReg() const
getReg - Returns the register number.
bool isTargetMuslAEABI() const
Definition: ARMSubtarget.h:610
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
0 0 0 1 True if ordered and equal
Definition: InstrTypes.h:863
static LLT pointer(uint16_t AddressSpace, unsigned SizeInBits)
Get a low-level pointer in the given address space (defaulting to 0).
1 0 1 1 True if unordered, greater than, or equal
Definition: InstrTypes.h:873
IRTranslator LLVM IR MI
bool hasDivideInARMMode() const
Definition: ARMSubtarget.h:524
unsigned getSizeInBits() const
Returns the total size of the type. Must only be called on sized types.
This file describes how to lower LLVM calls to machine code calls.
0 0 1 1 True if ordered and greater than or equal
Definition: InstrTypes.h:865
void setAction(const InstrAspect &Aspect, LegalizeAction Action)
More friendly way to set an action for common types that have an LLT representation.
0 0 0 0 Always false (always folded)
Definition: InstrTypes.h:862
signed greater or equal
Definition: InstrTypes.h:888