blob: 4f1ce0cd1c6ad1e7c64af079bfa6402760a57eca [file] [log] [blame]
Akira Hatanakae2489122011-04-15 21:51:11 +00001//===-- MipsISelLowering.h - Mips DAG Lowering Interface --------*- C++ -*-===//
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +00002//
3// The LLVM Compiler Infrastructure
4//
Chris Lattnerf3ebc3f2007-12-29 20:36:04 +00005// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +00007//
Akira Hatanakae2489122011-04-15 21:51:11 +00008//===----------------------------------------------------------------------===//
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +00009//
10// This file defines the interfaces that Mips uses to lower LLVM code into a
11// selection DAG.
12//
Akira Hatanakae2489122011-04-15 21:51:11 +000013//===----------------------------------------------------------------------===//
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +000014
15#ifndef MipsISELLOWERING_H
16#define MipsISELLOWERING_H
17
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +000018#include "Mips.h"
19#include "MipsSubtarget.h"
Akira Hatanaka4a3711d2012-10-26 23:56:38 +000020#include "llvm/CodeGen/CallingConvLower.h"
Craig Topperb25fda92012-03-17 18:46:09 +000021#include "llvm/CodeGen/SelectionDAG.h"
22#include "llvm/Target/TargetLowering.h"
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +000023
24namespace llvm {
25 namespace MipsISD {
26 enum NodeType {
27 // Start the numbering from where ISD NodeType finishes.
Dan Gohmaned1cf1a2008-09-23 18:42:32 +000028 FIRST_NUMBER = ISD::BUILTIN_OP_END,
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +000029
30 // Jump and link (call)
31 JmpLink,
32
Akira Hatanaka91318df2012-10-19 20:59:39 +000033 // Tail call
34 TailCall,
35
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +000036 // Get the Higher 16 bits from a 32-bit immediate
37 // No relation with Mips Hi register
Bruno Cardoso Lopesed874ef2011-03-04 17:51:39 +000038 Hi,
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +000039
40 // Get the Lower 16 bits from a 32-bit immediate
41 // No relation with Mips Lo register
Bruno Cardoso Lopesed874ef2011-03-04 17:51:39 +000042 Lo,
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +000043
Bruno Cardoso Lopese5d1fcf2008-07-21 18:52:34 +000044 // Handle gp_rel (small data/bss sections) relocation.
45 GPRel,
46
Bruno Cardoso Lopesbf3c1252011-05-31 02:53:58 +000047 // Thread Pointer
48 ThreadPointer,
49
Bruno Cardoso Lopes7ceec572008-07-09 04:45:36 +000050 // Floating Point Branch Conditional
Bruno Cardoso Lopesc9c3f492008-07-05 19:05:21 +000051 FPBrcond,
52
Bruno Cardoso Lopes7ceec572008-07-09 04:45:36 +000053 // Floating Point Compare
Bruno Cardoso Lopesc9c3f492008-07-05 19:05:21 +000054 FPCmp,
55
Akira Hatanakaa5352702011-03-31 18:26:17 +000056 // Floating Point Conditional Moves
57 CMovFP_T,
58 CMovFP_F,
59
Bruno Cardoso Lopesa72a5052009-05-27 17:23:44 +000060 // Floating Point Rounding
61 FPRound,
62
Bruno Cardoso Lopesed874ef2011-03-04 17:51:39 +000063 // Return
Bruno Cardoso Lopes4dc73fa2011-01-18 19:29:17 +000064 Ret,
65
66 // MAdd/Sub nodes
67 MAdd,
68 MAddu,
69 MSub,
Bruno Cardoso Lopes434248a62011-03-04 21:03:24 +000070 MSubu,
71
72 // DivRem(u)
73 DivRem,
Akira Hatanaka27916972011-04-15 19:52:08 +000074 DivRemU,
75
76 BuildPairF64,
Akira Hatanakab4068432011-05-28 01:07:07 +000077 ExtractElementF64,
78
Akira Hatanaka5ee84642011-12-09 01:53:17 +000079 Wrapper,
Akira Hatanaka4c406e72011-06-21 00:40:49 +000080
Akira Hatanakaa4c09bc2011-07-19 23:30:50 +000081 DynAlloc,
82
Akira Hatanaka5360f882011-08-17 02:05:42 +000083 Sync,
84
85 Ext,
Akira Hatanakab9ebf8d2012-06-02 00:03:12 +000086 Ins,
87
Akira Hatanaka233ac532012-09-21 23:52:47 +000088 // EXTR.W instrinsic nodes.
89 EXTP,
90 EXTPDP,
91 EXTR_S_H,
92 EXTR_W,
93 EXTR_R_W,
94 EXTR_RS_W,
95 SHILO,
96 MTHLIP,
97
98 // DPA.W intrinsic nodes.
99 MULSAQ_S_W_PH,
100 MAQ_S_W_PHL,
101 MAQ_S_W_PHR,
102 MAQ_SA_W_PHL,
103 MAQ_SA_W_PHR,
104 DPAU_H_QBL,
105 DPAU_H_QBR,
106 DPSU_H_QBL,
107 DPSU_H_QBR,
108 DPAQ_S_W_PH,
109 DPSQ_S_W_PH,
110 DPAQ_SA_L_W,
111 DPSQ_SA_L_W,
112 DPA_W_PH,
113 DPS_W_PH,
114 DPAQX_S_W_PH,
115 DPAQX_SA_W_PH,
116 DPAX_W_PH,
117 DPSX_W_PH,
118 DPSQX_S_W_PH,
119 DPSQX_SA_W_PH,
120 MULSA_W_PH,
121
122 MULT,
123 MULTU,
124 MADD_DSP,
125 MADDU_DSP,
126 MSUB_DSP,
127 MSUBU_DSP,
128
Akira Hatanakab9ebf8d2012-06-02 00:03:12 +0000129 // Load/Store Left/Right nodes.
130 LWL = ISD::FIRST_TARGET_MEMORY_OPCODE,
131 LWR,
132 SWL,
133 SWR,
134 LDL,
135 LDR,
136 SDL,
137 SDR
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000138 };
139 }
140
Akira Hatanakae2489122011-04-15 21:51:11 +0000141 //===--------------------------------------------------------------------===//
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000142 // TargetLowering Implementation
Akira Hatanakae2489122011-04-15 21:51:11 +0000143 //===--------------------------------------------------------------------===//
Bruno Cardoso Lopesed874ef2011-03-04 17:51:39 +0000144
Chris Lattner58e8be82009-08-13 05:41:27 +0000145 class MipsTargetLowering : public TargetLowering {
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000146 public:
Dan Gohman5f6a9da52007-08-02 21:21:54 +0000147 explicit MipsTargetLowering(MipsTargetMachine &TM);
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000148
Akira Hatanaka770f0642011-11-07 18:59:49 +0000149 virtual MVT getShiftAmountTy(EVT LHSTy) const { return MVT::i32; }
150
Akira Hatanaka2fcc1cf2011-08-12 21:30:06 +0000151 virtual bool allowsUnalignedMemoryAccesses (EVT VT) const;
152
Akira Hatanakafabb8cf2012-09-21 23:58:31 +0000153 virtual void LowerOperationWrapper(SDNode *N,
154 SmallVectorImpl<SDValue> &Results,
155 SelectionDAG &DAG) const;
156
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000157 /// LowerOperation - Provide custom lowering hooks for some operations.
Dan Gohman21cea8a2010-04-17 15:26:15 +0000158 virtual SDValue LowerOperation(SDValue Op, SelectionDAG &DAG) const;
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000159
Akira Hatanakafabb8cf2012-09-21 23:58:31 +0000160 /// ReplaceNodeResults - Replace the results of node with an illegal result
161 /// type with new values built out of custom code.
162 ///
163 virtual void ReplaceNodeResults(SDNode *N, SmallVectorImpl<SDValue>&Results,
164 SelectionDAG &DAG) const;
165
Bruno Cardoso Lopesed874ef2011-03-04 17:51:39 +0000166 /// getTargetNodeName - This method returns the name of a target specific
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000167 // DAG node.
168 virtual const char *getTargetNodeName(unsigned Opcode) const;
169
Scott Michela6729e82008-03-10 15:42:14 +0000170 /// getSetCCResultType - get the ISD::SETCC result ValueType
Duncan Sandsf2641e12011-09-06 19:07:46 +0000171 EVT getSetCCResultType(EVT VT) const;
Scott Michela6729e82008-03-10 15:42:14 +0000172
Bruno Cardoso Lopesed874ef2011-03-04 17:51:39 +0000173 virtual SDValue PerformDAGCombine(SDNode *N, DAGCombinerInfo &DCI) const;
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000174 private:
Akira Hatanaka4a3711d2012-10-26 23:56:38 +0000175
176 /// ByValArgInfo - Byval argument information.
177 struct ByValArgInfo {
178 unsigned FirstIdx; // Index of the first register used.
179 unsigned NumRegs; // Number of registers used for this argument.
180 unsigned Address; // Offset of the stack area used to pass this argument.
181
182 ByValArgInfo() : FirstIdx(0), NumRegs(0), Address(0) {}
183 };
184
185 /// MipsCC - This class provides methods used to analyze formal and call
186 /// arguments and inquire about calling convention information.
187 class MipsCC {
188 public:
189 MipsCC(CallingConv::ID CallConv, bool IsVarArg, bool IsO32,
190 CCState &Info);
191
192 void analyzeCallOperands(const SmallVectorImpl<ISD::OutputArg> &Outs);
193 void analyzeFormalArguments(const SmallVectorImpl<ISD::InputArg> &Ins);
194 void handleByValArg(unsigned ValNo, MVT ValVT, MVT LocVT,
195 CCValAssign::LocInfo LocInfo,
196 ISD::ArgFlagsTy ArgFlags);
197
198 const CCState &getCCInfo() const { return CCInfo; }
199
200 /// hasByValArg - Returns true if function has byval arguments.
201 bool hasByValArg() const { return !ByValArgs.empty(); }
202
203 /// useRegsForByval - Returns true if the calling convention allows the
204 /// use of registers to pass byval arguments.
205 bool useRegsForByval() const { return UseRegsForByval; }
206
207 /// regSize - Size (in number of bits) of integer registers.
208 unsigned regSize() const { return RegSize; }
209
210 /// numIntArgRegs - Number of integer registers available for calls.
211 unsigned numIntArgRegs() const { return NumIntArgRegs; }
212
213 /// reservedArgArea - The size of the area the caller reserves for
214 /// register arguments. This is 16-byte if ABI is O32.
215 unsigned reservedArgArea() const { return ReservedArgArea; }
216
217 /// intArgRegs - Pointer to array of integer registers.
218 const uint16_t *intArgRegs() const { return IntArgRegs; }
219
220 typedef SmallVector<ByValArgInfo, 2>::const_iterator byval_iterator;
221 byval_iterator byval_begin() const { return ByValArgs.begin(); }
222 byval_iterator byval_end() const { return ByValArgs.end(); }
223
224 private:
225 void allocateRegs(ByValArgInfo &ByVal, unsigned ByValSize,
226 unsigned Align);
227
228 CCState &CCInfo;
229 bool UseRegsForByval;
230 unsigned RegSize;
231 unsigned NumIntArgRegs;
232 unsigned ReservedArgArea;
233 const uint16_t *IntArgRegs, *ShadowRegs;
234 SmallVector<ByValArgInfo, 2> ByValArgs;
235 llvm::CCAssignFn *FixedFn, *VarFn;
236 };
237
Bruno Cardoso Lopesc9c3f492008-07-05 19:05:21 +0000238 // Subtarget Info
239 const MipsSubtarget *Subtarget;
Jia Liuf54f60f2012-02-28 07:46:26 +0000240
Akira Hatanaka7989f152011-10-28 18:47:24 +0000241 bool HasMips64, IsN64, IsO32;
Chris Lattner58e8be82009-08-13 05:41:27 +0000242
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000243 // Lower Operand helpers
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000244 SDValue LowerCallResult(SDValue Chain, SDValue InFlag,
Sandeep Patel68c5f472009-09-02 08:44:58 +0000245 CallingConv::ID CallConv, bool isVarArg,
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000246 const SmallVectorImpl<ISD::InputArg> &Ins,
247 DebugLoc dl, SelectionDAG &DAG,
Dan Gohman21cea8a2010-04-17 15:26:15 +0000248 SmallVectorImpl<SDValue> &InVals) const;
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000249
250 // Lower Operand specifics
Dan Gohman21cea8a2010-04-17 15:26:15 +0000251 SDValue LowerBRCOND(SDValue Op, SelectionDAG &DAG) const;
252 SDValue LowerConstantPool(SDValue Op, SelectionDAG &DAG) const;
Dan Gohman21cea8a2010-04-17 15:26:15 +0000253 SDValue LowerGlobalAddress(SDValue Op, SelectionDAG &DAG) const;
Bruno Cardoso Lopesf8198e42011-03-04 20:01:52 +0000254 SDValue LowerBlockAddress(SDValue Op, SelectionDAG &DAG) const;
Dan Gohman21cea8a2010-04-17 15:26:15 +0000255 SDValue LowerGlobalTLSAddress(SDValue Op, SelectionDAG &DAG) const;
256 SDValue LowerJumpTable(SDValue Op, SelectionDAG &DAG) const;
257 SDValue LowerSELECT(SDValue Op, SelectionDAG &DAG) const;
Akira Hatanaka24cf4e32012-07-11 19:32:27 +0000258 SDValue LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const;
Akira Hatanakab7f78592012-03-09 23:46:03 +0000259 SDValue LowerSETCC(SDValue Op, SelectionDAG &DAG) const;
Dan Gohman21cea8a2010-04-17 15:26:15 +0000260 SDValue LowerVASTART(SDValue Op, SelectionDAG &DAG) const;
Akira Hatanaka44eba3a2011-05-25 19:32:07 +0000261 SDValue LowerFCOPYSIGN(SDValue Op, SelectionDAG &DAG) const;
Akira Hatanaka7f4c9d12012-04-11 22:49:04 +0000262 SDValue LowerFABS(SDValue Op, SelectionDAG &DAG) const;
Akira Hatanaka66277522011-06-02 00:24:44 +0000263 SDValue LowerFRAMEADDR(SDValue Op, SelectionDAG &DAG) const;
Akira Hatanaka878ad8b2012-07-11 00:53:32 +0000264 SDValue LowerRETURNADDR(SDValue Op, SelectionDAG &DAG) const;
Akira Hatanakaa4c09bc2011-07-19 23:30:50 +0000265 SDValue LowerMEMBARRIER(SDValue Op, SelectionDAG& DAG) const;
Eli Friedman26a48482011-07-27 22:21:52 +0000266 SDValue LowerATOMIC_FENCE(SDValue Op, SelectionDAG& DAG) const;
Akira Hatanaka0a8ab712012-05-09 00:55:21 +0000267 SDValue LowerShiftLeftParts(SDValue Op, SelectionDAG& DAG) const;
Akira Hatanaka5fd22482012-06-14 21:10:56 +0000268 SDValue LowerShiftRightParts(SDValue Op, SelectionDAG& DAG,
269 bool IsSRA) const;
Akira Hatanaka8f1db772012-06-02 00:03:49 +0000270 SDValue LowerLOAD(SDValue Op, SelectionDAG &DAG) const;
271 SDValue LowerSTORE(SDValue Op, SelectionDAG &DAG) const;
Akira Hatanaka1babeaa2012-09-27 02:05:42 +0000272 SDValue LowerINTRINSIC_WO_CHAIN(SDValue Op, SelectionDAG &DAG) const;
273 SDValue LowerINTRINSIC_W_CHAIN(SDValue Op, SelectionDAG &DAG) const;
Bruno Cardoso Lopes4eed3af2008-06-06 00:58:26 +0000274
Akira Hatanaka90131ac2012-10-19 21:47:33 +0000275 /// IsEligibleForTailCallOptimization - Check whether the call is eligible
276 /// for tail call optimization.
Akira Hatanaka6a124a82012-10-27 00:56:56 +0000277 bool IsEligibleForTailCallOptimization(const MipsCC &MipsCCInfo,
278 bool IsVarArg,
Akira Hatanaka90131ac2012-10-19 21:47:33 +0000279 unsigned NextStackOffset) const;
280
Akira Hatanaka25dad192012-10-27 00:10:18 +0000281 /// copyByValArg - Copy argument registers which were used to pass a byval
282 /// argument to the stack. Create a stack frame object for the byval
283 /// argument.
284 void copyByValRegs(SDValue Chain, DebugLoc DL,
285 std::vector<SDValue> &OutChains, SelectionDAG &DAG,
286 const ISD::ArgFlagsTy &Flags,
287 SmallVectorImpl<SDValue> &InVals,
288 const Argument *FuncArg,
289 const MipsCC &CC, const ByValArgInfo &ByVal) const;
290
Akira Hatanaka35f55b12012-10-27 00:16:36 +0000291 /// passByValArg - Pass a byval argument in registers or on stack.
292 void passByValArg(SDValue Chain, DebugLoc DL,
293 SmallVector<std::pair<unsigned, SDValue>, 16> &RegsToPass,
294 SmallVector<SDValue, 8> &MemOpChains, SDValue StackPtr,
295 MachineFrameInfo *MFI, SelectionDAG &DAG, SDValue Arg,
296 const MipsCC &CC, const ByValArgInfo &ByVal,
297 const ISD::ArgFlagsTy &Flags, bool isLittle) const;
298
Akira Hatanaka2a134022012-10-27 00:21:13 +0000299 /// writeVarArgRegs - Write variable function arguments passed in registers
300 /// to the stack. Also create a stack frame object for the first variable
301 /// argument.
302 void writeVarArgRegs(std::vector<SDValue> &OutChains, const MipsCC &CC,
303 SDValue Chain, DebugLoc DL, SelectionDAG &DAG) const;
304
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000305 virtual SDValue
306 LowerFormalArguments(SDValue Chain,
Sandeep Patel68c5f472009-09-02 08:44:58 +0000307 CallingConv::ID CallConv, bool isVarArg,
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000308 const SmallVectorImpl<ISD::InputArg> &Ins,
309 DebugLoc dl, SelectionDAG &DAG,
Dan Gohman21cea8a2010-04-17 15:26:15 +0000310 SmallVectorImpl<SDValue> &InVals) const;
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000311
Akira Hatanaka6233cf52012-10-30 19:23:25 +0000312 SDValue passArgOnStack(SDValue StackPtr, unsigned Offset, SDValue Chain,
313 SDValue Arg, DebugLoc DL, bool IsTailCall,
314 SelectionDAG &DAG) const;
315
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000316 virtual SDValue
Justin Holewinskiaa583972012-05-25 16:35:28 +0000317 LowerCall(TargetLowering::CallLoweringInfo &CLI,
Dan Gohman21cea8a2010-04-17 15:26:15 +0000318 SmallVectorImpl<SDValue> &InVals) const;
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000319
Akira Hatanaka9c8dcfc2012-10-10 01:27:09 +0000320 virtual bool
321 CanLowerReturn(CallingConv::ID CallConv, MachineFunction &MF,
322 bool isVarArg,
323 const SmallVectorImpl<ISD::OutputArg> &Outs,
324 LLVMContext &Context) const;
325
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000326 virtual SDValue
327 LowerReturn(SDValue Chain,
Sandeep Patel68c5f472009-09-02 08:44:58 +0000328 CallingConv::ID CallConv, bool isVarArg,
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000329 const SmallVectorImpl<ISD::OutputArg> &Outs,
Dan Gohmanfe7532a2010-07-07 15:54:55 +0000330 const SmallVectorImpl<SDValue> &OutVals,
Dan Gohman21cea8a2010-04-17 15:26:15 +0000331 DebugLoc dl, SelectionDAG &DAG) const;
Dan Gohmanf9bbcd12009-08-05 01:29:28 +0000332
Dan Gohman25c16532010-05-01 00:01:06 +0000333 virtual MachineBasicBlock *
334 EmitInstrWithCustomInserter(MachineInstr *MI,
335 MachineBasicBlock *MBB) const;
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000336
Bruno Cardoso Lopesb10580a2007-08-21 16:09:25 +0000337 // Inline asm support
338 ConstraintType getConstraintType(const std::string &Constraint) const;
339
Akira Hatanakae2489122011-04-15 21:51:11 +0000340 /// Examine constraint string and operand type and determine a weight value.
341 /// The operand object must already have been set up with the operand type.
John Thompsone8360b72010-10-29 17:29:13 +0000342 ConstraintWeight getSingleConstraintMatchWeight(
343 AsmOperandInfo &info, const char *constraint) const;
344
Bruno Cardoso Lopesed874ef2011-03-04 17:51:39 +0000345 std::pair<unsigned, const TargetRegisterClass*>
Bruno Cardoso Lopesb10580a2007-08-21 16:09:25 +0000346 getRegForInlineAsmConstraint(const std::string &Constraint,
Owen Anderson53aa7a92009-08-10 22:56:29 +0000347 EVT VT) const;
Bruno Cardoso Lopesb10580a2007-08-21 16:09:25 +0000348
Eric Christopher1d6c89e2012-05-07 03:13:32 +0000349 /// LowerAsmOperandForConstraint - Lower the specified operand into the Ops
350 /// vector. If it is invalid, don't add anything to Ops. If hasMemory is
351 /// true it means one of the asm constraint of the inline asm instruction
352 /// being processed is 'm'.
353 virtual void LowerAsmOperandForConstraint(SDValue Op,
354 std::string &Constraint,
355 std::vector<SDValue> &Ops,
356 SelectionDAG &DAG) const;
357
Dan Gohman2fe6bee2008-10-18 02:06:02 +0000358 virtual bool isOffsetFoldingLegal(const GlobalAddressSDNode *GA) const;
Evan Cheng16993aa2009-10-27 19:56:55 +0000359
Akira Hatanaka1daf8c22012-06-13 19:33:32 +0000360 virtual EVT getOptimalMemOpType(uint64_t Size, unsigned DstAlign,
361 unsigned SrcAlign, bool IsZeroVal,
362 bool MemcpyStrSrc,
363 MachineFunction &MF) const;
364
Evan Cheng16993aa2009-10-27 19:56:55 +0000365 /// isFPImmLegal - Returns true if the target can instruction select the
366 /// specified FP immediate natively. If false, the legalizer will
367 /// materialize the FP immediate as a load from a constant pool.
Evan Cheng83896a52009-10-28 01:43:28 +0000368 virtual bool isFPImmLegal(const APFloat &Imm, EVT VT) const;
Bruno Cardoso Lopes98fc4c82011-05-31 02:54:07 +0000369
Akira Hatanakaf0b08442012-02-03 04:33:00 +0000370 virtual unsigned getJumpTableEncoding() const;
371
Akira Hatanakae4bd0542012-09-27 02:15:57 +0000372 MachineBasicBlock *EmitBPOSGE32(MachineInstr *MI,
373 MachineBasicBlock *BB) const;
Bruno Cardoso Lopes98fc4c82011-05-31 02:54:07 +0000374 MachineBasicBlock *EmitAtomicBinary(MachineInstr *MI, MachineBasicBlock *BB,
375 unsigned Size, unsigned BinOpcode, bool Nand = false) const;
376 MachineBasicBlock *EmitAtomicBinaryPartword(MachineInstr *MI,
377 MachineBasicBlock *BB, unsigned Size, unsigned BinOpcode,
378 bool Nand = false) const;
379 MachineBasicBlock *EmitAtomicCmpSwap(MachineInstr *MI,
380 MachineBasicBlock *BB, unsigned Size) const;
381 MachineBasicBlock *EmitAtomicCmpSwapPartword(MachineInstr *MI,
382 MachineBasicBlock *BB, unsigned Size) const;
Bruno Cardoso Lopes35e43c42007-06-06 07:42:06 +0000383 };
384}
385
386#endif // MipsISELLOWERING_H