blob: 9fe286a3b7a9a27679ae0a0c9d5cd8744a46af75 [file] [log] [blame]
Jia Liub22310f2012-02-18 12:03:15 +00001//===-- PPCSubtarget.h - Define Subtarget for the PPC ----------*- C++ -*--===//
Nate Begeman3bcfcd92005-08-04 07:12:09 +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.
Nate Begeman3bcfcd92005-08-04 07:12:09 +00007//
8//===----------------------------------------------------------------------===//
9//
Evan Cheng0d639a22011-07-01 21:01:15 +000010// This file declares the PowerPC specific subclass of TargetSubtargetInfo.
Nate Begeman3bcfcd92005-08-04 07:12:09 +000011//
12//===----------------------------------------------------------------------===//
13
Benjamin Kramera7c40ef2014-08-13 16:26:38 +000014#ifndef LLVM_LIB_TARGET_POWERPC_PPCSUBTARGET_H
15#define LLVM_LIB_TARGET_POWERPC_PPCSUBTARGET_H
Nate Begeman3bcfcd92005-08-04 07:12:09 +000016
Eric Christopherd104c312014-06-12 20:54:11 +000017#include "PPCFrameLowering.h"
Eric Christopherf8c031f2014-06-12 22:50:10 +000018#include "PPCISelLowering.h"
Chandler Carruthd9903882015-01-14 11:23:27 +000019#include "PPCInstrInfo.h"
Evan Cheng8264e272011-06-29 01:14:12 +000020#include "llvm/ADT/Triple.h"
Benjamin Kramerf9172fd42016-01-27 16:32:26 +000021#include "llvm/CodeGen/SelectionDAGTargetInfo.h"
Eric Christopher49628bc2014-06-12 21:08:06 +000022#include "llvm/IR/DataLayout.h"
Chandler Carruth802d7552012-12-04 07:12:27 +000023#include "llvm/MC/MCInstrItineraries.h"
24#include "llvm/Target/TargetSubtargetInfo.h"
Jim Laskey19058c32005-09-01 21:38:21 +000025#include <string>
26
Evan Cheng54b68e32011-07-01 20:45:01 +000027#define GET_SUBTARGETINFO_HEADER
Evan Chengc9c090d2011-07-01 22:36:09 +000028#include "PPCGenSubtargetInfo.inc"
Evan Cheng54b68e32011-07-01 20:45:01 +000029
Nick Lewycky28c5b862007-01-19 04:36:02 +000030// GCC #defines PPC on Linux but we use it as our namespace name
31#undef PPC
32
Nate Begeman3bcfcd92005-08-04 07:12:09 +000033namespace llvm {
Evan Cheng1a72add62011-07-07 07:07:08 +000034class StringRef;
Jim Laskey59e7a772006-12-12 20:57:08 +000035
36namespace PPC {
37 // -m directive values.
38 enum {
Dale Johannesen6ca3ccf2008-02-14 23:35:16 +000039 DIR_NONE,
Jim Laskey59e7a772006-12-12 20:57:08 +000040 DIR_32,
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +000041 DIR_440,
42 DIR_601,
43 DIR_602,
44 DIR_603,
Jim Laskey59e7a772006-12-12 20:57:08 +000045 DIR_7400,
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +000046 DIR_750,
47 DIR_970,
Hal Finkel9f9f8922012-04-01 19:22:40 +000048 DIR_A2,
Hal Finkel742b5352012-08-28 16:12:39 +000049 DIR_E500mc,
50 DIR_E5500,
Bill Schmidt52742c22013-02-01 22:59:51 +000051 DIR_PWR3,
52 DIR_PWR4,
53 DIR_PWR5,
54 DIR_PWR5X,
Hal Finkelf2b9c382012-06-11 15:43:08 +000055 DIR_PWR6,
Bill Schmidt52742c22013-02-01 22:59:51 +000056 DIR_PWR6X,
Hal Finkelf2b9c382012-06-11 15:43:08 +000057 DIR_PWR7,
Will Schmidt970ff642014-06-26 13:36:19 +000058 DIR_PWR8,
Nemanja Ivanovic6e29baf2016-05-09 18:54:58 +000059 DIR_PWR9,
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +000060 DIR_64
Jim Laskey59e7a772006-12-12 20:57:08 +000061 };
Alexander Kornienkof00654e2015-06-23 09:49:53 +000062}
Jim Laskey59e7a772006-12-12 20:57:08 +000063
Chris Lattnerf4646a72006-12-11 23:22:45 +000064class GlobalValue;
65class TargetMachine;
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +000066
Evan Cheng54b68e32011-07-01 20:45:01 +000067class PPCSubtarget : public PPCGenSubtargetInfo {
Hal Finkelfa7057a2016-03-29 01:36:01 +000068public:
69 enum POPCNTDKind {
70 POPCNTD_Unavailable,
71 POPCNTD_Slow,
72 POPCNTD_Fast
73 };
74
Nate Begeman3bcfcd92005-08-04 07:12:09 +000075protected:
Eric Christopher3770cf52014-08-09 04:38:56 +000076 /// TargetTriple - What processor and OS we're targeting.
77 Triple TargetTriple;
78
Nate Begeman3bcfcd92005-08-04 07:12:09 +000079 /// stackAlignment - The minimum alignment known to hold of the stack frame on
80 /// entry to the function and which must be maintained by every function.
Chris Lattner983a4152005-08-05 22:05:03 +000081 unsigned StackAlignment;
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +000082
Jim Laskey802748c2005-11-01 20:06:59 +000083 /// Selected instruction itineraries (one entry per itinerary class.)
84 InstrItineraryData InstrItins;
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +000085
Jim Laskey59e7a772006-12-12 20:57:08 +000086 /// Which cpu directive was used.
87 unsigned DarwinDirective;
Nate Begeman3bcfcd92005-08-04 07:12:09 +000088
89 /// Used by the ISel to turn in optimizations for POWER4-derived architectures
Hal Finkelbfd3d082012-06-11 19:57:01 +000090 bool HasMFOCRF;
Chris Lattnera35f3062006-06-16 17:34:12 +000091 bool Has64BitSupport;
92 bool Use64BitRegs;
Hal Finkel940ab932014-02-28 00:27:01 +000093 bool UseCRBits;
Petar Jovanovic280f7102015-12-14 17:57:33 +000094 bool UseSoftFloat;
Chris Lattner16682ff2006-06-16 17:50:12 +000095 bool IsPPC64;
Jim Laskeya2b52352005-10-26 17:30:34 +000096 bool HasAltivec;
Joerg Sonnenberger39f095a2014-08-07 12:18:21 +000097 bool HasSPE;
Hal Finkelefb305e2013-01-30 21:17:42 +000098 bool HasQPX;
Eric Christopher081efcc2013-10-16 20:38:58 +000099 bool HasVSX;
Bill Schmidtdcce0232014-10-10 17:21:15 +0000100 bool HasP8Vector;
Bill Schmidtfe88b182015-02-03 21:58:23 +0000101 bool HasP8Altivec;
Nemanja Ivanovice8effe12015-03-04 20:44:33 +0000102 bool HasP8Crypto;
Kit Barton93612ec2016-02-26 21:11:55 +0000103 bool HasP9Vector;
104 bool HasP9Altivec;
Hal Finkeldbc78e12013-08-19 05:01:02 +0000105 bool HasFCPSGN;
Chris Lattneraa3b1fc2005-09-02 18:33:05 +0000106 bool HasFSQRT;
Hal Finkel2e103312013-04-03 04:01:11 +0000107 bool HasFRE, HasFRES, HasFRSQRTE, HasFRSQRTES;
108 bool HasRecipPrec;
Chris Lattnerb9f35f02006-02-28 07:08:22 +0000109 bool HasSTFIWX;
Hal Finkelbeb296b2013-03-31 10:12:51 +0000110 bool HasLFIWAX;
Hal Finkelc20a08d2013-03-29 08:57:48 +0000111 bool HasFPRND;
Hal Finkelf6d45f22013-04-01 17:52:07 +0000112 bool HasFPCVT;
Hal Finkel460e94d2012-06-22 23:10:08 +0000113 bool HasISEL;
Nemanja Ivanovicc0904792015-04-09 23:54:37 +0000114 bool HasBPERMD;
115 bool HasExtDiv;
Hal Finkel4edc66b2015-01-03 01:16:37 +0000116 bool HasCMPB;
Hal Finkel31d29562013-03-28 19:25:55 +0000117 bool HasLDBRX;
Hal Finkel6fa56972011-10-17 04:03:49 +0000118 bool IsBookE;
Hal Finkelfe3368c2014-10-02 22:34:22 +0000119 bool HasOnlyMSYNC;
Joerg Sonnenberger0b2ebcb2014-08-04 15:47:38 +0000120 bool IsE500;
121 bool IsPPC4xx;
Joerg Sonnenberger74052102014-08-04 17:07:41 +0000122 bool IsPPC6xx;
Kit Barton4f79f962015-06-16 16:01:15 +0000123 bool FeatureMFTB;
Hal Finkel0096dbd2013-09-12 14:40:06 +0000124 bool DeprecatedDST;
Chris Lattnerf4646a72006-12-11 23:22:45 +0000125 bool HasLazyResolverStubs;
Bill Schmidt0a9170d2013-07-26 01:35:43 +0000126 bool IsLittleEndian;
Bill Schmidt082cfc02015-01-14 20:17:10 +0000127 bool HasICBT;
Hal Finkele2ab0f12015-01-15 21:17:34 +0000128 bool HasInvariantFunctionDescriptors;
Nemanja Ivanovic0adf26b2015-03-10 20:51:07 +0000129 bool HasPartwordAtomics;
Nemanja Ivanovicc38b5312015-04-11 10:40:42 +0000130 bool HasDirectMove;
Kit Barton535e69d2015-03-25 19:36:23 +0000131 bool HasHTM;
Eric Christopher25bf4a82015-11-20 22:38:20 +0000132 bool HasFusion;
Nemanja Ivanovicb033f672015-12-15 12:19:34 +0000133 bool HasFloat128;
Nemanja Ivanovica621a7f2016-03-31 15:26:37 +0000134 bool IsISA3_0;
Hal Finkelfa7057a2016-03-29 01:36:01 +0000135
136 POPCNTDKind HasPOPCNTD;
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000137
Hal Finkelc93a9a22015-02-25 01:06:45 +0000138 /// When targeting QPX running a stock PPC64 Linux kernel where the stack
139 /// alignment has not been changed, we need to keep the 16-byte alignment
140 /// of the stack.
141 bool IsQPXStackUnaligned;
142
Eric Christophera10d58d2015-02-13 22:48:51 +0000143 const PPCTargetMachine &TM;
Eric Christopherf55a2242014-06-12 22:28:06 +0000144 PPCFrameLowering FrameLowering;
Eric Christopherbd14dc52014-06-12 22:05:46 +0000145 PPCInstrInfo InstrInfo;
Eric Christopherf8c031f2014-06-12 22:50:10 +0000146 PPCTargetLowering TLInfo;
Benjamin Kramerf9172fd42016-01-27 16:32:26 +0000147 SelectionDAGTargetInfo TSInfo;
Eric Christopher49628bc2014-06-12 21:08:06 +0000148
Nate Begeman3bcfcd92005-08-04 07:12:09 +0000149public:
150 /// This constructor initializes the data members to match that
Daniel Dunbar31b44e82009-08-02 22:11:08 +0000151 /// of the specified triple.
Nate Begeman3bcfcd92005-08-04 07:12:09 +0000152 ///
Daniel Sandersa73f1fd2015-06-10 12:11:26 +0000153 PPCSubtarget(const Triple &TT, const std::string &CPU, const std::string &FS,
154 const PPCTargetMachine &TM);
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000155
156 /// ParseSubtargetFeatures - Parses features string setting specified
Jim Laskey75eab3c2005-10-26 18:07:50 +0000157 /// subtarget options. Definition of function is auto generated by tblgen.
Evan Cheng1a72add62011-07-07 07:07:08 +0000158 void ParseSubtargetFeatures(StringRef CPU, StringRef FS);
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000159
Nate Begeman3bcfcd92005-08-04 07:12:09 +0000160 /// getStackAlignment - Returns the minimum alignment known to hold of the
161 /// stack frame on entry to the function and which must be maintained by every
162 /// function for this subtarget.
Chris Lattner983a4152005-08-05 22:05:03 +0000163 unsigned getStackAlignment() const { return StackAlignment; }
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000164
Jim Laskey59e7a772006-12-12 20:57:08 +0000165 /// getDarwinDirective - Returns the -m directive specified for the cpu.
166 ///
167 unsigned getDarwinDirective() const { return DarwinDirective; }
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000168
Eric Christopher170ebcf2014-06-13 22:38:48 +0000169 /// getInstrItins - Return the instruction itineraries based on subtarget
Jim Laskey802748c2005-11-01 20:06:59 +0000170 /// selection.
Eric Christopherd9134482014-08-04 21:25:23 +0000171 const InstrItineraryData *getInstrItineraryData() const override {
172 return &InstrItins;
173 }
Chris Lattner16682ff2006-06-16 17:50:12 +0000174
Eric Christopherd9134482014-08-04 21:25:23 +0000175 const PPCFrameLowering *getFrameLowering() const override {
176 return &FrameLowering;
177 }
Eric Christopherd9134482014-08-04 21:25:23 +0000178 const PPCInstrInfo *getInstrInfo() const override { return &InstrInfo; }
Eric Christopherd9134482014-08-04 21:25:23 +0000179 const PPCTargetLowering *getTargetLowering() const override {
180 return &TLInfo;
181 }
Benjamin Kramerf9172fd42016-01-27 16:32:26 +0000182 const SelectionDAGTargetInfo *getSelectionDAGInfo() const override {
Eric Christopherd9134482014-08-04 21:25:23 +0000183 return &TSInfo;
184 }
185 const PPCRegisterInfo *getRegisterInfo() const override {
186 return &getInstrInfo()->getRegisterInfo();
187 }
Eric Christophere8dbfe12015-02-13 22:23:04 +0000188 const PPCTargetMachine &getTargetMachine() const { return TM; }
Eric Christopherd104c312014-06-12 20:54:11 +0000189
190 /// initializeSubtargetDependencies - Initializes using a CPU and feature string
191 /// so that we can use initializer lists for subtarget initialization.
192 PPCSubtarget &initializeSubtargetDependencies(StringRef CPU, StringRef FS);
193
Hal Finkela0014a52013-07-15 22:29:40 +0000194private:
195 void initializeEnvironment();
Eric Christopherb68e2532014-09-03 20:36:31 +0000196 void initSubtargetFeatures(StringRef CPU, StringRef FS);
Hal Finkela0014a52013-07-15 22:29:40 +0000197
198public:
Chris Lattner16682ff2006-06-16 17:50:12 +0000199 /// isPPC64 - Return true if we are generating code for 64-bit pointer mode.
200 ///
Eric Christopherfee6aaf2015-02-17 06:45:15 +0000201 bool isPPC64() const;
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000202
Chris Lattner16682ff2006-06-16 17:50:12 +0000203 /// has64BitSupport - Return true if the selected CPU supports 64-bit
204 /// instructions, regardless of whether we are in 32-bit or 64-bit mode.
205 bool has64BitSupport() const { return Has64BitSupport; }
Petar Jovanovic280f7102015-12-14 17:57:33 +0000206 // useSoftFloat - Return true if soft-float option is turned on.
207 bool useSoftFloat() const { return UseSoftFloat; }
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000208
Chris Lattner16682ff2006-06-16 17:50:12 +0000209 /// use64BitRegs - Return true if in 64-bit mode or if we should use 64-bit
210 /// registers in 32-bit mode when possible. This can only true if
211 /// has64BitSupport() returns true.
212 bool use64BitRegs() const { return Use64BitRegs; }
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000213
Hal Finkel940ab932014-02-28 00:27:01 +0000214 /// useCRBits - Return true if we should store and manipulate i1 values in
215 /// the individual condition register bits.
216 bool useCRBits() const { return UseCRBits; }
217
Chris Lattnerf4646a72006-12-11 23:22:45 +0000218 /// hasLazyResolverStub - Return true if accesses to the specified global have
219 /// to go through a dyld lazy resolution stub. This means that an extra load
220 /// is required to get the address of the global.
Eric Christophere8dbfe12015-02-13 22:23:04 +0000221 bool hasLazyResolverStub(const GlobalValue *GV) const;
NAKAMURA Takumi70b25de2012-10-29 15:51:35 +0000222
Bill Schmidt0a9170d2013-07-26 01:35:43 +0000223 // isLittleEndian - True if generating little-endian code
224 bool isLittleEndian() const { return IsLittleEndian; }
225
Chris Lattner16682ff2006-06-16 17:50:12 +0000226 // Specific obvious features.
Hal Finkeldbc78e12013-08-19 05:01:02 +0000227 bool hasFCPSGN() const { return HasFCPSGN; }
Chris Lattneraa3b1fc2005-09-02 18:33:05 +0000228 bool hasFSQRT() const { return HasFSQRT; }
Hal Finkel2e103312013-04-03 04:01:11 +0000229 bool hasFRE() const { return HasFRE; }
230 bool hasFRES() const { return HasFRES; }
231 bool hasFRSQRTE() const { return HasFRSQRTE; }
232 bool hasFRSQRTES() const { return HasFRSQRTES; }
233 bool hasRecipPrec() const { return HasRecipPrec; }
Chris Lattnerb9f35f02006-02-28 07:08:22 +0000234 bool hasSTFIWX() const { return HasSTFIWX; }
Hal Finkelbeb296b2013-03-31 10:12:51 +0000235 bool hasLFIWAX() const { return HasLFIWAX; }
Hal Finkelc20a08d2013-03-29 08:57:48 +0000236 bool hasFPRND() const { return HasFPRND; }
Hal Finkelf6d45f22013-04-01 17:52:07 +0000237 bool hasFPCVT() const { return HasFPCVT; }
Jim Laskeya2b52352005-10-26 17:30:34 +0000238 bool hasAltivec() const { return HasAltivec; }
Joerg Sonnenberger39f095a2014-08-07 12:18:21 +0000239 bool hasSPE() const { return HasSPE; }
Hal Finkelefb305e2013-01-30 21:17:42 +0000240 bool hasQPX() const { return HasQPX; }
Hal Finkel27774d92014-03-13 07:58:58 +0000241 bool hasVSX() const { return HasVSX; }
Bill Schmidtdcce0232014-10-10 17:21:15 +0000242 bool hasP8Vector() const { return HasP8Vector; }
Bill Schmidtfe88b182015-02-03 21:58:23 +0000243 bool hasP8Altivec() const { return HasP8Altivec; }
Nemanja Ivanovice8effe12015-03-04 20:44:33 +0000244 bool hasP8Crypto() const { return HasP8Crypto; }
Kit Barton93612ec2016-02-26 21:11:55 +0000245 bool hasP9Vector() const { return HasP9Vector; }
246 bool hasP9Altivec() const { return HasP9Altivec; }
Hal Finkelbfd3d082012-06-11 19:57:01 +0000247 bool hasMFOCRF() const { return HasMFOCRF; }
Hal Finkel460e94d2012-06-22 23:10:08 +0000248 bool hasISEL() const { return HasISEL; }
Nemanja Ivanovicc0904792015-04-09 23:54:37 +0000249 bool hasBPERMD() const { return HasBPERMD; }
250 bool hasExtDiv() const { return HasExtDiv; }
Hal Finkel4edc66b2015-01-03 01:16:37 +0000251 bool hasCMPB() const { return HasCMPB; }
Hal Finkel31d29562013-03-28 19:25:55 +0000252 bool hasLDBRX() const { return HasLDBRX; }
Hal Finkel6fa56972011-10-17 04:03:49 +0000253 bool isBookE() const { return IsBookE; }
Hal Finkelfe3368c2014-10-02 22:34:22 +0000254 bool hasOnlyMSYNC() const { return HasOnlyMSYNC; }
Joerg Sonnenberger0b2ebcb2014-08-04 15:47:38 +0000255 bool isPPC4xx() const { return IsPPC4xx; }
Joerg Sonnenberger74052102014-08-04 17:07:41 +0000256 bool isPPC6xx() const { return IsPPC6xx; }
Joerg Sonnenberger0b2ebcb2014-08-04 15:47:38 +0000257 bool isE500() const { return IsE500; }
Kit Barton4f79f962015-06-16 16:01:15 +0000258 bool isFeatureMFTB() const { return FeatureMFTB; }
Hal Finkel0096dbd2013-09-12 14:40:06 +0000259 bool isDeprecatedDST() const { return DeprecatedDST; }
Bill Schmidt082cfc02015-01-14 20:17:10 +0000260 bool hasICBT() const { return HasICBT; }
Hal Finkele2ab0f12015-01-15 21:17:34 +0000261 bool hasInvariantFunctionDescriptors() const {
262 return HasInvariantFunctionDescriptors;
263 }
Nemanja Ivanovic0adf26b2015-03-10 20:51:07 +0000264 bool hasPartwordAtomics() const { return HasPartwordAtomics; }
Nemanja Ivanovicc38b5312015-04-11 10:40:42 +0000265 bool hasDirectMove() const { return HasDirectMove; }
Bill Wendlingc7b2ab92007-01-16 09:29:17 +0000266
Hal Finkelc93a9a22015-02-25 01:06:45 +0000267 bool isQPXStackUnaligned() const { return IsQPXStackUnaligned; }
268 unsigned getPlatformStackAlignment() const {
269 if ((hasQPX() || isBGQ()) && !isQPXStackUnaligned())
270 return 32;
271
272 return 16;
273 }
Kit Barton535e69d2015-03-25 19:36:23 +0000274 bool hasHTM() const { return HasHTM; }
Eric Christopher25bf4a82015-11-20 22:38:20 +0000275 bool hasFusion() const { return HasFusion; }
Nemanja Ivanovicb033f672015-12-15 12:19:34 +0000276 bool hasFloat128() const { return HasFloat128; }
Nemanja Ivanovica621a7f2016-03-31 15:26:37 +0000277 bool isISA3_0() const { return IsISA3_0; }
Hal Finkelc93a9a22015-02-25 01:06:45 +0000278
Hal Finkelfa7057a2016-03-29 01:36:01 +0000279 POPCNTDKind hasPOPCNTD() const { return HasPOPCNTD; }
280
Daniel Dunbara37aab22011-04-19 20:54:28 +0000281 const Triple &getTargetTriple() const { return TargetTriple; }
282
Chris Lattnerdcbc0f32008-01-02 19:35:16 +0000283 /// isDarwin - True if this is any darwin platform.
Daniel Dunbarcd01ed52011-04-20 00:14:25 +0000284 bool isDarwin() const { return TargetTriple.isMacOSX(); }
Hal Finkel7f9e8d32013-01-29 00:22:47 +0000285 /// isBGQ - True if this is a BG/Q platform.
286 bool isBGQ() const { return TargetTriple.getVendor() == Triple::BGQ; }
Rafael Espindola770b4b82008-12-19 10:55:56 +0000287
Hal Finkel3ee2af72014-07-18 23:29:49 +0000288 bool isTargetELF() const { return TargetTriple.isOSBinFormatELF(); }
289 bool isTargetMachO() const { return TargetTriple.isOSBinFormatMachO(); }
Tim Shena1d8bc52016-04-19 20:14:52 +0000290 bool isTargetLinux() const { return TargetTriple.isOSLinux(); }
Hal Finkel3ee2af72014-07-18 23:29:49 +0000291
Eric Christopherfee6aaf2015-02-17 06:45:15 +0000292 bool isDarwinABI() const { return isTargetMachO() || isDarwin(); }
293 bool isSVR4ABI() const { return !isDarwinABI(); }
294 bool isELFv2ABI() const;
Tilmann Schellerd1aaa322009-08-15 11:54:46 +0000295
Eric Christopher6b0fcfe2014-05-21 23:40:26 +0000296 bool enableEarlyIfConversion() const override { return hasISEL(); }
297
Hal Finkel21442b22013-09-11 23:05:25 +0000298 // Scheduling customization.
Craig Topper0d3fa922014-04-29 07:57:37 +0000299 bool enableMachineScheduler() const override;
Sanjay Patela2f658d2014-07-15 22:39:58 +0000300 // This overrides the PostRAScheduler bit in the SchedModel for each CPU.
Matthias Braun39a2afc2015-06-13 03:42:16 +0000301 bool enablePostRAScheduler() const override;
Sanjay Patela2f658d2014-07-15 22:39:58 +0000302 AntiDepBreakMode getAntiDepBreakMode() const override;
303 void getCriticalPathRCs(RegClassVector &CriticalPathRCs) const override;
304
Hal Finkel21442b22013-09-11 23:05:25 +0000305 void overrideSchedPolicy(MachineSchedPolicy &Policy,
Craig Topper0d3fa922014-04-29 07:57:37 +0000306 unsigned NumRegionInstrs) const override;
307 bool useAA() const override;
Hal Finkel5ff00b42015-01-09 02:03:11 +0000308
309 bool enableSubRegLiveness() const override;
Eric Christopherc1808362015-11-20 20:51:31 +0000310
311 /// classifyGlobalReference - Classify a global variable reference for the
312 /// current subtarget accourding to how we should reference it.
313 unsigned char classifyGlobalReference(const GlobalValue *GV) const;
Nate Begeman3bcfcd92005-08-04 07:12:09 +0000314};
Alexander Kornienkof00654e2015-06-23 09:49:53 +0000315} // End llvm namespace
Nate Begeman3bcfcd92005-08-04 07:12:09 +0000316
317#endif