13#ifndef LLVM_LIB_TARGET_NVPTX_NVPTXSUBTARGET_H
14#define LLVM_LIB_TARGET_NVPTX_NVPTXSUBTARGET_H
26#define GET_SUBTARGETINFO_HEADER
27#include "NVPTXGenSubtargetInfo.inc"
32 virtual void anchor();
33 std::string TargetName;
40 unsigned int FullSmVersion;
44 unsigned int SmVersion;
48 std::unique_ptr<const SelectionDAGTargetInfo> TSInfo;
64 return &FrameLowering;
68 return &InstrInfo.getRegisterInfo();
89 return SmVersion >= 100 && PTXVersion >= 88 &&
96 bool hasAtomCas16()
const {
return SmVersion >= 70 && PTXVersion >= 63; }
98 bool hasClusters()
const {
return SmVersion >= 90 && PTXVersion >= 78; }
99 bool hasLDG()
const {
return SmVersion >= 32; }
105 bool hasNoReturn()
const {
return SmVersion >= 30 && PTXVersion >= 64; }
111 return SmVersion >= 90 && PTXVersion >= 86;
116 return SmVersion >= 61 && PTXVersion >= 50;
120 bool HasTcgen05 =
false;
121 unsigned MinPTXVersion = 86;
122 switch (FullSmVersion) {
139 return HasTcgen05 && PTXVersion >= MinPTXVersion;
164 return FullSmVersion == 1003 && PTXVersion >= 86;
172 switch (FullSmVersion) {
175 return PTXVersion >= 86;
177 return PTXVersion >= 88;
191 bool hasCvtaParam()
const {
return SmVersion >= 70 && PTXVersion >= 77; }
215 return TargetName.empty() ?
"sm_30" : TargetName;
NVPTX address space definition.
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
bool hasCpAsyncBulkTensorCTAGroupSupport() const
const NVPTXInstrInfo * getInstrInfo() const override
void failIfClustersUnsupported(std::string const &FailureMessage) const
bool hasPTXWithAccelSMs(unsigned PTXVersion, ArrayRef< unsigned > SMVersions) const
std::string getTargetName() const
unsigned getMaxRequiredAlignment() const
bool hasAtomMinMax64() const
bool hasTcgen05InstSupport() const
bool hasAtomAddF64() const
bool hasSplitAcquireAndReleaseFences() const
bool hasMaskOperator() const
const NVPTXTargetLowering * getTargetLowering() const override
void ParseSubtargetFeatures(StringRef CPU, StringRef TuneCPU, StringRef FS)
unsigned getMinCmpXchgSizeInBits() const
unsigned getPTXVersion() const
bool hasCvtaParam() const
~NVPTXSubtarget() override
bool hasNativeBF16Support(int Opcode) const
const NVPTXRegisterInfo * getRegisterInfo() const override
unsigned int getFullSmVersion() const
unsigned int getSmVersion() const
bool hasDotInstructions() const
bool hasTcgen05MMAScaleInputDImm() const
bool hasFamilySpecificFeatures() const
bool hasTcgen05Instructions() const
bool hasAtomBitwise64() const
bool hasPTXWithFamilySMs(unsigned PTXVersion, ArrayRef< unsigned > SMVersions) const
bool hasTcgen05ShiftSupport() const
bool hasRelaxedMMIO() const
bool hasTargetName() const
bool hasAtomSwap128() const
bool hasF32x2Instructions() const
unsigned int getSmFamilyVersion() const
bool allowFP16Math() const
const TargetFrameLowering * getFrameLowering() const override
bool hasAtomScope() const
bool hasAtomCas16() const
NVPTXSubtarget(const Triple &TT, const std::string &CPU, const std::string &FS, const NVPTXTargetMachine &TM)
This constructor initializes the data members to match that of the specified module.
bool hasMemoryOrdering() const
bool hasArchAccelFeatures() const
NVPTXSubtarget & initializeSubtargetDependencies(StringRef CPU, StringRef FS)
const SelectionDAGTargetInfo * getSelectionDAGInfo() const override
bool has256BitVectorLoadStore(unsigned AS) const
bool hasPTXASUnreachableBug() const
Targets can subclass this to parameterize the SelectionDAG lowering and instruction selection process...
StringRef - Represent a constant reference to a string, i.e.
Information about stack frame layout on the target.
Triple - Helper class for working with autoconf configuration names.
This is an optimization pass for GlobalISel generic memory operations.