Lines Matching refs:STI
161 bool isHsaAbi(const MCSubtargetInfo &STI) { in isHsaAbi() argument
162 return STI.getTargetTriple().getOS() == Triple::AMDHSA; in isHsaAbi()
705 AMDGPUTargetID::AMDGPUTargetID(const MCSubtargetInfo &STI) in AMDGPUTargetID() argument
706 : STI(STI), XnackSetting(TargetIDSetting::Any), in AMDGPUTargetID()
708 if (!STI.getFeatureBits().test(FeatureSupportsXNACK)) in AMDGPUTargetID()
710 if (!STI.getFeatureBits().test(FeatureSupportsSRAMECC)) in AMDGPUTargetID()
798 auto TargetTriple = STI.getTargetTriple(); in toString()
799 auto Version = getIsaVersion(STI.getCPU()); in toString()
811 Processor = STI.getCPU().str(); in toString()
818 if (STI.getTargetTriple().getOS() == Triple::AMDHSA) { in toString()
837 unsigned getWavefrontSize(const MCSubtargetInfo *STI) { in getWavefrontSize() argument
838 if (STI->getFeatureBits().test(FeatureWavefrontSize16)) in getWavefrontSize()
840 if (STI->getFeatureBits().test(FeatureWavefrontSize32)) in getWavefrontSize()
846 unsigned getLocalMemorySize(const MCSubtargetInfo *STI) { in getLocalMemorySize() argument
848 if (STI->getFeatureBits().test(FeatureLocalMemorySize32768)) in getLocalMemorySize()
850 if (STI->getFeatureBits().test(FeatureLocalMemorySize65536)) in getLocalMemorySize()
856 if (isGFX10Plus(*STI) && !STI->getFeatureBits().test(FeatureCuMode)) in getLocalMemorySize()
862 unsigned getAddressableLocalMemorySize(const MCSubtargetInfo *STI) { in getAddressableLocalMemorySize() argument
863 if (STI->getFeatureBits().test(FeatureLocalMemorySize32768)) in getAddressableLocalMemorySize()
865 if (STI->getFeatureBits().test(FeatureLocalMemorySize65536)) in getAddressableLocalMemorySize()
870 unsigned getEUsPerCU(const MCSubtargetInfo *STI) { in getEUsPerCU() argument
874 if (isGFX10Plus(*STI) && STI->getFeatureBits().test(FeatureCuMode)) in getEUsPerCU()
881 unsigned getMaxWorkGroupsPerCU(const MCSubtargetInfo *STI, in getMaxWorkGroupsPerCU() argument
884 if (STI->getTargetTriple().getArch() != Triple::amdgcn) in getMaxWorkGroupsPerCU()
886 unsigned MaxWaves = getMaxWavesPerEU(STI) * getEUsPerCU(STI); in getMaxWorkGroupsPerCU()
887 unsigned N = getWavesPerWorkGroup(STI, FlatWorkGroupSize); in getMaxWorkGroupsPerCU()
894 if (isGFX10Plus(*STI) && !STI->getFeatureBits().test(FeatureCuMode)) in getMaxWorkGroupsPerCU()
900 unsigned getMinWavesPerEU(const MCSubtargetInfo *STI) { in getMinWavesPerEU() argument
904 unsigned getMaxWavesPerEU(const MCSubtargetInfo *STI) { in getMaxWavesPerEU() argument
906 if (isGFX90A(*STI)) in getMaxWavesPerEU()
908 if (!isGFX10Plus(*STI)) in getMaxWavesPerEU()
910 return hasGFX10_3Insts(*STI) ? 16 : 20; in getMaxWavesPerEU()
913 unsigned getWavesPerEUForWorkGroup(const MCSubtargetInfo *STI, in getWavesPerEUForWorkGroup() argument
915 return divideCeil(getWavesPerWorkGroup(STI, FlatWorkGroupSize), in getWavesPerEUForWorkGroup()
916 getEUsPerCU(STI)); in getWavesPerEUForWorkGroup()
919 unsigned getMinFlatWorkGroupSize(const MCSubtargetInfo *STI) { in getMinFlatWorkGroupSize() argument
923 unsigned getMaxFlatWorkGroupSize(const MCSubtargetInfo *STI) { in getMaxFlatWorkGroupSize() argument
928 unsigned getWavesPerWorkGroup(const MCSubtargetInfo *STI, in getWavesPerWorkGroup() argument
930 return divideCeil(FlatWorkGroupSize, getWavefrontSize(STI)); in getWavesPerWorkGroup()
933 unsigned getSGPRAllocGranule(const MCSubtargetInfo *STI) { in getSGPRAllocGranule() argument
934 IsaVersion Version = getIsaVersion(STI->getCPU()); in getSGPRAllocGranule()
936 return getAddressableNumSGPRs(STI); in getSGPRAllocGranule()
942 unsigned getSGPREncodingGranule(const MCSubtargetInfo *STI) { in getSGPREncodingGranule() argument
946 unsigned getTotalNumSGPRs(const MCSubtargetInfo *STI) { in getTotalNumSGPRs() argument
947 IsaVersion Version = getIsaVersion(STI->getCPU()); in getTotalNumSGPRs()
953 unsigned getAddressableNumSGPRs(const MCSubtargetInfo *STI) { in getAddressableNumSGPRs() argument
954 if (STI->getFeatureBits().test(FeatureSGPRInitBug)) in getAddressableNumSGPRs()
957 IsaVersion Version = getIsaVersion(STI->getCPU()); in getAddressableNumSGPRs()
965 unsigned getMinNumSGPRs(const MCSubtargetInfo *STI, unsigned WavesPerEU) { in getMinNumSGPRs() argument
968 IsaVersion Version = getIsaVersion(STI->getCPU()); in getMinNumSGPRs()
972 if (WavesPerEU >= getMaxWavesPerEU(STI)) in getMinNumSGPRs()
975 unsigned MinNumSGPRs = getTotalNumSGPRs(STI) / (WavesPerEU + 1); in getMinNumSGPRs()
976 if (STI->getFeatureBits().test(FeatureTrapHandler)) in getMinNumSGPRs()
978 MinNumSGPRs = alignDown(MinNumSGPRs, getSGPRAllocGranule(STI)) + 1; in getMinNumSGPRs()
979 return std::min(MinNumSGPRs, getAddressableNumSGPRs(STI)); in getMinNumSGPRs()
982 unsigned getMaxNumSGPRs(const MCSubtargetInfo *STI, unsigned WavesPerEU, in getMaxNumSGPRs() argument
986 unsigned AddressableNumSGPRs = getAddressableNumSGPRs(STI); in getMaxNumSGPRs()
987 IsaVersion Version = getIsaVersion(STI->getCPU()); in getMaxNumSGPRs()
992 unsigned MaxNumSGPRs = getTotalNumSGPRs(STI) / WavesPerEU; in getMaxNumSGPRs()
993 if (STI->getFeatureBits().test(FeatureTrapHandler)) in getMaxNumSGPRs()
995 MaxNumSGPRs = alignDown(MaxNumSGPRs, getSGPRAllocGranule(STI)); in getMaxNumSGPRs()
999 unsigned getNumExtraSGPRs(const MCSubtargetInfo *STI, bool VCCUsed, in getNumExtraSGPRs() argument
1005 IsaVersion Version = getIsaVersion(STI->getCPU()); in getNumExtraSGPRs()
1017 STI->getFeatureBits().test(AMDGPU::FeatureArchitectedFlatScratch)) in getNumExtraSGPRs()
1024 unsigned getNumExtraSGPRs(const MCSubtargetInfo *STI, bool VCCUsed, in getNumExtraSGPRs() argument
1026 return getNumExtraSGPRs(STI, VCCUsed, FlatScrUsed, in getNumExtraSGPRs()
1027 STI->getFeatureBits().test(AMDGPU::FeatureXNACK)); in getNumExtraSGPRs()
1030 unsigned getNumSGPRBlocks(const MCSubtargetInfo *STI, unsigned NumSGPRs) { in getNumSGPRBlocks() argument
1031 NumSGPRs = alignTo(std::max(1u, NumSGPRs), getSGPREncodingGranule(STI)); in getNumSGPRBlocks()
1033 return NumSGPRs / getSGPREncodingGranule(STI) - 1; in getNumSGPRBlocks()
1036 unsigned getVGPRAllocGranule(const MCSubtargetInfo *STI, in getVGPRAllocGranule() argument
1038 if (STI->getFeatureBits().test(FeatureGFX90AInsts)) in getVGPRAllocGranule()
1043 STI->getFeatureBits().test(FeatureWavefrontSize32); in getVGPRAllocGranule()
1045 if (STI->getFeatureBits().test(FeatureGFX11FullVGPRs)) in getVGPRAllocGranule()
1048 if (hasGFX10_3Insts(*STI)) in getVGPRAllocGranule()
1054 unsigned getVGPREncodingGranule(const MCSubtargetInfo *STI, in getVGPREncodingGranule() argument
1056 if (STI->getFeatureBits().test(FeatureGFX90AInsts)) in getVGPREncodingGranule()
1061 STI->getFeatureBits().test(FeatureWavefrontSize32); in getVGPREncodingGranule()
1066 unsigned getTotalNumVGPRs(const MCSubtargetInfo *STI) { in getTotalNumVGPRs() argument
1067 if (STI->getFeatureBits().test(FeatureGFX90AInsts)) in getTotalNumVGPRs()
1069 if (!isGFX10Plus(*STI)) in getTotalNumVGPRs()
1071 bool IsWave32 = STI->getFeatureBits().test(FeatureWavefrontSize32); in getTotalNumVGPRs()
1072 if (STI->getFeatureBits().test(FeatureGFX11FullVGPRs)) in getTotalNumVGPRs()
1077 unsigned getAddressableNumVGPRs(const MCSubtargetInfo *STI) { in getAddressableNumVGPRs() argument
1078 if (STI->getFeatureBits().test(FeatureGFX90AInsts)) in getAddressableNumVGPRs()
1083 unsigned getNumWavesPerEUWithNumVGPRs(const MCSubtargetInfo *STI, in getNumWavesPerEUWithNumVGPRs() argument
1085 unsigned MaxWaves = getMaxWavesPerEU(STI); in getNumWavesPerEUWithNumVGPRs()
1086 unsigned Granule = getVGPRAllocGranule(STI); in getNumWavesPerEUWithNumVGPRs()
1090 return std::min(std::max(getTotalNumVGPRs(STI) / RoundedRegs, 1u), MaxWaves); in getNumWavesPerEUWithNumVGPRs()
1093 unsigned getMinNumVGPRs(const MCSubtargetInfo *STI, unsigned WavesPerEU) { in getMinNumVGPRs() argument
1096 unsigned MaxWavesPerEU = getMaxWavesPerEU(STI); in getMinNumVGPRs()
1100 unsigned TotNumVGPRs = getTotalNumVGPRs(STI); in getMinNumVGPRs()
1101 unsigned AddrsableNumVGPRs = getAddressableNumVGPRs(STI); in getMinNumVGPRs()
1102 unsigned Granule = getVGPRAllocGranule(STI); in getMinNumVGPRs()
1108 unsigned MinWavesPerEU = getNumWavesPerEUWithNumVGPRs(STI, AddrsableNumVGPRs); in getMinNumVGPRs()
1110 return getMinNumVGPRs(STI, MinWavesPerEU); in getMinNumVGPRs()
1117 unsigned getMaxNumVGPRs(const MCSubtargetInfo *STI, unsigned WavesPerEU) { in getMaxNumVGPRs() argument
1120 unsigned MaxNumVGPRs = alignDown(getTotalNumVGPRs(STI) / WavesPerEU, in getMaxNumVGPRs()
1121 getVGPRAllocGranule(STI)); in getMaxNumVGPRs()
1122 unsigned AddressableNumVGPRs = getAddressableNumVGPRs(STI); in getMaxNumVGPRs()
1126 unsigned getNumVGPRBlocks(const MCSubtargetInfo *STI, unsigned NumVGPRs, in getNumVGPRBlocks() argument
1129 getVGPREncodingGranule(STI, EnableWavefrontSize32)); in getNumVGPRBlocks()
1131 return NumVGPRs / getVGPREncodingGranule(STI, EnableWavefrontSize32) - 1; in getNumVGPRBlocks()
1137 const MCSubtargetInfo *STI) { in initDefaultAMDKernelCodeT() argument
1138 IsaVersion Version = getIsaVersion(STI->getCPU()); in initDefaultAMDKernelCodeT()
1162 if (STI->getFeatureBits().test(FeatureWavefrontSize32)) { in initDefaultAMDKernelCodeT()
1167 S_00B848_WGP_MODE(STI->getFeatureBits().test(FeatureCuMode) ? 0 : 1) | in initDefaultAMDKernelCodeT()
1173 const MCSubtargetInfo *STI) { in getDefaultAmdhsaKernelDescriptor() argument
1174 IsaVersion Version = getIsaVersion(STI->getCPU()); in getDefaultAmdhsaKernelDescriptor()
1198 STI->getFeatureBits().test(FeatureWavefrontSize32) ? 1 : 0); in getDefaultAmdhsaKernelDescriptor()
1201 STI->getFeatureBits().test(FeatureCuMode) ? 0 : 1); in getDefaultAmdhsaKernelDescriptor()
1205 if (AMDGPU::isGFX90A(*STI)) { in getDefaultAmdhsaKernelDescriptor()
1208 STI->getFeatureBits().test(FeatureTgSplit) ? 1 : 0); in getDefaultAmdhsaKernelDescriptor()
1513 const MCSubtargetInfo &STI) { in getDefaultCustomOperandEncoding() argument
1517 if (Op.isSupported(STI)) in getDefaultCustomOperandEncoding()
1526 const MCSubtargetInfo &STI) { in isSymbolicCustomOperandEncoding() argument
1531 if (!Op.isSupported(STI)) in isSymbolicCustomOperandEncoding()
1545 const MCSubtargetInfo &STI) { in decodeCustomOperand() argument
1548 if (Op.isSupported(STI)) { in decodeCustomOperand()
1569 const MCSubtargetInfo &STI) { in encodeCustomOperand() argument
1574 if (!Op.isSupported(STI)) { in encodeCustomOperand()
1594 int getDefaultDepCtrEncoding(const MCSubtargetInfo &STI) { in getDefaultDepCtrEncoding() argument
1597 Default = getDefaultCustomOperandEncoding(DepCtrInfo, DEP_CTR_SIZE, STI); in getDefaultDepCtrEncoding()
1602 const MCSubtargetInfo &STI) { in isSymbolicDepCtrEncoding() argument
1604 HasNonDefaultVal, STI); in isSymbolicDepCtrEncoding()
1608 bool &IsDefault, const MCSubtargetInfo &STI) { in decodeDepCtr() argument
1610 IsDefault, STI); in decodeDepCtr()
1614 const MCSubtargetInfo &STI) { in encodeDepCtr() argument
1616 STI); in encodeDepCtr()
1663 int64_t getHwregId(const StringRef Name, const MCSubtargetInfo &STI) { in getHwregId() argument
1664 int Idx = getOprIdx<const MCSubtargetInfo &>(Name, Opr, OPR_SIZE, STI); in getHwregId()
1686 StringRef getHwreg(unsigned Id, const MCSubtargetInfo &STI) { in getHwreg() argument
1687 int Idx = getOprIdx<const MCSubtargetInfo &>(Id, Opr, OPR_SIZE, STI); in getHwreg()
1755 bool isSupportedTgtId(unsigned Id, const MCSubtargetInfo &STI) { in isSupportedTgtId() argument
1758 return !isGFX11Plus(STI); in isSupportedTgtId()
1761 return isGFX10Plus(STI); in isSupportedTgtId()
1764 return isGFX11Plus(STI); in isSupportedTgtId()
1767 return !isGFX11Plus(STI); in isSupportedTgtId()
1793 static StringLiteral const *getNfmtLookupTable(const MCSubtargetInfo &STI) { in getNfmtLookupTable() argument
1794 if (isSI(STI) || isCI(STI)) in getNfmtLookupTable()
1796 if (isVI(STI) || isGFX9(STI)) in getNfmtLookupTable()
1801 int64_t getNfmt(const StringRef Name, const MCSubtargetInfo &STI) { in getNfmt() argument
1802 auto lookupTable = getNfmtLookupTable(STI); in getNfmt()
1810 StringRef getNfmtName(unsigned Id, const MCSubtargetInfo &STI) { in getNfmtName() argument
1812 return getNfmtLookupTable(STI)[Id]; in getNfmtName()
1815 bool isValidDfmtNfmt(unsigned Id, const MCSubtargetInfo &STI) { in isValidDfmtNfmt() argument
1819 return isValidNfmt(Nfmt, STI); in isValidDfmtNfmt()
1822 bool isValidNfmt(unsigned Id, const MCSubtargetInfo &STI) { in isValidNfmt() argument
1823 return !getNfmtName(Id, STI).empty(); in isValidNfmt()
1835 int64_t getUnifiedFormat(const StringRef Name, const MCSubtargetInfo &STI) { in getUnifiedFormat() argument
1836 if (isGFX11Plus(STI)) { in getUnifiedFormat()
1850 StringRef getUnifiedFormatName(unsigned Id, const MCSubtargetInfo &STI) { in getUnifiedFormatName() argument
1851 if(isValidUnifiedFormat(Id, STI)) in getUnifiedFormatName()
1852 return isGFX10(STI) ? UfmtSymbolicGFX10[Id] : UfmtSymbolicGFX11[Id]; in getUnifiedFormatName()
1856 bool isValidUnifiedFormat(unsigned Id, const MCSubtargetInfo &STI) { in isValidUnifiedFormat() argument
1857 return isGFX10(STI) ? Id <= UfmtGFX10::UFMT_LAST : Id <= UfmtGFX11::UFMT_LAST; in isValidUnifiedFormat()
1861 const MCSubtargetInfo &STI) { in convertDfmtNfmt2Ufmt() argument
1863 if (isGFX11Plus(STI)) { in convertDfmtNfmt2Ufmt()
1877 bool isValidFormatEncoding(unsigned Val, const MCSubtargetInfo &STI) { in isValidFormatEncoding() argument
1878 return isGFX10Plus(STI) ? (Val <= UFMT_MAX) : (Val <= DFMT_NFMT_MAX); in isValidFormatEncoding()
1881 unsigned getDefaultFormatEncoding(const MCSubtargetInfo &STI) { in getDefaultFormatEncoding() argument
1882 if (isGFX10Plus(STI)) in getDefaultFormatEncoding()
1895 static uint64_t getMsgIdMask(const MCSubtargetInfo &STI) { in getMsgIdMask() argument
1896 return isGFX11Plus(STI) ? ID_MASK_GFX11Plus_ : ID_MASK_PreGFX11_; in getMsgIdMask()
1899 int64_t getMsgId(const StringRef Name, const MCSubtargetInfo &STI) { in getMsgId() argument
1900 int Idx = getOprIdx<const MCSubtargetInfo &>(Name, Msg, MSG_SIZE, STI); in getMsgId()
1904 bool isValidMsgId(int64_t MsgId, const MCSubtargetInfo &STI) { in isValidMsgId() argument
1905 return (MsgId & ~(getMsgIdMask(STI))) == 0; in isValidMsgId()
1908 StringRef getMsgName(int64_t MsgId, const MCSubtargetInfo &STI) { in getMsgName() argument
1909 int Idx = getOprIdx<const MCSubtargetInfo &>(MsgId, Msg, MSG_SIZE, STI); in getMsgName()
1925 bool isValidMsgOp(int64_t MsgId, int64_t OpId, const MCSubtargetInfo &STI, in isValidMsgOp() argument
1927 assert(isValidMsgId(MsgId, STI)); in isValidMsgOp()
1934 if (!isGFX11Plus(STI)) { in isValidMsgOp()
1946 const MCSubtargetInfo &STI) { in getMsgOpName() argument
1947 assert(msgRequiresOp(MsgId, STI)); in getMsgOpName()
1952 const MCSubtargetInfo &STI, bool Strict) { in isValidMsgStream() argument
1953 assert(isValidMsgOp(MsgId, OpId, STI, Strict)); in isValidMsgStream()
1958 if (!isGFX11Plus(STI)) { in isValidMsgStream()
1971 bool msgRequiresOp(int64_t MsgId, const MCSubtargetInfo &STI) { in msgRequiresOp() argument
1973 (!isGFX11Plus(STI) && in msgRequiresOp()
1978 const MCSubtargetInfo &STI) { in msgSupportsStream() argument
1979 return !isGFX11Plus(STI) && in msgSupportsStream()
1985 uint16_t &StreamId, const MCSubtargetInfo &STI) { in decodeMsg() argument
1986 MsgId = Val & getMsgIdMask(STI); in decodeMsg()
1987 if (isGFX11Plus(STI)) { in decodeMsg()
2088 bool hasXNACK(const MCSubtargetInfo &STI) { in hasXNACK() argument
2089 return STI.hasFeature(AMDGPU::FeatureXNACK); in hasXNACK()
2092 bool hasSRAMECC(const MCSubtargetInfo &STI) { in hasSRAMECC() argument
2093 return STI.hasFeature(AMDGPU::FeatureSRAMECC); in hasSRAMECC()
2096 bool hasMIMG_R128(const MCSubtargetInfo &STI) { in hasMIMG_R128() argument
2097 return STI.hasFeature(AMDGPU::FeatureMIMG_R128) && !STI.hasFeature(AMDGPU::FeatureR128A16); in hasMIMG_R128()
2100 bool hasA16(const MCSubtargetInfo &STI) { in hasA16() argument
2101 return STI.hasFeature(AMDGPU::FeatureA16); in hasA16()
2104 bool hasG16(const MCSubtargetInfo &STI) { in hasG16() argument
2105 return STI.hasFeature(AMDGPU::FeatureG16); in hasG16()
2108 bool hasPackedD16(const MCSubtargetInfo &STI) { in hasPackedD16() argument
2109 return !STI.hasFeature(AMDGPU::FeatureUnpackedD16VMem) && !isCI(STI) && in hasPackedD16()
2110 !isSI(STI); in hasPackedD16()
2113 bool hasGDS(const MCSubtargetInfo &STI) { in hasGDS() argument
2114 return STI.hasFeature(AMDGPU::FeatureGDS); in hasGDS()
2117 unsigned getNSAMaxSize(const MCSubtargetInfo &STI, bool HasSampler) { in getNSAMaxSize() argument
2118 auto Version = getIsaVersion(STI.getCPU()); in getNSAMaxSize()
2128 unsigned getMaxNumUserSGPRs(const MCSubtargetInfo &STI) { return 16; } in getMaxNumUserSGPRs() argument
2130 bool isSI(const MCSubtargetInfo &STI) { in isSI() argument
2131 return STI.hasFeature(AMDGPU::FeatureSouthernIslands); in isSI()
2134 bool isCI(const MCSubtargetInfo &STI) { in isCI() argument
2135 return STI.hasFeature(AMDGPU::FeatureSeaIslands); in isCI()
2138 bool isVI(const MCSubtargetInfo &STI) { in isVI() argument
2139 return STI.hasFeature(AMDGPU::FeatureVolcanicIslands); in isVI()
2142 bool isGFX9(const MCSubtargetInfo &STI) { in isGFX9() argument
2143 return STI.hasFeature(AMDGPU::FeatureGFX9); in isGFX9()
2146 bool isGFX9_GFX10(const MCSubtargetInfo &STI) { in isGFX9_GFX10() argument
2147 return isGFX9(STI) || isGFX10(STI); in isGFX9_GFX10()
2150 bool isGFX9_GFX10_GFX11(const MCSubtargetInfo &STI) { in isGFX9_GFX10_GFX11() argument
2151 return isGFX9(STI) || isGFX10(STI) || isGFX11(STI); in isGFX9_GFX10_GFX11()
2154 bool isGFX8_GFX9_GFX10(const MCSubtargetInfo &STI) { in isGFX8_GFX9_GFX10() argument
2155 return isVI(STI) || isGFX9(STI) || isGFX10(STI); in isGFX8_GFX9_GFX10()
2158 bool isGFX8Plus(const MCSubtargetInfo &STI) { in isGFX8Plus() argument
2159 return isVI(STI) || isGFX9Plus(STI); in isGFX8Plus()
2162 bool isGFX9Plus(const MCSubtargetInfo &STI) { in isGFX9Plus() argument
2163 return isGFX9(STI) || isGFX10Plus(STI); in isGFX9Plus()
2166 bool isGFX10(const MCSubtargetInfo &STI) { in isGFX10() argument
2167 return STI.hasFeature(AMDGPU::FeatureGFX10); in isGFX10()
2170 bool isGFX10_GFX11(const MCSubtargetInfo &STI) { in isGFX10_GFX11() argument
2171 return isGFX10(STI) || isGFX11(STI); in isGFX10_GFX11()
2174 bool isGFX10Plus(const MCSubtargetInfo &STI) { in isGFX10Plus() argument
2175 return isGFX10(STI) || isGFX11Plus(STI); in isGFX10Plus()
2178 bool isGFX11(const MCSubtargetInfo &STI) { in isGFX11() argument
2179 return STI.hasFeature(AMDGPU::FeatureGFX11); in isGFX11()
2182 bool isGFX11Plus(const MCSubtargetInfo &STI) { in isGFX11Plus() argument
2183 return isGFX11(STI) || isGFX12Plus(STI); in isGFX11Plus()
2186 bool isGFX12(const MCSubtargetInfo &STI) { in isGFX12() argument
2187 return STI.getFeatureBits()[AMDGPU::FeatureGFX12]; in isGFX12()
2190 bool isGFX12Plus(const MCSubtargetInfo &STI) { return isGFX12(STI); } in isGFX12Plus() argument
2192 bool isNotGFX12Plus(const MCSubtargetInfo &STI) { return !isGFX12Plus(STI); } in isNotGFX12Plus() argument
2194 bool isNotGFX11Plus(const MCSubtargetInfo &STI) { in isNotGFX11Plus() argument
2195 return !isGFX11Plus(STI); in isNotGFX11Plus()
2198 bool isNotGFX10Plus(const MCSubtargetInfo &STI) { in isNotGFX10Plus() argument
2199 return isSI(STI) || isCI(STI) || isVI(STI) || isGFX9(STI); in isNotGFX10Plus()
2202 bool isGFX10Before1030(const MCSubtargetInfo &STI) { in isGFX10Before1030() argument
2203 return isGFX10(STI) && !AMDGPU::isGFX10_BEncoding(STI); in isGFX10Before1030()
2206 bool isGCN3Encoding(const MCSubtargetInfo &STI) { in isGCN3Encoding() argument
2207 return STI.hasFeature(AMDGPU::FeatureGCN3Encoding); in isGCN3Encoding()
2210 bool isGFX10_AEncoding(const MCSubtargetInfo &STI) { in isGFX10_AEncoding() argument
2211 return STI.hasFeature(AMDGPU::FeatureGFX10_AEncoding); in isGFX10_AEncoding()
2214 bool isGFX10_BEncoding(const MCSubtargetInfo &STI) { in isGFX10_BEncoding() argument
2215 return STI.hasFeature(AMDGPU::FeatureGFX10_BEncoding); in isGFX10_BEncoding()
2218 bool hasGFX10_3Insts(const MCSubtargetInfo &STI) { in hasGFX10_3Insts() argument
2219 return STI.hasFeature(AMDGPU::FeatureGFX10_3Insts); in hasGFX10_3Insts()
2222 bool isGFX10_3_GFX11(const MCSubtargetInfo &STI) { in isGFX10_3_GFX11() argument
2223 return isGFX10_BEncoding(STI) && !isGFX12Plus(STI); in isGFX10_3_GFX11()
2226 bool isGFX90A(const MCSubtargetInfo &STI) { in isGFX90A() argument
2227 return STI.hasFeature(AMDGPU::FeatureGFX90AInsts); in isGFX90A()
2230 bool isGFX940(const MCSubtargetInfo &STI) { in isGFX940() argument
2231 return STI.hasFeature(AMDGPU::FeatureGFX940Insts); in isGFX940()
2234 bool hasArchitectedFlatScratch(const MCSubtargetInfo &STI) { in hasArchitectedFlatScratch() argument
2235 return STI.hasFeature(AMDGPU::FeatureArchitectedFlatScratch); in hasArchitectedFlatScratch()
2238 bool hasMAIInsts(const MCSubtargetInfo &STI) { in hasMAIInsts() argument
2239 return STI.hasFeature(AMDGPU::FeatureMAIInsts); in hasMAIInsts()
2242 bool hasVOPD(const MCSubtargetInfo &STI) { in hasVOPD() argument
2243 return STI.hasFeature(AMDGPU::FeatureVOPD); in hasVOPD()
2246 bool hasDPPSrc1SGPR(const MCSubtargetInfo &STI) { in hasDPPSrc1SGPR() argument
2247 return STI.hasFeature(AMDGPU::FeatureDPPSrc1SGPR); in hasDPPSrc1SGPR()
2250 unsigned hasKernargPreload(const MCSubtargetInfo &STI) { in hasKernargPreload() argument
2251 return STI.hasFeature(AMDGPU::FeatureKernargPreload); in hasKernargPreload()
2317 assert(!isSI(STI)); \
2318 case node: return isCI(STI) ? node##_ci : node##_vi;
2321 case node: return isGFX9Plus(STI) ? node##_gfx9plus : node##_vi;
2324 case node: return isGFX11Plus(STI) ? node##_gfx11plus : node##_gfxpre11;
2327 case node: return isGFX11Plus(STI) ? result##_gfx11plus : result##_gfxpre11;
2329 unsigned getMCReg(unsigned Reg, const MCSubtargetInfo &STI) { in getMCReg() argument
2330 if (STI.getTargetTriple().getArch() == Triple::r600) in getMCReg()
2908 const MCSubtargetInfo &STI) { in getGcnBufferFormatInfo() argument
2909 return isGFX11Plus(STI) in getGcnBufferFormatInfo()
2912 : isGFX10(STI) ? getGfx10BufferFormatInfo(BitsPerComp, in getGcnBufferFormatInfo()
2919 const MCSubtargetInfo &STI) { in getGcnBufferFormatInfo() argument
2920 return isGFX11Plus(STI) ? getGfx11PlusBufferFormatInfo(Format) in getGcnBufferFormatInfo()
2921 : isGFX10(STI) ? getGfx10BufferFormatInfo(Format) in getGcnBufferFormatInfo()