1//===- IntrinsicsNVVM.td - Defines NVVM intrinsics ---------*- tablegen -*-===// 2// 3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4// See https://llvm.org/LICENSE.txt for license information. 5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6// 7//===----------------------------------------------------------------------===// 8// 9// This file defines all of the NVVM-specific intrinsics for use with NVPTX. 10// 11//===----------------------------------------------------------------------===// 12 13// The following intrinsics were once defined here, but are now auto-upgraded 14// to target-generic LLVM intrinsics. 15// 16// * llvm.nvvm.brev32 --> llvm.bitreverse.i32 17// * llvm.nvvm.brev64 --> llvm.bitreverse.i64 18// * llvm.nvvm.clz.i --> llvm.ctlz.i32 19// * llvm.nvvm.clz.ll --> trunc i64 llvm.ctlz.i64(x) to i32 20// * llvm.nvvm.popc.i --> llvm.ctpop.i32 21// * llvm.nvvm.popc.ll --> trunc i64 llvm.ctpop.i64 to i32 22// * llvm.nvvm.abs.i --> select(x >= -x, x, -x) 23// * llvm.nvvm.abs.ll --> ibid. 24// * llvm.nvvm.max.i --> select(x sge y, x, y) 25// * llvm.nvvm.max.ll --> ibid. 26// * llvm.nvvm.max.ui --> select(x uge y, x, y) 27// * llvm.nvvm.max.ull --> ibid. 28// * llvm.nvvm.max.i --> select(x sle y, x, y) 29// * llvm.nvvm.max.ll --> ibid. 30// * llvm.nvvm.max.ui --> select(x ule y, x, y) 31// * llvm.nvvm.max.ull --> ibid. 32// * llvm.nvvm.h2f --> llvm.convert.to.fp16.f32 33 34def llvm_global_ptr_ty : LLVMQualPointerType<1>; // (global)ptr 35def llvm_shared_ptr_ty : LLVMQualPointerType<3>; // (shared)ptr 36 37// 38// MISC 39// 40 41// Helper class that represents a 'fragment' of an NVPTX *MMA instruction. 42// Geom: m<M>n<N>k<K>. E.g. m8n32k16 43// Frag: [a|b|c|d] ([x1|x2|x4] for ldmatrix) 44// PtxEltType: PTX type for the element. 45class WMMA_REGS<string Geom, string Frag, string PtxEltType> { 46 string geom = Geom; 47 string frag = Frag; 48 string ptx_elt_type = PtxEltType; 49 string gft = Geom#":"#Frag#":"#ptx_elt_type; 50 string ft = frag#":"#ptx_elt_type; 51 list<LLVMType> regs = !cond( 52 // mma fp ops use smaller fragments than wmma fp ops 53 !eq(gft,"m8n8k4:a:f16") : !listsplat(llvm_v2f16_ty, 2), 54 !eq(gft,"m8n8k4:b:f16") : !listsplat(llvm_v2f16_ty, 2), 55 !eq(gft,"m16n8k8:a:f16") : !listsplat(llvm_v2f16_ty, 2), 56 !eq(gft,"m16n8k8:b:f16") : [llvm_v2f16_ty], 57 !eq(gft,"m16n8k8:c:f16") : !listsplat(llvm_v2f16_ty, 2), 58 !eq(gft,"m16n8k8:d:f16") : !listsplat(llvm_v2f16_ty, 2), 59 !eq(gft,"m16n8k8:c:f32") : !listsplat(llvm_float_ty, 4), 60 !eq(gft,"m16n8k8:d:f32") : !listsplat(llvm_float_ty, 4), 61 !eq(gft,"m16n8k16:a:f16") : !listsplat(llvm_v2f16_ty, 4), 62 !eq(gft,"m16n8k16:b:f16") : !listsplat(llvm_v2f16_ty, 2), 63 !eq(gft,"m16n8k16:c:f16") : !listsplat(llvm_v2f16_ty, 2), 64 !eq(gft,"m16n8k16:d:f16") : !listsplat(llvm_v2f16_ty, 2), 65 !eq(gft,"m16n8k16:c:f32") : !listsplat(llvm_float_ty, 4), 66 !eq(gft,"m16n8k16:d:f32") : !listsplat(llvm_float_ty, 4), 67 !eq(gft,"m16n8k4:c:f32") : !listsplat(llvm_float_ty, 4), 68 !eq(gft,"m16n8k4:d:f32") : !listsplat(llvm_float_ty, 4), 69 70 // wmma fp16 -> fp16/fp32 @ m16n16k16/m8n32k16/m32n8k16 71 // All other supported geometries use the same fragment format for f32 and 72 // f16, so we only need to consider {fragment, type}. 73 !eq(ft,"a:f16") : !listsplat(llvm_v2f16_ty, 8), 74 !eq(ft,"b:f16") : !listsplat(llvm_v2f16_ty, 8), 75 !eq(ft,"c:f16") : !listsplat(llvm_v2f16_ty, 4), 76 !eq(ft,"d:f16") : !listsplat(llvm_v2f16_ty, 4), 77 !eq(ft,"c:f32") : !listsplat(llvm_float_ty, 8), 78 !eq(ft,"d:f32") : !listsplat(llvm_float_ty, 8), 79 80 // wmma tf32 -> s32 @ m16n16k8 81 !eq(gft,"m16n16k8:a:tf32") : !listsplat(llvm_i32_ty, 4), 82 !eq(gft,"m16n16k8:b:tf32") : !listsplat(llvm_i32_ty, 4), 83 84 // mma tf32 -> s32 @ m16n16k8/m16n8k8 85 !eq(gft,"m16n8k4:a:tf32") : !listsplat(llvm_i32_ty, 2), 86 !eq(gft,"m16n8k4:b:tf32") : [llvm_i32_ty], 87 !eq(gft,"m16n8k8:a:tf32") : !listsplat(llvm_i32_ty, 4), 88 !eq(gft,"m16n8k8:b:tf32") : !listsplat(llvm_i32_ty, 2), 89 90 !eq(gft,"m8n8k4:a:f64") : [llvm_double_ty], 91 !eq(gft,"m8n8k4:b:f64") : [llvm_double_ty], 92 !eq(gft,"m8n8k4:c:f64") : !listsplat(llvm_double_ty, 2), 93 !eq(gft,"m8n8k4:d:f64") : !listsplat(llvm_double_ty, 2), 94 95 // wmma bf16 -> s32 @ m16n16k16/m8n32k16/m32n8k16 96 !eq(gft,"m16n16k16:a:bf16") : !listsplat(llvm_i32_ty, 4), 97 !eq(gft,"m16n16k16:b:bf16") : !listsplat(llvm_i32_ty, 4), 98 !eq(gft,"m8n32k16:a:bf16") : !listsplat(llvm_i32_ty, 2), 99 !eq(gft,"m8n32k16:b:bf16") : !listsplat(llvm_i32_ty, 8), 100 !eq(gft,"m32n8k16:a:bf16") : !listsplat(llvm_i32_ty, 8), 101 !eq(gft,"m32n8k16:b:bf16") : !listsplat(llvm_i32_ty, 2), 102 103 // mma bf16 -> s32 @ m16n8k16/m16n8k8 104 !eq(gft,"m16n8k16:a:bf16") : !listsplat(llvm_i32_ty, 4), 105 !eq(gft,"m16n8k16:b:bf16") : !listsplat(llvm_i32_ty, 2), 106 !eq(gft,"m16n8k8:a:bf16") : !listsplat(llvm_i32_ty, 2), 107 !eq(gft,"m16n8k8:b:bf16") : [llvm_i32_ty], 108 109 // wmma u8/s8 -> s32 @ m16n16k16/m8n32k16/m32n8k16 110 !eq(gft,"m16n16k16:a:u8") : !listsplat(llvm_i32_ty, 2), 111 !eq(gft,"m16n16k16:a:s8") : !listsplat(llvm_i32_ty, 2), 112 !eq(gft,"m16n16k16:b:u8") : !listsplat(llvm_i32_ty, 2), 113 !eq(gft,"m16n16k16:b:s8") : !listsplat(llvm_i32_ty, 2), 114 !eq(gft,"m16n16k16:c:s32") : !listsplat(llvm_i32_ty, 8), 115 !eq(gft,"m16n16k16:d:s32") : !listsplat(llvm_i32_ty, 8), 116 117 !eq(gft,"m8n32k16:a:u8") : [llvm_i32_ty], 118 !eq(gft,"m8n32k16:a:s8") : [llvm_i32_ty], 119 !eq(gft,"m8n32k16:b:u8") : !listsplat(llvm_i32_ty, 4), 120 !eq(gft,"m8n32k16:b:s8") : !listsplat(llvm_i32_ty, 4), 121 !eq(gft,"m8n32k16:c:s32") : !listsplat(llvm_i32_ty, 8), 122 !eq(gft,"m8n32k16:d:s32") : !listsplat(llvm_i32_ty, 8), 123 124 !eq(gft,"m32n8k16:a:u8") : !listsplat(llvm_i32_ty, 4), 125 !eq(gft,"m32n8k16:a:s8") : !listsplat(llvm_i32_ty, 4), 126 !eq(gft,"m32n8k16:b:u8") : [llvm_i32_ty], 127 !eq(gft,"m32n8k16:b:s8") : [llvm_i32_ty], 128 !eq(gft,"m32n8k16:c:s32") : !listsplat(llvm_i32_ty, 8), 129 !eq(gft,"m32n8k16:d:s32") : !listsplat(llvm_i32_ty, 8), 130 131 // mma u8/s8 -> s32 @ m8n8k16/m16n8k16/m16n8k32 132 !eq(gft,"m8n8k16:a:u8") : [llvm_i32_ty], 133 !eq(gft,"m8n8k16:a:s8") : [llvm_i32_ty], 134 !eq(gft,"m8n8k16:b:u8") : [llvm_i32_ty], 135 !eq(gft,"m8n8k16:b:s8") : [llvm_i32_ty], 136 !eq(gft,"m8n8k16:c:s32") : !listsplat(llvm_i32_ty, 2), 137 !eq(gft,"m8n8k16:d:s32") : !listsplat(llvm_i32_ty, 2), 138 139 !eq(gft,"m16n8k16:a:u8") : !listsplat(llvm_i32_ty, 2), 140 !eq(gft,"m16n8k16:a:s8") : !listsplat(llvm_i32_ty, 2), 141 !eq(gft,"m16n8k16:b:u8") : [llvm_i32_ty], 142 !eq(gft,"m16n8k16:b:s8") : [llvm_i32_ty], 143 !eq(gft,"m16n8k16:c:s32") : !listsplat(llvm_i32_ty, 4), 144 !eq(gft,"m16n8k16:d:s32") : !listsplat(llvm_i32_ty, 4), 145 146 !eq(gft,"m16n8k32:a:u8") : !listsplat(llvm_i32_ty, 4), 147 !eq(gft,"m16n8k32:a:s8") : !listsplat(llvm_i32_ty, 4), 148 !eq(gft,"m16n8k32:b:u8") : !listsplat(llvm_i32_ty, 2), 149 !eq(gft,"m16n8k32:b:s8") : !listsplat(llvm_i32_ty, 2), 150 !eq(gft,"m16n8k32:c:s32") : !listsplat(llvm_i32_ty, 4), 151 !eq(gft,"m16n8k32:d:s32") : !listsplat(llvm_i32_ty, 4), 152 153 // wmma/mma u4/s4 -> s32 @ m8n8k32 (u4/s4) 154 !eq(gft,"m8n8k32:a:u4") : [llvm_i32_ty], 155 !eq(gft,"m8n8k32:a:s4") : [llvm_i32_ty], 156 !eq(gft,"m8n8k32:b:u4") : [llvm_i32_ty], 157 !eq(gft,"m8n8k32:b:s4") : [llvm_i32_ty], 158 !eq(gft,"m8n8k32:c:s32") : !listsplat(llvm_i32_ty, 2), 159 !eq(gft,"m8n8k32:d:s32") : !listsplat(llvm_i32_ty, 2), 160 161 !eq(gft,"m16n8k32:a:u4") : !listsplat(llvm_i32_ty, 2), 162 !eq(gft,"m16n8k32:a:s4") : !listsplat(llvm_i32_ty, 2), 163 !eq(gft,"m16n8k32:b:u4") : [llvm_i32_ty], 164 !eq(gft,"m16n8k32:b:s4") : [llvm_i32_ty], 165 !eq(gft,"m16n8k32:c:s32") : !listsplat(llvm_i32_ty, 4), 166 !eq(gft,"m16n8k32:d:s32") : !listsplat(llvm_i32_ty, 4), 167 168 !eq(gft,"m16n8k64:a:u4") : !listsplat(llvm_i32_ty, 4), 169 !eq(gft,"m16n8k64:a:s4") : !listsplat(llvm_i32_ty, 4), 170 !eq(gft,"m16n8k64:b:u4") : !listsplat(llvm_i32_ty, 2), 171 !eq(gft,"m16n8k64:b:s4") : !listsplat(llvm_i32_ty, 2), 172 !eq(gft,"m16n8k64:c:s32") : !listsplat(llvm_i32_ty, 4), 173 !eq(gft,"m16n8k64:d:s32") : !listsplat(llvm_i32_ty, 4), 174 175 // wmma/mma b1 -> s32 @ m8n8k128(b1) 176 !eq(gft,"m8n8k128:a:b1") : [llvm_i32_ty], 177 !eq(gft,"m8n8k128:b:b1") : [llvm_i32_ty], 178 !eq(gft,"m8n8k128:c:s32") : !listsplat(llvm_i32_ty, 2), 179 !eq(gft,"m8n8k128:d:s32") : !listsplat(llvm_i32_ty, 2), 180 181 !eq(gft,"m16n8k128:a:b1") : !listsplat(llvm_i32_ty, 2), 182 !eq(gft,"m16n8k128:b:b1") : [llvm_i32_ty], 183 !eq(gft,"m16n8k128:c:s32") : !listsplat(llvm_i32_ty, 4), 184 !eq(gft,"m16n8k128:d:s32") : !listsplat(llvm_i32_ty, 4), 185 186 !eq(gft,"m16n8k256:a:b1") : !listsplat(llvm_i32_ty, 4), 187 !eq(gft,"m16n8k256:b:b1") : !listsplat(llvm_i32_ty, 2), 188 !eq(gft,"m16n8k256:c:s32") : !listsplat(llvm_i32_ty, 4), 189 !eq(gft,"m16n8k256:d:s32") : !listsplat(llvm_i32_ty, 4), 190 191 // ldmatrix b16 -> s32 @ m8n8 192 !eq(gft,"m8n8:x1:b16") : !listsplat(llvm_i32_ty, 1), 193 !eq(gft,"m8n8:x2:b16") : !listsplat(llvm_i32_ty, 2), 194 !eq(gft,"m8n8:x4:b16") : !listsplat(llvm_i32_ty, 4), 195 ); 196} 197 198class WMMA_NAME_LDST<string Op, WMMA_REGS Frag, string Layout, int WithStride> { 199 string intr = "llvm.nvvm.wmma." 200 # Frag.geom 201 # "." # Op 202 # "." # Frag.frag 203 # "." # Layout 204 # !if(WithStride, ".stride", "") 205 # "." # Frag.ptx_elt_type 206 ; 207 // TODO(tra): record name should ideally use the same field order as the intrinsic. 208 // E.g. string record = !subst("llvm", "int", 209 // !subst(".", "_", llvm)); 210 string record = "int_nvvm_wmma_" 211 # Frag.geom 212 # "_" # Op 213 # "_" # Frag.frag 214 # "_" # Frag.ptx_elt_type 215 # "_" # Layout 216 # !if(WithStride, "_stride", ""); 217} 218 219class MMA_SIGNATURE<WMMA_REGS A, WMMA_REGS B, WMMA_REGS C, WMMA_REGS D> { 220 list<WMMA_REGS> id_frags = !cond( 221 // FP16 ops are identified by accumulator & result type. 222 !eq(A.ptx_elt_type, "f16") : [D, C], 223 // other ops are identified by input types. 224 !ne(A.ptx_elt_type, B.ptx_elt_type): [A, B], 225 true: [A] 226 ); 227 string ret = !foldl("", id_frags, a, b, !strconcat(a, ".", b.ptx_elt_type)); 228} 229 230class WMMA_NAME<string ALayout, string BLayout, int Satfinite, string Rnd, string b1op, 231 WMMA_REGS A, WMMA_REGS B, WMMA_REGS C, WMMA_REGS D> { 232 string signature = MMA_SIGNATURE<A, B, C, D>.ret; 233 string llvm = "llvm.nvvm.wmma." 234 # A.geom 235 # ".mma" 236 # b1op 237 # "." # ALayout 238 # "." # BLayout 239 # !if(!ne(Rnd, ""), !strconcat(".", Rnd), "") 240 # signature 241 # !if(Satfinite, ".satfinite", ""); 242 243 string record = !subst(".", "_", 244 !subst("llvm.", "int_", llvm)); 245} 246 247class MMA_NAME<string ALayout, string BLayout, int Satfinite, string b1op, 248 WMMA_REGS A, WMMA_REGS B, WMMA_REGS C, WMMA_REGS D> { 249 string signature = MMA_SIGNATURE<A, B, C, D>.ret; 250 string llvm = "llvm.nvvm.mma" 251 # b1op 252 # "." # A.geom 253 # "." # ALayout 254 # "." # BLayout 255 # !if(Satfinite, ".satfinite", "") 256 # signature; 257 string record = !subst(".", "_", 258 !subst("llvm.", "int_", llvm)); 259} 260 261class LDMATRIX_NAME<WMMA_REGS Frag, int Trans> { 262 string intr = "llvm.nvvm.ldmatrix.sync.aligned" 263 # "." # Frag.geom 264 # "." # Frag.frag 265 # !if(Trans, ".trans", "") 266 # "." # Frag.ptx_elt_type 267 ; 268 string record = !subst(".", "_", 269 !subst("llvm.", "int_", intr)); 270} 271 272// Generates list of 4-tuples of WMMA_REGS representing a valid MMA op. 273// Geom: list of supported geometries. 274// TypeN: PTX type of the corresponding fragment's element. 275// TypeB and TypeD may be empty if it must match that of TypeA or TypeC. 276class MMA_OPS<list<string> Geom, list<string> TypeA, list<string> TypeB, 277 list<string> TypeC, list<string> TypeD> { 278 list<list<WMMA_REGS>> ret = 279 !foldl([]<list<WMMA_REGS>>, Geom, t1, geom, !listconcat(t1, 280 !foldl([]<list<WMMA_REGS>>, TypeA, t2, type_a, !listconcat(t2, 281 !foldl([]<list<WMMA_REGS>>, !if(!size(TypeB), TypeB, [type_a]), t3, type_b, !listconcat(t3, 282 !foldl([]<list<WMMA_REGS>>, TypeC, t4, type_c, !listconcat(t4, 283 !foldl([]<list<WMMA_REGS>>, !if(!size(TypeD), TypeD, [type_c]), t5, type_d, !listconcat(t5, 284 [[WMMA_REGS<geom, "a", type_a>, 285 WMMA_REGS<geom, "b", type_b>, 286 WMMA_REGS<geom, "c", type_c>, 287 WMMA_REGS<geom, "d", type_d>]])))))))))); 288 // Debugging aid for readable representation of the list above. 289 list<list<string>> ops = !foreach(x, ret, [x[0].gft, x[1].gft, x[2].gft, x[3].gft]); 290} 291 292class MMA_LDST_OPS<list<string> Geom, list<string> Frags, list<string> Types> { 293 list<WMMA_REGS> ret = 294 !foldl([]<WMMA_REGS>, Geom, t1, geom, !listconcat(t1, 295 !foldl([]<WMMA_REGS>, Frags, t2, frag, !listconcat(t2, 296 !foldl([]<WMMA_REGS>, Types, t3, type, !listconcat(t3, 297 [WMMA_REGS<geom, frag, type>])))))); 298 // Debugging aid for readable representation of the list above. 299 list<string> ops = !foreach(x, ret, x.gft); 300} 301 302class LDMATRIX_OPS<list<string> Geom, list<string> Frags, list<string> Types> { 303 list<WMMA_REGS> ret = 304 !foldl([]<WMMA_REGS>, Geom, t1, geom, !listconcat(t1, 305 !foldl([]<WMMA_REGS>, Frags, t2, frag, !listconcat(t2, 306 !foldl([]<WMMA_REGS>, Types, t3, type, !listconcat(t3, 307 [WMMA_REGS<geom, frag, type>])))))); 308 // Debugging aid for readable representation of the list above. 309 list<string> ops = !foreach(x, ret, x.gft); 310} 311 312// Creates list of valid combinations of fragments. This is the main list that 313// drives generation of corresponding intrinsics and instructions. 314class NVVM_MMA_OPS { 315 list<list<WMMA_REGS>> tf32_wmma_ops = MMA_OPS< 316 ["m16n16k8"], 317 ["tf32"], [], ["f32"], []>.ret; 318 list<list<WMMA_REGS>> bf16_wmma_ops = MMA_OPS< 319 ["m16n16k16", "m32n8k16", "m8n32k16"], 320 ["bf16"], [], ["f32"], []>.ret; 321 list<list<WMMA_REGS>> f64_wmma_ops = MMA_OPS< 322 ["m8n8k4"], 323 ["f64"], [], ["f64"], []>.ret; 324 list<list<WMMA_REGS>> fp_wmma_ops = MMA_OPS< 325 ["m16n16k16", "m32n8k16", "m8n32k16"], 326 ["f16"], [], ["f16", "f32"], ["f16", "f32"]>.ret; 327 list<list<WMMA_REGS>> int_wmma_ops = MMA_OPS< 328 ["m16n16k16", "m32n8k16", "m8n32k16"], 329 ["s8", "u8"], [], ["s32"], []>.ret; 330 list<list<WMMA_REGS>> subint_wmma_ops = MMA_OPS< 331 ["m8n8k32"], 332 ["s4", "u4"], [], ["s32"], []>.ret; 333 list<list<WMMA_REGS>> bit_wmma_ops = MMA_OPS< 334 ["m8n8k128"], 335 ["b1"], [], ["s32"], []>.ret; 336 list<list<WMMA_REGS>> all_wmma_ops = !listconcat( 337 tf32_wmma_ops, bf16_wmma_ops, f64_wmma_ops, 338 fp_wmma_ops, int_wmma_ops, subint_wmma_ops, bit_wmma_ops); 339 340 list<list<WMMA_REGS>> tf32_mma_ops = MMA_OPS< 341 ["m16n8k4", "m16n8k8"], 342 ["tf32"], [], ["f32"], []>.ret; 343 list<list<WMMA_REGS>> bf16_mma_ops = MMA_OPS< 344 ["m16n8k16", "m16n8k8"], 345 ["bf16"], [], ["f32"], []>.ret; 346 list<list<WMMA_REGS>> f64_mma_ops = MMA_OPS< 347 ["m8n8k4"], 348 ["f64"], [], ["f64"], []>.ret; 349 list<list<WMMA_REGS>> fp_mma_ops = MMA_OPS< 350 ["m8n8k4", "m16n8k8", "m16n8k16"], 351 ["f16"], [], ["f16", "f32"], ["f16", "f32"]>.ret; 352 list<list<WMMA_REGS>> int_mma_ops = MMA_OPS< 353 ["m8n8k16", "m16n8k16", "m16n8k32"], 354 ["s8", "u8"], ["s8", "u8"], ["s32"], []>.ret; 355 list<list<WMMA_REGS>> subint_mma_ops = MMA_OPS< 356 ["m8n8k32", "m16n8k32", "m16n8k64"], 357 ["s4", "u4"], ["s4", "u4"], ["s32"], []>.ret; 358 list<list<WMMA_REGS>> bit_mma_ops = MMA_OPS< 359 ["m8n8k128", "m16n8k128", "m16n8k256"], 360 ["b1"], [], ["s32"], []>.ret; 361 list<list<WMMA_REGS>> all_mma_ops = !listconcat( 362 tf32_mma_ops, bf16_mma_ops, f64_mma_ops, 363 fp_mma_ops, int_mma_ops, subint_mma_ops, bit_mma_ops); 364 365 list<WMMA_REGS> ldst_ab_ops = MMA_LDST_OPS< 366 ["m16n16k16", "m32n8k16", "m8n32k16"], 367 ["a", "b"], ["f16", "u8", "s8", "bf16"]>.ret; 368 list<WMMA_REGS> ldst_cd_ops = MMA_LDST_OPS< 369 ["m16n16k16", "m32n8k16", "m8n32k16"], 370 ["c", "d"], ["f16", "f32", "s32"]>.ret; 371 list<WMMA_REGS> ldst_tf32_ab_ops = MMA_LDST_OPS< 372 ["m16n16k8"], 373 ["a", "b"], ["tf32"]>.ret; 374 list<WMMA_REGS> ldst_tf32_cd_ops = MMA_LDST_OPS< 375 ["m16n16k8"], 376 ["c", "d"], ["f32"]>.ret; 377 list<WMMA_REGS> ldst_f64_abcd_ops = MMA_LDST_OPS< 378 ["m8n8k4"], 379 ["a", "b", "c", "d"], ["f64"]>.ret; 380 list<WMMA_REGS> ldst_subint_ab_ops = MMA_LDST_OPS< 381 ["m8n8k32"], ["a", "b"], ["s4","u4"]>.ret; 382 list<WMMA_REGS> ldst_bit_ab_ops = MMA_LDST_OPS< 383 ["m8n8k128"], ["a", "b"], ["b1"]>.ret; 384 list<WMMA_REGS> ldst_subint_cd_ops = MMA_LDST_OPS< 385 ["m8n8k32", "m8n8k128"], ["c", "d"], ["s32"]>.ret; 386 list<WMMA_REGS> all_ldst_ops = !listconcat(ldst_ab_ops, ldst_cd_ops, 387 ldst_tf32_ab_ops, 388 ldst_tf32_cd_ops, 389 ldst_f64_abcd_ops, 390 ldst_subint_ab_ops, 391 ldst_bit_ab_ops, 392 ldst_subint_cd_ops); 393 // Separate A/B/C fragments (loads) from D (stores). 394 list<WMMA_REGS> all_ld_ops = !filter(op, all_ldst_ops, !ne(op.frag, "d")); 395 list<WMMA_REGS> all_st_ops = !filter(op, all_ldst_ops, !eq(op.frag, "d")); 396 397 list<WMMA_REGS> ldmatrix_b16_ops = LDMATRIX_OPS< 398 ["m8n8"], ["x1", "x2", "x4"], ["b16"]>.ret; 399 list<WMMA_REGS> all_ldmatrix_ops = ldmatrix_b16_ops; 400} 401 402def NVVM_MMA_OPS : NVVM_MMA_OPS; 403 404// Returns true if this combination of fragment and layout for WMMA load/store 405// ops is supported; false otherwise. 406// E.g. 407// if NVVM_WMMA_LDST_SUPPORTED<...>.ret then 408// def : FOO<>; // The record will only be defined for supported ops. 409// 410class NVVM_WMMA_LDST_SUPPORTED<WMMA_REGS frag, string layout> { 411 string f = frag.frag; 412 string t = frag.ptx_elt_type; 413 414 bit ret = !cond( 415 // Sub-int load and store requires A fragment to be of row layout and B 416 // fragments to be of column layout. 417 !and(!or(!eq(t, "b1"), 418 !eq(t, "u4"), 419 !eq(t, "s4")), 420 !or(!and(!eq(f, "a"), 421 !ne(layout, "row")), 422 !and(!eq(f, "b"), 423 !ne(layout, "col")))) : false, 424 true: true 425 ); 426} 427 428// Returns true if this combination of layout/satf/rnd for WMMA ops is 429// supported; false otherwise. 430// E.g. 431// if NVVM_WMMA_SUPPORTED<...>.ret then 432// def : FOO<>; // The record will only be defined for supported ops. 433// 434class NVVM_WMMA_SUPPORTED<list<WMMA_REGS> frags, string layout_a, string layout_b, int satf, string rnd> { 435 // WMMA ops check both layouts. 436 string layout = layout_a # ":" # layout_b; 437 string t = frags[0].ptx_elt_type; 438 439 bit ret = !cond( 440 // only f64 wmma functions support rnd options 441 // any non f64 type that uses a rnd value is invalid 442 !and(!ne(t, "f64"), !ne(rnd, "")) : false, 443 444 // satf is only valid for select types 445 !and(!eq(satf, 1), 446 !ne(t, "s8"), 447 !ne(t, "u8"), 448 !ne(t, "s4"), 449 !ne(t, "u4"), 450 !ne(t, "f16")): false, 451 452 // Sub-int wmma requires row/column layout 453 !and(!or(!eq(t, "s4"), 454 !eq(t, "u4"), 455 !eq(t, "b1")), 456 !ne(layout, "row:col")) : false, 457 true: true 458 ); 459} 460 461class NVVM_MMA_B1OPS<list<WMMA_REGS> frags> { 462 list<string> ret = !cond( 463 !eq(frags[0].ptx_elt_type, "b1") : [".xor.popc", ".and.popc"], 464 true: [""] 465 ); 466} 467 468// Returns true if this combination of layout/satf for MMA ops is supported; 469// false otherwise. 470// E.g. 471// if NVVM_MMA_SUPPORTED<...>.ret then 472// def : FOO<>; // The record will only be defined for supported ops. 473// 474class NVVM_MMA_SUPPORTED<list<WMMA_REGS> frags, string layout_a, string layout_b, int satf> { 475 // MMA ops check both layouts. 476 string layout = layout_a # ":" # layout_b; 477 string a_type = frags[0].ptx_elt_type; 478 string b_type = frags[1].ptx_elt_type; 479 string c_type = frags[2].ptx_elt_type; 480 string d_type = frags[3].ptx_elt_type; 481 string geom = frags[0].geom; 482 483 // gcd is a shortcut used to identify instructions that depend on 484 // geom+frag_c+frag_d. 485 string gcd = geom # ":" # c_type # d_type; 486 bit ret = !cond( 487 488 // Limit satf to valid types 489 !and(!eq(satf, 1), 490 !ne(a_type, "s8"), 491 !ne(a_type, "u8"), 492 !ne(a_type, "s4"), 493 !ne(a_type, "u4")): false, 494 495 // m8n8k4 has no C=f32 D=f16 variant. 496 !eq(gcd, "m8n8k4:f32f16"): false, 497 498 // only m8n8k4 for f16 does not require row:col layout 499 !and(!ne(layout, "row:col"), 500 !or(!ne(geom, "m8n8k4"), 501 !ne(a_type, "f16"))) : false, 502 503 // m16n8k8 requires A and B to be the same type and C and D to be the same 504 // type. 505 !and(!eq(geom, "m16n8k8"), 506 !or(!ne(a_type, b_type), 507 !ne(c_type, d_type))): false, 508 509 // m16n8k8 requires C and D to be the same type. 510 !and(!eq(geom, "m16n8k8"), 511 !ne(c_type, d_type)): false, 512 513 // All other are OK. 514 true: true 515 ); 516} 517 518// Returns true if the fragment is valid for ldmatrix ops is supported; 519// false otherwise. 520// E.g. 521// if NVVM_LDMATRIX_SUPPORTED<...>.ret then 522// def : FOO<>; // The record will only be defined for supported ops. 523// 524class NVVM_LDMATRIX_SUPPORTED<WMMA_REGS frag> { 525 string g = frag.geom; 526 string t = frag.ptx_elt_type; 527 528 bit ret = !cond( 529 // Only currently support m8n8 and b16 530 !and(!eq(g, "m8n8"), !eq(t, "b16")): true, 531 true: false 532 ); 533} 534 535class SHFL_INFO<bit sync, string mode, string type, bit return_pred> { 536 string Suffix = !if(sync, "sync_", "") 537 # mode # "_" 538 # type 539 # !if(return_pred, "p", ""); 540 541 string Name = "int_nvvm_shfl_" # Suffix; 542 string Builtin = "__nvvm_shfl_" # Suffix; 543 string IntrName = "llvm.nvvm.shfl." # !subst("_",".", Suffix); 544 bit withGccBuiltin = !not(return_pred); 545 bit withoutGccBuiltin = return_pred; 546 LLVMType OpType = !cond( 547 !eq(type,"i32"): llvm_i32_ty, 548 !eq(type,"f32"): llvm_float_ty); 549 list<LLVMType> RetTy = !if(return_pred, [OpType, llvm_i1_ty], [OpType]); 550 list<LLVMType> ArgsTy = !if(sync, 551 [llvm_i32_ty, OpType, llvm_i32_ty, llvm_i32_ty], 552 [OpType, llvm_i32_ty, llvm_i32_ty]); 553} 554 555let TargetPrefix = "nvvm" in { 556 def int_nvvm_prmt : ClangBuiltin<"__nvvm_prmt">, 557 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 558 [IntrNoMem, IntrSpeculatable]>; 559 560 def int_nvvm_nanosleep : ClangBuiltin<"__nvvm_nanosleep">, 561 DefaultAttrsIntrinsic<[], [llvm_i32_ty], 562 [IntrConvergent, IntrNoMem, IntrHasSideEffects]>; 563 564// 565// Min Max 566// 567 568 foreach operation = ["min", "max"] in { 569 def int_nvvm_f # operation # _d : 570 ClangBuiltin<!strconcat("__nvvm_f", operation, "_d")>, 571 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 572 [IntrNoMem, IntrSpeculatable, Commutative]>; 573 574 foreach variant = ["_f", "_ftz_f", "_nan_f", "_ftz_nan_f", 575 "_xorsign_abs_f", "_ftz_xorsign_abs_f", "_nan_xorsign_abs_f", 576 "_ftz_nan_xorsign_abs_f"] in { 577 def int_nvvm_f # operation # variant : 578 ClangBuiltin<!strconcat("__nvvm_f", operation, variant)>, 579 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 580 [IntrNoMem, IntrSpeculatable, Commutative]>; 581 } 582 583 foreach variant = ["_f16", "_ftz_f16", "_nan_f16", "_ftz_nan_f16", 584 "_xorsign_abs_f16", "_ftz_xorsign_abs_f16", "_nan_xorsign_abs_f16", 585 "_ftz_nan_xorsign_abs_f16"] in { 586 def int_nvvm_f # operation # variant : 587 DefaultAttrsIntrinsic<[llvm_half_ty], [llvm_half_ty, llvm_half_ty], 588 [IntrNoMem, IntrSpeculatable, Commutative]>; 589 } 590 591 foreach variant = ["_f16x2", "_ftz_f16x2", "_nan_f16x2", 592 "_ftz_nan_f16x2", "_xorsign_abs_f16x2", "_ftz_xorsign_abs_f16x2", 593 "_nan_xorsign_abs_f16x2", "_ftz_nan_xorsign_abs_f16x2"] in { 594 def int_nvvm_f # operation # variant : 595 DefaultAttrsIntrinsic<[llvm_v2f16_ty], [llvm_v2f16_ty, llvm_v2f16_ty], 596 [IntrNoMem, IntrSpeculatable, Commutative]>; 597 } 598 599 foreach variant = ["_bf16", "_ftz_bf16", "_nan_bf16", "_ftz_nan_bf16", 600 "_xorsign_abs_bf16", "_ftz_xorsign_abs_bf16", "_nan_xorsign_abs_bf16", 601 "_ftz_nan_xorsign_abs_bf16"] in { 602 def int_nvvm_f # operation # variant : 603 ClangBuiltin<!strconcat("__nvvm_f", operation, variant)>, 604 DefaultAttrsIntrinsic<[llvm_bfloat_ty], [llvm_bfloat_ty, llvm_bfloat_ty], 605 [IntrNoMem, IntrSpeculatable, Commutative]>; 606 } 607 608 foreach variant = ["_bf16x2", "_ftz_bf16x2", "_nan_bf16x2", 609 "_ftz_nan_bf16x2", "_xorsign_abs_bf16x2", "_ftz_xorsign_abs_bf16x2", 610 "_nan_xorsign_abs_bf16x2", "_ftz_nan_xorsign_abs_bf16x2"] in { 611 def int_nvvm_f # operation # variant : 612 ClangBuiltin<!strconcat("__nvvm_f", operation, variant)>, 613 DefaultAttrsIntrinsic<[llvm_v2bf16_ty], [llvm_v2bf16_ty, llvm_v2bf16_ty], 614 [IntrNoMem, IntrSpeculatable, Commutative]>; 615 } 616 } 617 618// 619// Multiplication 620// 621 622 def int_nvvm_mulhi_s : ClangBuiltin<"__nvvm_mulhi_s">, 623 DefaultAttrsIntrinsic<[llvm_i16_ty], [llvm_i16_ty, llvm_i16_ty], 624 [IntrNoMem, IntrSpeculatable, Commutative]>; 625 def int_nvvm_mulhi_us : ClangBuiltin<"__nvvm_mulhi_us">, 626 DefaultAttrsIntrinsic<[llvm_i16_ty], [llvm_i16_ty, llvm_i16_ty], 627 [IntrNoMem, IntrSpeculatable, Commutative]>; 628 629 def int_nvvm_mulhi_i : ClangBuiltin<"__nvvm_mulhi_i">, 630 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 631 [IntrNoMem, IntrSpeculatable, Commutative]>; 632 def int_nvvm_mulhi_ui : ClangBuiltin<"__nvvm_mulhi_ui">, 633 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 634 [IntrNoMem, IntrSpeculatable, Commutative]>; 635 636 def int_nvvm_mulhi_ll : ClangBuiltin<"__nvvm_mulhi_ll">, 637 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_i64_ty, llvm_i64_ty], 638 [IntrNoMem, IntrSpeculatable, Commutative]>; 639 def int_nvvm_mulhi_ull : ClangBuiltin<"__nvvm_mulhi_ull">, 640 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_i64_ty, llvm_i64_ty], 641 [IntrNoMem, IntrSpeculatable, Commutative]>; 642 643 def int_nvvm_mul_rn_ftz_f : ClangBuiltin<"__nvvm_mul_rn_ftz_f">, 644 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 645 [IntrNoMem, IntrSpeculatable, Commutative]>; 646 def int_nvvm_mul_rn_f : ClangBuiltin<"__nvvm_mul_rn_f">, 647 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 648 [IntrNoMem, IntrSpeculatable, Commutative]>; 649 def int_nvvm_mul_rz_ftz_f : ClangBuiltin<"__nvvm_mul_rz_ftz_f">, 650 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 651 [IntrNoMem, IntrSpeculatable, Commutative]>; 652 def int_nvvm_mul_rz_f : ClangBuiltin<"__nvvm_mul_rz_f">, 653 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 654 [IntrNoMem, IntrSpeculatable, Commutative]>; 655 def int_nvvm_mul_rm_ftz_f : ClangBuiltin<"__nvvm_mul_rm_ftz_f">, 656 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 657 [IntrNoMem, IntrSpeculatable, Commutative]>; 658 def int_nvvm_mul_rm_f : ClangBuiltin<"__nvvm_mul_rm_f">, 659 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 660 [IntrNoMem, IntrSpeculatable, Commutative]>; 661 def int_nvvm_mul_rp_ftz_f : ClangBuiltin<"__nvvm_mul_rp_ftz_f">, 662 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 663 [IntrNoMem, IntrSpeculatable, Commutative]>; 664 def int_nvvm_mul_rp_f : ClangBuiltin<"__nvvm_mul_rp_f">, 665 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 666 [IntrNoMem, IntrSpeculatable, Commutative]>; 667 668 def int_nvvm_mul_rn_d : ClangBuiltin<"__nvvm_mul_rn_d">, 669 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 670 [IntrNoMem, IntrSpeculatable, Commutative]>; 671 def int_nvvm_mul_rz_d : ClangBuiltin<"__nvvm_mul_rz_d">, 672 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 673 [IntrNoMem, IntrSpeculatable, Commutative]>; 674 def int_nvvm_mul_rm_d : ClangBuiltin<"__nvvm_mul_rm_d">, 675 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 676 [IntrNoMem, IntrSpeculatable, Commutative]>; 677 def int_nvvm_mul_rp_d : ClangBuiltin<"__nvvm_mul_rp_d">, 678 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 679 [IntrNoMem, IntrSpeculatable, Commutative]>; 680 681 def int_nvvm_mul24_i : ClangBuiltin<"__nvvm_mul24_i">, 682 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 683 [IntrNoMem, IntrSpeculatable, Commutative]>; 684 def int_nvvm_mul24_ui : ClangBuiltin<"__nvvm_mul24_ui">, 685 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 686 [IntrNoMem, IntrSpeculatable, Commutative]>; 687 688// 689// Div 690// 691 692 def int_nvvm_div_approx_ftz_f : ClangBuiltin<"__nvvm_div_approx_ftz_f">, 693 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 694 [IntrNoMem]>; 695 def int_nvvm_div_approx_f : ClangBuiltin<"__nvvm_div_approx_f">, 696 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 697 [IntrNoMem]>; 698 699 def int_nvvm_div_rn_ftz_f : ClangBuiltin<"__nvvm_div_rn_ftz_f">, 700 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 701 [IntrNoMem]>; 702 def int_nvvm_div_rn_f : ClangBuiltin<"__nvvm_div_rn_f">, 703 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 704 [IntrNoMem]>; 705 706 def int_nvvm_div_rz_ftz_f : ClangBuiltin<"__nvvm_div_rz_ftz_f">, 707 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 708 [IntrNoMem]>; 709 def int_nvvm_div_rz_f : ClangBuiltin<"__nvvm_div_rz_f">, 710 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 711 [IntrNoMem]>; 712 713 def int_nvvm_div_rm_ftz_f : ClangBuiltin<"__nvvm_div_rm_ftz_f">, 714 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 715 [IntrNoMem]>; 716 def int_nvvm_div_rm_f : ClangBuiltin<"__nvvm_div_rm_f">, 717 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 718 [IntrNoMem]>; 719 720 def int_nvvm_div_rp_ftz_f : ClangBuiltin<"__nvvm_div_rp_ftz_f">, 721 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 722 [IntrNoMem]>; 723 def int_nvvm_div_rp_f : ClangBuiltin<"__nvvm_div_rp_f">, 724 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 725 [IntrNoMem]>; 726 727 def int_nvvm_div_rn_d : ClangBuiltin<"__nvvm_div_rn_d">, 728 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 729 [IntrNoMem]>; 730 def int_nvvm_div_rz_d : ClangBuiltin<"__nvvm_div_rz_d">, 731 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 732 [IntrNoMem]>; 733 def int_nvvm_div_rm_d : ClangBuiltin<"__nvvm_div_rm_d">, 734 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 735 [IntrNoMem]>; 736 def int_nvvm_div_rp_d : ClangBuiltin<"__nvvm_div_rp_d">, 737 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 738 [IntrNoMem]>; 739 740// 741// Sad 742// 743 744 def int_nvvm_sad_s : ClangBuiltin<"__nvvm_sad_s">, 745 DefaultAttrsIntrinsic<[llvm_i16_ty], [llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 746 [IntrNoMem, Commutative, IntrSpeculatable]>; 747 def int_nvvm_sad_us : ClangBuiltin<"__nvvm_sad_us">, 748 DefaultAttrsIntrinsic<[llvm_i16_ty], [llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 749 [IntrNoMem, Commutative, IntrSpeculatable]>; 750 751 def int_nvvm_sad_i : ClangBuiltin<"__nvvm_sad_i">, 752 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 753 [IntrNoMem, Commutative, IntrSpeculatable]>; 754 def int_nvvm_sad_ui : ClangBuiltin<"__nvvm_sad_ui">, 755 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 756 [IntrNoMem, Commutative, IntrSpeculatable]>; 757 758 def int_nvvm_sad_ll : ClangBuiltin<"__nvvm_sad_ll">, 759 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_i64_ty, llvm_i64_ty, llvm_i64_ty], 760 [IntrNoMem, Commutative, IntrSpeculatable]>; 761 def int_nvvm_sad_ull : ClangBuiltin<"__nvvm_sad_ull">, 762 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_i64_ty, llvm_i64_ty, llvm_i64_ty], 763 [IntrNoMem, Commutative, IntrSpeculatable]>; 764 765 766// 767// Floor Ceil 768// 769 770 def int_nvvm_floor_ftz_f : ClangBuiltin<"__nvvm_floor_ftz_f">, 771 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 772 def int_nvvm_floor_f : ClangBuiltin<"__nvvm_floor_f">, 773 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 774 def int_nvvm_floor_d : ClangBuiltin<"__nvvm_floor_d">, 775 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 776 777 def int_nvvm_ceil_ftz_f : ClangBuiltin<"__nvvm_ceil_ftz_f">, 778 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 779 def int_nvvm_ceil_f : ClangBuiltin<"__nvvm_ceil_f">, 780 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 781 def int_nvvm_ceil_d : ClangBuiltin<"__nvvm_ceil_d">, 782 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 783 784// 785// Abs 786// 787 788 def int_nvvm_fabs_ftz_f : ClangBuiltin<"__nvvm_fabs_ftz_f">, 789 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 790 def int_nvvm_fabs_f : ClangBuiltin<"__nvvm_fabs_f">, 791 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 792 def int_nvvm_fabs_d : ClangBuiltin<"__nvvm_fabs_d">, 793 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 794 795// 796// Abs, Neg bf16, bf16x2 797// 798 799 foreach unary = ["abs", "neg"] in { 800 def int_nvvm_ # unary # _bf16 : 801 ClangBuiltin<!strconcat("__nvvm_", unary, "_bf16")>, 802 DefaultAttrsIntrinsic<[llvm_bfloat_ty], [llvm_bfloat_ty], [IntrNoMem]>; 803 def int_nvvm_ # unary # _bf16x2 : 804 ClangBuiltin<!strconcat("__nvvm_", unary, "_bf16x2")>, 805 DefaultAttrsIntrinsic<[llvm_v2bf16_ty], [llvm_v2bf16_ty], [IntrNoMem]>; 806 } 807 808// 809// Round 810// 811 812 def int_nvvm_round_ftz_f : ClangBuiltin<"__nvvm_round_ftz_f">, 813 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 814 def int_nvvm_round_f : ClangBuiltin<"__nvvm_round_f">, 815 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 816 817 def int_nvvm_round_d : ClangBuiltin<"__nvvm_round_d">, 818 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 819 820// 821// Trunc 822// 823 824 def int_nvvm_trunc_ftz_f : ClangBuiltin<"__nvvm_trunc_ftz_f">, 825 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 826 def int_nvvm_trunc_f : ClangBuiltin<"__nvvm_trunc_f">, 827 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 828 829 def int_nvvm_trunc_d : ClangBuiltin<"__nvvm_trunc_d">, 830 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 831 832// 833// Saturate 834// 835 836 def int_nvvm_saturate_ftz_f : ClangBuiltin<"__nvvm_saturate_ftz_f">, 837 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 838 def int_nvvm_saturate_f : ClangBuiltin<"__nvvm_saturate_f">, 839 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 840 841 def int_nvvm_saturate_d : ClangBuiltin<"__nvvm_saturate_d">, 842 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 843 844// 845// Exp2 Log2 846// 847 848 def int_nvvm_ex2_approx_ftz_f : ClangBuiltin<"__nvvm_ex2_approx_ftz_f">, 849 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 850 def int_nvvm_ex2_approx_f : ClangBuiltin<"__nvvm_ex2_approx_f">, 851 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 852 def int_nvvm_ex2_approx_d : ClangBuiltin<"__nvvm_ex2_approx_d">, 853 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 854 def int_nvvm_ex2_approx_f16 : 855 DefaultAttrsIntrinsic<[llvm_half_ty], [llvm_half_ty], [IntrNoMem]>; 856 def int_nvvm_ex2_approx_f16x2 : 857 DefaultAttrsIntrinsic<[llvm_v2f16_ty], [llvm_v2f16_ty], [IntrNoMem]>; 858 859 def int_nvvm_lg2_approx_ftz_f : ClangBuiltin<"__nvvm_lg2_approx_ftz_f">, 860 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 861 def int_nvvm_lg2_approx_f : ClangBuiltin<"__nvvm_lg2_approx_f">, 862 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 863 def int_nvvm_lg2_approx_d : ClangBuiltin<"__nvvm_lg2_approx_d">, 864 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 865 866// 867// Sin Cos 868// 869 870 def int_nvvm_sin_approx_ftz_f : ClangBuiltin<"__nvvm_sin_approx_ftz_f">, 871 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 872 def int_nvvm_sin_approx_f : ClangBuiltin<"__nvvm_sin_approx_f">, 873 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 874 875 def int_nvvm_cos_approx_ftz_f : ClangBuiltin<"__nvvm_cos_approx_ftz_f">, 876 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 877 def int_nvvm_cos_approx_f : ClangBuiltin<"__nvvm_cos_approx_f">, 878 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 879 880// 881// Fma 882// 883 884 foreach variant = ["_rn_f16", "_rn_ftz_f16", "_rn_sat_f16", 885 "_rn_ftz_sat_f16", "_rn_relu_f16", "_rn_ftz_relu_f16"] in { 886 def int_nvvm_fma # variant : DefaultAttrsIntrinsic<[llvm_half_ty], 887 [llvm_half_ty, llvm_half_ty, llvm_half_ty], 888 [IntrNoMem, IntrSpeculatable]>; 889 } 890 891 foreach variant = ["_rn_f16x2", "_rn_ftz_f16x2", "_rn_sat_f16x2", 892 "_rn_ftz_sat_f16x2", "_rn_relu_f16x2", "_rn_ftz_relu_f16x2"] in { 893 def int_nvvm_fma # variant : DefaultAttrsIntrinsic<[llvm_v2f16_ty], 894 [llvm_v2f16_ty, llvm_v2f16_ty, llvm_v2f16_ty], 895 [IntrNoMem, IntrSpeculatable]>; 896 } 897 898 foreach variant = ["_rn_bf16", "_rn_ftz_bf16", "_rn_sat_bf16", 899 "_rn_ftz_sat_bf16", "_rn_relu_bf16", "_rn_ftz_relu_bf16"] in { 900 def int_nvvm_fma # variant : ClangBuiltin<!strconcat("__nvvm_fma", variant)>, 901 DefaultAttrsIntrinsic<[llvm_bfloat_ty], 902 [llvm_bfloat_ty, llvm_bfloat_ty, llvm_bfloat_ty], 903 [IntrNoMem, IntrSpeculatable]>; 904 } 905 906 foreach variant = ["_rn_bf16x2", "_rn_ftz_bf16x2", "_rn_sat_bf16x2", 907 "_rn_ftz_sat_bf16x2", "_rn_relu_bf16x2", "_rn_ftz_relu_bf16x2"] in { 908 def int_nvvm_fma # variant : ClangBuiltin<!strconcat("__nvvm_fma", variant)>, 909 DefaultAttrsIntrinsic<[llvm_v2bf16_ty], 910 [llvm_v2bf16_ty, llvm_v2bf16_ty, llvm_v2bf16_ty], 911 [IntrNoMem, IntrSpeculatable]>; 912 } 913 914 foreach variant = ["_rn_ftz_f", "_rn_f", "_rz_ftz_f", "_rz_f", "_rm_ftz_f", 915 "_rm_f", "_rp_ftz_f", "_rp_f"] in { 916 def int_nvvm_fma # variant : ClangBuiltin<!strconcat("__nvvm_fma", variant)>, 917 DefaultAttrsIntrinsic<[llvm_float_ty], 918 [llvm_float_ty, llvm_float_ty, llvm_float_ty], 919 [IntrNoMem, IntrSpeculatable]>; 920 } 921 922 foreach variant = ["_rn_d", "_rz_d", "_rm_d", "_rp_d"] in { 923 def int_nvvm_fma # variant : ClangBuiltin<!strconcat("__nvvm_fma", variant)>, 924 DefaultAttrsIntrinsic<[llvm_double_ty], 925 [llvm_double_ty, llvm_double_ty, llvm_double_ty], 926 [IntrNoMem, IntrSpeculatable]>; 927 } 928 929// 930// Rcp 931// 932 933 def int_nvvm_rcp_rn_ftz_f : ClangBuiltin<"__nvvm_rcp_rn_ftz_f">, 934 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 935 def int_nvvm_rcp_rn_f : ClangBuiltin<"__nvvm_rcp_rn_f">, 936 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 937 def int_nvvm_rcp_rz_ftz_f : ClangBuiltin<"__nvvm_rcp_rz_ftz_f">, 938 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 939 def int_nvvm_rcp_rz_f : ClangBuiltin<"__nvvm_rcp_rz_f">, 940 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 941 def int_nvvm_rcp_rm_ftz_f : ClangBuiltin<"__nvvm_rcp_rm_ftz_f">, 942 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 943 def int_nvvm_rcp_rm_f : ClangBuiltin<"__nvvm_rcp_rm_f">, 944 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 945 def int_nvvm_rcp_rp_ftz_f : ClangBuiltin<"__nvvm_rcp_rp_ftz_f">, 946 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 947 def int_nvvm_rcp_rp_f : ClangBuiltin<"__nvvm_rcp_rp_f">, 948 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 949 950 def int_nvvm_rcp_rn_d : ClangBuiltin<"__nvvm_rcp_rn_d">, 951 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 952 def int_nvvm_rcp_rz_d : ClangBuiltin<"__nvvm_rcp_rz_d">, 953 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 954 def int_nvvm_rcp_rm_d : ClangBuiltin<"__nvvm_rcp_rm_d">, 955 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 956 def int_nvvm_rcp_rp_d : ClangBuiltin<"__nvvm_rcp_rp_d">, 957 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 958 959 def int_nvvm_rcp_approx_ftz_f : ClangBuiltin<"__nvvm_rcp_approx_ftz_f">, 960 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 961 def int_nvvm_rcp_approx_ftz_d : ClangBuiltin<"__nvvm_rcp_approx_ftz_d">, 962 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 963 964// 965// Sqrt 966// 967 968 def int_nvvm_sqrt_f : ClangBuiltin<"__nvvm_sqrt_f">, 969 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 970 def int_nvvm_sqrt_rn_ftz_f : ClangBuiltin<"__nvvm_sqrt_rn_ftz_f">, 971 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 972 def int_nvvm_sqrt_rn_f : ClangBuiltin<"__nvvm_sqrt_rn_f">, 973 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 974 def int_nvvm_sqrt_rz_ftz_f : ClangBuiltin<"__nvvm_sqrt_rz_ftz_f">, 975 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 976 def int_nvvm_sqrt_rz_f : ClangBuiltin<"__nvvm_sqrt_rz_f">, 977 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 978 def int_nvvm_sqrt_rm_ftz_f : ClangBuiltin<"__nvvm_sqrt_rm_ftz_f">, 979 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 980 def int_nvvm_sqrt_rm_f : ClangBuiltin<"__nvvm_sqrt_rm_f">, 981 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 982 def int_nvvm_sqrt_rp_ftz_f : ClangBuiltin<"__nvvm_sqrt_rp_ftz_f">, 983 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 984 def int_nvvm_sqrt_rp_f : ClangBuiltin<"__nvvm_sqrt_rp_f">, 985 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 986 def int_nvvm_sqrt_approx_ftz_f : ClangBuiltin<"__nvvm_sqrt_approx_ftz_f">, 987 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 988 def int_nvvm_sqrt_approx_f : ClangBuiltin<"__nvvm_sqrt_approx_f">, 989 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 990 991 def int_nvvm_sqrt_rn_d : ClangBuiltin<"__nvvm_sqrt_rn_d">, 992 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 993 def int_nvvm_sqrt_rz_d : ClangBuiltin<"__nvvm_sqrt_rz_d">, 994 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 995 def int_nvvm_sqrt_rm_d : ClangBuiltin<"__nvvm_sqrt_rm_d">, 996 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 997 def int_nvvm_sqrt_rp_d : ClangBuiltin<"__nvvm_sqrt_rp_d">, 998 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 999 1000// 1001// Rsqrt 1002// 1003 1004 def int_nvvm_rsqrt_approx_ftz_f : ClangBuiltin<"__nvvm_rsqrt_approx_ftz_f">, 1005 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 1006 def int_nvvm_rsqrt_approx_ftz_d : ClangBuiltin<"__nvvm_rsqrt_approx_ftz_d">, 1007 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 1008 def int_nvvm_rsqrt_approx_f : ClangBuiltin<"__nvvm_rsqrt_approx_f">, 1009 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty], [IntrNoMem]>; 1010 def int_nvvm_rsqrt_approx_d : ClangBuiltin<"__nvvm_rsqrt_approx_d">, 1011 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty], [IntrNoMem]>; 1012 1013// 1014// Add 1015// 1016 1017 def int_nvvm_add_rn_ftz_f : ClangBuiltin<"__nvvm_add_rn_ftz_f">, 1018 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 1019 [IntrNoMem, IntrSpeculatable, Commutative]>; 1020 def int_nvvm_add_rn_f : ClangBuiltin<"__nvvm_add_rn_f">, 1021 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 1022 [IntrNoMem, IntrSpeculatable, Commutative]>; 1023 def int_nvvm_add_rz_ftz_f : ClangBuiltin<"__nvvm_add_rz_ftz_f">, 1024 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 1025 [IntrNoMem, IntrSpeculatable, Commutative]>; 1026 def int_nvvm_add_rz_f : ClangBuiltin<"__nvvm_add_rz_f">, 1027 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 1028 [IntrNoMem, IntrSpeculatable, Commutative]>; 1029 def int_nvvm_add_rm_ftz_f : ClangBuiltin<"__nvvm_add_rm_ftz_f">, 1030 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 1031 [IntrNoMem, IntrSpeculatable, Commutative]>; 1032 def int_nvvm_add_rm_f : ClangBuiltin<"__nvvm_add_rm_f">, 1033 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 1034 [IntrNoMem, IntrSpeculatable, Commutative]>; 1035 def int_nvvm_add_rp_ftz_f : ClangBuiltin<"__nvvm_add_rp_ftz_f">, 1036 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 1037 [IntrNoMem, IntrSpeculatable, Commutative]>; 1038 def int_nvvm_add_rp_f : ClangBuiltin<"__nvvm_add_rp_f">, 1039 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_float_ty, llvm_float_ty], 1040 [IntrNoMem, IntrSpeculatable, Commutative]>; 1041 1042 def int_nvvm_add_rn_d : ClangBuiltin<"__nvvm_add_rn_d">, 1043 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 1044 [IntrNoMem, IntrSpeculatable, Commutative]>; 1045 def int_nvvm_add_rz_d : ClangBuiltin<"__nvvm_add_rz_d">, 1046 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 1047 [IntrNoMem, IntrSpeculatable, Commutative]>; 1048 def int_nvvm_add_rm_d : ClangBuiltin<"__nvvm_add_rm_d">, 1049 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 1050 [IntrNoMem, IntrSpeculatable, Commutative]>; 1051 def int_nvvm_add_rp_d : ClangBuiltin<"__nvvm_add_rp_d">, 1052 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_double_ty, llvm_double_ty], 1053 [IntrNoMem, IntrSpeculatable, Commutative]>; 1054 1055// 1056// Convert 1057// 1058 1059 def int_nvvm_d2f_rn_ftz : ClangBuiltin<"__nvvm_d2f_rn_ftz">, 1060 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1061 def int_nvvm_d2f_rn : ClangBuiltin<"__nvvm_d2f_rn">, 1062 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1063 def int_nvvm_d2f_rz_ftz : ClangBuiltin<"__nvvm_d2f_rz_ftz">, 1064 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1065 def int_nvvm_d2f_rz : ClangBuiltin<"__nvvm_d2f_rz">, 1066 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1067 def int_nvvm_d2f_rm_ftz : ClangBuiltin<"__nvvm_d2f_rm_ftz">, 1068 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1069 def int_nvvm_d2f_rm : ClangBuiltin<"__nvvm_d2f_rm">, 1070 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1071 def int_nvvm_d2f_rp_ftz : ClangBuiltin<"__nvvm_d2f_rp_ftz">, 1072 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1073 def int_nvvm_d2f_rp : ClangBuiltin<"__nvvm_d2f_rp">, 1074 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1075 1076 def int_nvvm_d2i_rn : ClangBuiltin<"__nvvm_d2i_rn">, 1077 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1078 def int_nvvm_d2i_rz : ClangBuiltin<"__nvvm_d2i_rz">, 1079 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1080 def int_nvvm_d2i_rm : ClangBuiltin<"__nvvm_d2i_rm">, 1081 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1082 def int_nvvm_d2i_rp : ClangBuiltin<"__nvvm_d2i_rp">, 1083 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1084 1085 def int_nvvm_d2ui_rn : ClangBuiltin<"__nvvm_d2ui_rn">, 1086 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1087 def int_nvvm_d2ui_rz : ClangBuiltin<"__nvvm_d2ui_rz">, 1088 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1089 def int_nvvm_d2ui_rm : ClangBuiltin<"__nvvm_d2ui_rm">, 1090 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1091 def int_nvvm_d2ui_rp : ClangBuiltin<"__nvvm_d2ui_rp">, 1092 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1093 1094 def int_nvvm_i2d_rn : ClangBuiltin<"__nvvm_i2d_rn">, 1095 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1096 def int_nvvm_i2d_rz : ClangBuiltin<"__nvvm_i2d_rz">, 1097 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1098 def int_nvvm_i2d_rm : ClangBuiltin<"__nvvm_i2d_rm">, 1099 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1100 def int_nvvm_i2d_rp : ClangBuiltin<"__nvvm_i2d_rp">, 1101 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1102 1103 def int_nvvm_ui2d_rn : ClangBuiltin<"__nvvm_ui2d_rn">, 1104 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1105 def int_nvvm_ui2d_rz : ClangBuiltin<"__nvvm_ui2d_rz">, 1106 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1107 def int_nvvm_ui2d_rm : ClangBuiltin<"__nvvm_ui2d_rm">, 1108 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1109 def int_nvvm_ui2d_rp : ClangBuiltin<"__nvvm_ui2d_rp">, 1110 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1111 1112 def int_nvvm_f2i_rn_ftz : ClangBuiltin<"__nvvm_f2i_rn_ftz">, 1113 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1114 def int_nvvm_f2i_rn : ClangBuiltin<"__nvvm_f2i_rn">, 1115 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1116 def int_nvvm_f2i_rz_ftz : ClangBuiltin<"__nvvm_f2i_rz_ftz">, 1117 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1118 def int_nvvm_f2i_rz : ClangBuiltin<"__nvvm_f2i_rz">, 1119 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1120 def int_nvvm_f2i_rm_ftz : ClangBuiltin<"__nvvm_f2i_rm_ftz">, 1121 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1122 def int_nvvm_f2i_rm : ClangBuiltin<"__nvvm_f2i_rm">, 1123 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1124 def int_nvvm_f2i_rp_ftz : ClangBuiltin<"__nvvm_f2i_rp_ftz">, 1125 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1126 def int_nvvm_f2i_rp : ClangBuiltin<"__nvvm_f2i_rp">, 1127 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1128 1129 def int_nvvm_f2ui_rn_ftz : ClangBuiltin<"__nvvm_f2ui_rn_ftz">, 1130 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1131 def int_nvvm_f2ui_rn : ClangBuiltin<"__nvvm_f2ui_rn">, 1132 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1133 def int_nvvm_f2ui_rz_ftz : ClangBuiltin<"__nvvm_f2ui_rz_ftz">, 1134 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1135 def int_nvvm_f2ui_rz : ClangBuiltin<"__nvvm_f2ui_rz">, 1136 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1137 def int_nvvm_f2ui_rm_ftz : ClangBuiltin<"__nvvm_f2ui_rm_ftz">, 1138 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1139 def int_nvvm_f2ui_rm : ClangBuiltin<"__nvvm_f2ui_rm">, 1140 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1141 def int_nvvm_f2ui_rp_ftz : ClangBuiltin<"__nvvm_f2ui_rp_ftz">, 1142 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1143 def int_nvvm_f2ui_rp : ClangBuiltin<"__nvvm_f2ui_rp">, 1144 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1145 1146 def int_nvvm_i2f_rn : ClangBuiltin<"__nvvm_i2f_rn">, 1147 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1148 def int_nvvm_i2f_rz : ClangBuiltin<"__nvvm_i2f_rz">, 1149 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1150 def int_nvvm_i2f_rm : ClangBuiltin<"__nvvm_i2f_rm">, 1151 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1152 def int_nvvm_i2f_rp : ClangBuiltin<"__nvvm_i2f_rp">, 1153 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1154 1155 def int_nvvm_ui2f_rn : ClangBuiltin<"__nvvm_ui2f_rn">, 1156 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1157 def int_nvvm_ui2f_rz : ClangBuiltin<"__nvvm_ui2f_rz">, 1158 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1159 def int_nvvm_ui2f_rm : ClangBuiltin<"__nvvm_ui2f_rm">, 1160 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1161 def int_nvvm_ui2f_rp : ClangBuiltin<"__nvvm_ui2f_rp">, 1162 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1163 1164 def int_nvvm_lohi_i2d : ClangBuiltin<"__nvvm_lohi_i2d">, 1165 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i32_ty, llvm_i32_ty], 1166 [IntrNoMem, IntrSpeculatable, Commutative]>; 1167 1168 def int_nvvm_d2i_lo : ClangBuiltin<"__nvvm_d2i_lo">, 1169 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1170 def int_nvvm_d2i_hi : ClangBuiltin<"__nvvm_d2i_hi">, 1171 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1172 1173 def int_nvvm_f2ll_rn_ftz : ClangBuiltin<"__nvvm_f2ll_rn_ftz">, 1174 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1175 def int_nvvm_f2ll_rn : ClangBuiltin<"__nvvm_f2ll_rn">, 1176 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1177 def int_nvvm_f2ll_rz_ftz : ClangBuiltin<"__nvvm_f2ll_rz_ftz">, 1178 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1179 def int_nvvm_f2ll_rz : ClangBuiltin<"__nvvm_f2ll_rz">, 1180 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1181 def int_nvvm_f2ll_rm_ftz : ClangBuiltin<"__nvvm_f2ll_rm_ftz">, 1182 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1183 def int_nvvm_f2ll_rm : ClangBuiltin<"__nvvm_f2ll_rm">, 1184 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1185 def int_nvvm_f2ll_rp_ftz : ClangBuiltin<"__nvvm_f2ll_rp_ftz">, 1186 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1187 def int_nvvm_f2ll_rp : ClangBuiltin<"__nvvm_f2ll_rp">, 1188 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1189 1190 def int_nvvm_f2ull_rn_ftz : ClangBuiltin<"__nvvm_f2ull_rn_ftz">, 1191 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1192 def int_nvvm_f2ull_rn : ClangBuiltin<"__nvvm_f2ull_rn">, 1193 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1194 def int_nvvm_f2ull_rz_ftz : ClangBuiltin<"__nvvm_f2ull_rz_ftz">, 1195 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1196 def int_nvvm_f2ull_rz : ClangBuiltin<"__nvvm_f2ull_rz">, 1197 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1198 def int_nvvm_f2ull_rm_ftz : ClangBuiltin<"__nvvm_f2ull_rm_ftz">, 1199 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1200 def int_nvvm_f2ull_rm : ClangBuiltin<"__nvvm_f2ull_rm">, 1201 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1202 def int_nvvm_f2ull_rp_ftz : ClangBuiltin<"__nvvm_f2ull_rp_ftz">, 1203 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1204 def int_nvvm_f2ull_rp : ClangBuiltin<"__nvvm_f2ull_rp">, 1205 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1206 1207 def int_nvvm_d2ll_rn : ClangBuiltin<"__nvvm_d2ll_rn">, 1208 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1209 def int_nvvm_d2ll_rz : ClangBuiltin<"__nvvm_d2ll_rz">, 1210 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1211 def int_nvvm_d2ll_rm : ClangBuiltin<"__nvvm_d2ll_rm">, 1212 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1213 def int_nvvm_d2ll_rp : ClangBuiltin<"__nvvm_d2ll_rp">, 1214 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1215 1216 def int_nvvm_d2ull_rn : ClangBuiltin<"__nvvm_d2ull_rn">, 1217 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1218 def int_nvvm_d2ull_rz : ClangBuiltin<"__nvvm_d2ull_rz">, 1219 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1220 def int_nvvm_d2ull_rm : ClangBuiltin<"__nvvm_d2ull_rm">, 1221 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1222 def int_nvvm_d2ull_rp : ClangBuiltin<"__nvvm_d2ull_rp">, 1223 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1224 1225 def int_nvvm_ll2f_rn : ClangBuiltin<"__nvvm_ll2f_rn">, 1226 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1227 def int_nvvm_ll2f_rz : ClangBuiltin<"__nvvm_ll2f_rz">, 1228 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1229 def int_nvvm_ll2f_rm : ClangBuiltin<"__nvvm_ll2f_rm">, 1230 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1231 def int_nvvm_ll2f_rp : ClangBuiltin<"__nvvm_ll2f_rp">, 1232 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1233 def int_nvvm_ull2f_rn : ClangBuiltin<"__nvvm_ull2f_rn">, 1234 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1235 def int_nvvm_ull2f_rz : ClangBuiltin<"__nvvm_ull2f_rz">, 1236 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1237 def int_nvvm_ull2f_rm : ClangBuiltin<"__nvvm_ull2f_rm">, 1238 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1239 def int_nvvm_ull2f_rp : ClangBuiltin<"__nvvm_ull2f_rp">, 1240 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1241 1242 def int_nvvm_ll2d_rn : ClangBuiltin<"__nvvm_ll2d_rn">, 1243 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1244 def int_nvvm_ll2d_rz : ClangBuiltin<"__nvvm_ll2d_rz">, 1245 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1246 def int_nvvm_ll2d_rm : ClangBuiltin<"__nvvm_ll2d_rm">, 1247 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1248 def int_nvvm_ll2d_rp : ClangBuiltin<"__nvvm_ll2d_rp">, 1249 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1250 def int_nvvm_ull2d_rn : ClangBuiltin<"__nvvm_ull2d_rn">, 1251 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1252 def int_nvvm_ull2d_rz : ClangBuiltin<"__nvvm_ull2d_rz">, 1253 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1254 def int_nvvm_ull2d_rm : ClangBuiltin<"__nvvm_ull2d_rm">, 1255 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1256 def int_nvvm_ull2d_rp : ClangBuiltin<"__nvvm_ull2d_rp">, 1257 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1258 1259 def int_nvvm_f2h_rn_ftz : ClangBuiltin<"__nvvm_f2h_rn_ftz">, 1260 DefaultAttrsIntrinsic<[llvm_i16_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1261 def int_nvvm_f2h_rn : ClangBuiltin<"__nvvm_f2h_rn">, 1262 DefaultAttrsIntrinsic<[llvm_i16_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1263 1264 def int_nvvm_bf2h_rn_ftz : ClangBuiltin<"__nvvm_bf2h_rn_ftz">, 1265 DefaultAttrsIntrinsic<[llvm_i16_ty], [llvm_bfloat_ty], [IntrNoMem, IntrSpeculatable]>; 1266 def int_nvvm_bf2h_rn : ClangBuiltin<"__nvvm_bf2h_rn">, 1267 DefaultAttrsIntrinsic<[llvm_i16_ty], [llvm_bfloat_ty], [IntrNoMem, IntrSpeculatable]>; 1268 1269 def int_nvvm_ff2bf16x2_rn : ClangBuiltin<"__nvvm_ff2bf16x2_rn">, 1270 Intrinsic<[llvm_v2bf16_ty], [llvm_float_ty, llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1271 def int_nvvm_ff2bf16x2_rn_relu : ClangBuiltin<"__nvvm_ff2bf16x2_rn_relu">, 1272 Intrinsic<[llvm_v2bf16_ty], [llvm_float_ty, llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1273 def int_nvvm_ff2bf16x2_rz : ClangBuiltin<"__nvvm_ff2bf16x2_rz">, 1274 Intrinsic<[llvm_v2bf16_ty], [llvm_float_ty, llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1275 def int_nvvm_ff2bf16x2_rz_relu : ClangBuiltin<"__nvvm_ff2bf16x2_rz_relu">, 1276 Intrinsic<[llvm_v2bf16_ty], [llvm_float_ty, llvm_float_ty], [IntrNoMem]>; 1277 1278 def int_nvvm_ff2f16x2_rn : ClangBuiltin<"__nvvm_ff2f16x2_rn">, 1279 Intrinsic<[llvm_v2f16_ty], [llvm_float_ty, llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1280 def int_nvvm_ff2f16x2_rn_relu : ClangBuiltin<"__nvvm_ff2f16x2_rn_relu">, 1281 Intrinsic<[llvm_v2f16_ty], [llvm_float_ty, llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1282 def int_nvvm_ff2f16x2_rz : ClangBuiltin<"__nvvm_ff2f16x2_rz">, 1283 Intrinsic<[llvm_v2f16_ty], [llvm_float_ty, llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1284 def int_nvvm_ff2f16x2_rz_relu : ClangBuiltin<"__nvvm_ff2f16x2_rz_relu">, 1285 Intrinsic<[llvm_v2f16_ty], [llvm_float_ty, llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1286 1287 def int_nvvm_f2bf16_rn : ClangBuiltin<"__nvvm_f2bf16_rn">, 1288 Intrinsic<[llvm_bfloat_ty], [llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1289 def int_nvvm_f2bf16_rn_relu : ClangBuiltin<"__nvvm_f2bf16_rn_relu">, 1290 Intrinsic<[llvm_bfloat_ty], [llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1291 def int_nvvm_f2bf16_rz : ClangBuiltin<"__nvvm_f2bf16_rz">, 1292 Intrinsic<[llvm_bfloat_ty], [llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1293 def int_nvvm_f2bf16_rz_relu : ClangBuiltin<"__nvvm_f2bf16_rz_relu">, 1294 Intrinsic<[llvm_bfloat_ty], [llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1295 1296 def int_nvvm_f2tf32_rna : ClangBuiltin<"__nvvm_f2tf32_rna">, 1297 Intrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrNoCallback]>; 1298 1299// 1300// Bitcast 1301// 1302 1303 def int_nvvm_bitcast_f2i : ClangBuiltin<"__nvvm_bitcast_f2i">, 1304 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_float_ty], [IntrNoMem, IntrSpeculatable]>; 1305 def int_nvvm_bitcast_i2f : ClangBuiltin<"__nvvm_bitcast_i2f">, 1306 DefaultAttrsIntrinsic<[llvm_float_ty], [llvm_i32_ty], [IntrNoMem, IntrSpeculatable]>; 1307 1308 def int_nvvm_bitcast_ll2d : ClangBuiltin<"__nvvm_bitcast_ll2d">, 1309 DefaultAttrsIntrinsic<[llvm_double_ty], [llvm_i64_ty], [IntrNoMem, IntrSpeculatable]>; 1310 def int_nvvm_bitcast_d2ll : ClangBuiltin<"__nvvm_bitcast_d2ll">, 1311 DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_double_ty], [IntrNoMem, IntrSpeculatable]>; 1312 1313// FNS 1314 1315 def int_nvvm_fns : ClangBuiltin<"__nvvm_fns">, 1316 DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1317 [IntrNoMem]>; 1318 1319// Atomics not available as llvm intrinsics. 1320 def int_nvvm_atomic_load_inc_32 : Intrinsic<[llvm_i32_ty], 1321 [llvm_anyptr_ty, llvm_i32_ty], 1322 [IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>]>; 1323 def int_nvvm_atomic_load_dec_32 : Intrinsic<[llvm_i32_ty], 1324 [llvm_anyptr_ty, llvm_i32_ty], 1325 [IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>]>; 1326 1327 class SCOPED_ATOMIC2_impl<LLVMType elty> 1328 : Intrinsic<[elty], 1329 [llvm_anyptr_ty, LLVMMatchType<0>], 1330 [IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>]>; 1331 class SCOPED_ATOMIC3_impl<LLVMType elty> 1332 : Intrinsic<[elty], 1333 [llvm_anyptr_ty, LLVMMatchType<0>, 1334 LLVMMatchType<0>], 1335 [IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>]>; 1336 1337 multiclass PTXAtomicWithScope2<LLVMType elty> { 1338 def _cta : SCOPED_ATOMIC2_impl<elty>; 1339 def _sys : SCOPED_ATOMIC2_impl<elty>; 1340 } 1341 multiclass PTXAtomicWithScope3<LLVMType elty> { 1342 def _cta : SCOPED_ATOMIC3_impl<elty>; 1343 def _sys : SCOPED_ATOMIC3_impl<elty>; 1344 } 1345 multiclass PTXAtomicWithScope2_fi { 1346 defm _f: PTXAtomicWithScope2<llvm_anyfloat_ty>; 1347 defm _i: PTXAtomicWithScope2<llvm_anyint_ty>; 1348 } 1349 defm int_nvvm_atomic_add_gen : PTXAtomicWithScope2_fi; 1350 defm int_nvvm_atomic_inc_gen_i : PTXAtomicWithScope2<llvm_anyint_ty>; 1351 defm int_nvvm_atomic_dec_gen_i : PTXAtomicWithScope2<llvm_anyint_ty>; 1352 defm int_nvvm_atomic_exch_gen_i: PTXAtomicWithScope2<llvm_anyint_ty>; 1353 defm int_nvvm_atomic_xor_gen_i : PTXAtomicWithScope2<llvm_anyint_ty>; 1354 defm int_nvvm_atomic_max_gen_i : PTXAtomicWithScope2<llvm_anyint_ty>; 1355 defm int_nvvm_atomic_min_gen_i : PTXAtomicWithScope2<llvm_anyint_ty>; 1356 defm int_nvvm_atomic_or_gen_i : PTXAtomicWithScope2<llvm_anyint_ty>; 1357 defm int_nvvm_atomic_and_gen_i : PTXAtomicWithScope2<llvm_anyint_ty>; 1358 defm int_nvvm_atomic_cas_gen_i : PTXAtomicWithScope3<llvm_anyint_ty>; 1359 1360// Bar.Sync 1361 1362 // The builtin for "bar.sync 0" is called __syncthreads. Unlike most of the 1363 // intrinsics in this file, this one is a user-facing API. 1364 def int_nvvm_barrier0 : ClangBuiltin<"__syncthreads">, 1365 Intrinsic<[], [], [IntrConvergent, IntrNoCallback]>; 1366 // Synchronize all threads in the CTA at barrier 'n'. 1367 def int_nvvm_barrier_n : ClangBuiltin<"__nvvm_bar_n">, 1368 Intrinsic<[], [llvm_i32_ty], [IntrConvergent, IntrNoCallback]>; 1369 // Synchronize 'm', a multiple of warp size, (arg 2) threads in 1370 // the CTA at barrier 'n' (arg 1). 1371 def int_nvvm_barrier : ClangBuiltin<"__nvvm_bar">, 1372 Intrinsic<[], [llvm_i32_ty, llvm_i32_ty], [IntrConvergent, IntrNoCallback]>; 1373 def int_nvvm_barrier0_popc : ClangBuiltin<"__nvvm_bar0_popc">, 1374 Intrinsic<[llvm_i32_ty], [llvm_i32_ty], [IntrConvergent, IntrNoCallback]>; 1375 def int_nvvm_barrier0_and : ClangBuiltin<"__nvvm_bar0_and">, 1376 Intrinsic<[llvm_i32_ty], [llvm_i32_ty], [IntrConvergent, IntrNoCallback]>; 1377 def int_nvvm_barrier0_or : ClangBuiltin<"__nvvm_bar0_or">, 1378 Intrinsic<[llvm_i32_ty], [llvm_i32_ty], [IntrConvergent, IntrNoCallback]>; 1379 1380 def int_nvvm_bar_sync : 1381 Intrinsic<[], [llvm_i32_ty], [IntrConvergent, IntrNoCallback]>, 1382 ClangBuiltin<"__nvvm_bar_sync">; 1383 def int_nvvm_bar_warp_sync : 1384 Intrinsic<[], [llvm_i32_ty], [IntrConvergent, IntrNoCallback]>, 1385 ClangBuiltin<"__nvvm_bar_warp_sync">; 1386 1387 // barrier.sync id[, cnt] 1388 def int_nvvm_barrier_sync : 1389 Intrinsic<[], [llvm_i32_ty], [IntrConvergent, IntrNoCallback]>, 1390 ClangBuiltin<"__nvvm_barrier_sync">; 1391 def int_nvvm_barrier_sync_cnt : 1392 Intrinsic<[], [llvm_i32_ty, llvm_i32_ty], [IntrConvergent, IntrNoCallback]>, 1393 ClangBuiltin<"__nvvm_barrier_sync_cnt">; 1394 1395 // barrier.cluster.[wait, arrive, arrive.relaxed] 1396 def int_nvvm_barrier_cluster_arrive : 1397 Intrinsic<[], [], [IntrConvergent, IntrNoCallback]>; 1398 def int_nvvm_barrier_cluster_arrive_relaxed : 1399 Intrinsic<[], [], [IntrConvergent, IntrNoCallback]>; 1400 def int_nvvm_barrier_cluster_wait : 1401 Intrinsic<[], [], [IntrConvergent, IntrNoCallback]>; 1402 1403 // 'aligned' versions of the above barrier.cluster.* intrinsics 1404 def int_nvvm_barrier_cluster_arrive_aligned : 1405 Intrinsic<[], [], [IntrConvergent, IntrNoCallback]>; 1406 def int_nvvm_barrier_cluster_arrive_relaxed_aligned : 1407 Intrinsic<[], [], [IntrConvergent, IntrNoCallback]>; 1408 def int_nvvm_barrier_cluster_wait_aligned : 1409 Intrinsic<[], [], [IntrConvergent, IntrNoCallback]>; 1410 1411 // Membar 1412 def int_nvvm_membar_cta : ClangBuiltin<"__nvvm_membar_cta">, 1413 Intrinsic<[], [], [IntrNoCallback]>; 1414 def int_nvvm_membar_gl : ClangBuiltin<"__nvvm_membar_gl">, 1415 Intrinsic<[], [], [IntrNoCallback]>; 1416 def int_nvvm_membar_sys : ClangBuiltin<"__nvvm_membar_sys">, 1417 Intrinsic<[], [], [IntrNoCallback]>; 1418 def int_nvvm_fence_sc_cluster: 1419 Intrinsic<[], [], [IntrNoCallback]>; 1420 1421// Async Copy 1422def int_nvvm_cp_async_mbarrier_arrive : 1423 ClangBuiltin<"__nvvm_cp_async_mbarrier_arrive">, 1424 Intrinsic<[],[llvm_ptr_ty],[IntrConvergent, IntrNoCallback]>; 1425def int_nvvm_cp_async_mbarrier_arrive_shared : 1426 ClangBuiltin<"__nvvm_cp_async_mbarrier_arrive_shared">, 1427 Intrinsic<[],[llvm_shared_ptr_ty],[IntrConvergent, IntrNoCallback]>; 1428def int_nvvm_cp_async_mbarrier_arrive_noinc : 1429 ClangBuiltin<"__nvvm_cp_async_mbarrier_arrive_noinc">, 1430 Intrinsic<[],[llvm_ptr_ty],[IntrConvergent, IntrNoCallback]>; 1431def int_nvvm_cp_async_mbarrier_arrive_noinc_shared : 1432 ClangBuiltin<"__nvvm_cp_async_mbarrier_arrive_noinc_shared">, 1433 Intrinsic<[],[llvm_shared_ptr_ty],[IntrConvergent, IntrNoCallback]>; 1434 1435multiclass CP_ASYNC_SHARED_GLOBAL<string n, string cc> { 1436 def NAME: Intrinsic<[],[llvm_shared_ptr_ty, llvm_global_ptr_ty], 1437 [IntrArgMemOnly, IntrNoCallback, NoAlias<ArgIndex<0>>, NoAlias<ArgIndex<1>>, 1438 WriteOnly<ArgIndex<0>>, ReadOnly<ArgIndex<1>>], 1439 "llvm.nvvm.cp.async." # cc # ".shared.global." # n>; 1440 def _s: Intrinsic<[],[llvm_shared_ptr_ty, llvm_global_ptr_ty, llvm_i32_ty], 1441 [IntrArgMemOnly, IntrNoCallback, NoAlias<ArgIndex<0>>, NoAlias<ArgIndex<1>>, 1442 WriteOnly<ArgIndex<0>>, ReadOnly<ArgIndex<1>>], 1443 "llvm.nvvm.cp.async." # cc # ".shared.global." # n # ".s">; 1444} 1445 1446defm int_nvvm_cp_async_ca_shared_global_4 : CP_ASYNC_SHARED_GLOBAL<"4", "ca">; 1447defm int_nvvm_cp_async_ca_shared_global_8 : CP_ASYNC_SHARED_GLOBAL<"8", "ca">; 1448defm int_nvvm_cp_async_ca_shared_global_16 : CP_ASYNC_SHARED_GLOBAL<"16", "ca">; 1449defm int_nvvm_cp_async_cg_shared_global_16 : CP_ASYNC_SHARED_GLOBAL<"16", "cg">; 1450 1451def int_nvvm_cp_async_commit_group : 1452 ClangBuiltin<"__nvvm_cp_async_commit_group">, 1453 Intrinsic<[],[],[]>; 1454 1455def int_nvvm_cp_async_wait_group : 1456 ClangBuiltin<"__nvvm_cp_async_wait_group">, 1457 Intrinsic<[],[llvm_i32_ty],[ImmArg<ArgIndex<0>>]>; 1458 1459def int_nvvm_cp_async_wait_all : 1460 ClangBuiltin<"__nvvm_cp_async_wait_all">, 1461 Intrinsic<[],[],[]>; 1462 1463// cp.async.bulk variants of the commit/wait group 1464def int_nvvm_cp_async_bulk_commit_group : 1465 Intrinsic<[],[],[]>; 1466 1467def int_nvvm_cp_async_bulk_wait_group : 1468 Intrinsic<[],[llvm_i32_ty],[ImmArg<ArgIndex<0>>]>; 1469 1470def int_nvvm_cp_async_bulk_wait_group_read : 1471 Intrinsic<[],[llvm_i32_ty],[ImmArg<ArgIndex<0>>]>; 1472 1473// mbarrier 1474def int_nvvm_mbarrier_init : ClangBuiltin<"__nvvm_mbarrier_init">, 1475 Intrinsic<[],[llvm_ptr_ty, llvm_i32_ty],[IntrConvergent, IntrNoCallback]>; 1476def int_nvvm_mbarrier_init_shared : 1477 ClangBuiltin<"__nvvm_mbarrier_init_shared">, 1478 Intrinsic<[],[llvm_shared_ptr_ty, llvm_i32_ty],[IntrConvergent, IntrNoCallback]>; 1479 1480def int_nvvm_mbarrier_inval : ClangBuiltin<"__nvvm_mbarrier_inval">, 1481 Intrinsic<[],[llvm_ptr_ty], 1482 [IntrConvergent, IntrWriteMem, IntrArgMemOnly, IntrNoCallback, 1483 WriteOnly<ArgIndex<0>>, NoCapture<ArgIndex<0>>]>; 1484def int_nvvm_mbarrier_inval_shared : 1485 ClangBuiltin<"__nvvm_mbarrier_inval_shared">, 1486 Intrinsic<[],[llvm_shared_ptr_ty], 1487 [IntrConvergent, IntrWriteMem, IntrArgMemOnly, IntrNoCallback, 1488 WriteOnly<ArgIndex<0>>, NoCapture<ArgIndex<0>>]>; 1489 1490def int_nvvm_mbarrier_arrive : ClangBuiltin<"__nvvm_mbarrier_arrive">, 1491 Intrinsic<[llvm_i64_ty],[llvm_ptr_ty],[IntrConvergent, IntrNoCallback]>; 1492def int_nvvm_mbarrier_arrive_shared : 1493 ClangBuiltin<"__nvvm_mbarrier_arrive_shared">, 1494 Intrinsic<[llvm_i64_ty],[llvm_shared_ptr_ty],[IntrConvergent, IntrNoCallback]>; 1495def int_nvvm_mbarrier_arrive_noComplete : 1496 ClangBuiltin<"__nvvm_mbarrier_arrive_noComplete">, 1497 Intrinsic<[llvm_i64_ty],[llvm_ptr_ty, llvm_i32_ty],[IntrConvergent, IntrNoCallback]>; 1498def int_nvvm_mbarrier_arrive_noComplete_shared : 1499 ClangBuiltin<"__nvvm_mbarrier_arrive_noComplete_shared">, 1500 Intrinsic<[llvm_i64_ty],[llvm_shared_ptr_ty, 1501 llvm_i32_ty],[IntrConvergent, IntrNoCallback]>; 1502 1503def int_nvvm_mbarrier_arrive_drop : 1504 ClangBuiltin<"__nvvm_mbarrier_arrive_drop">, 1505 Intrinsic<[llvm_i64_ty],[llvm_ptr_ty],[IntrConvergent, IntrNoCallback]>; 1506def int_nvvm_mbarrier_arrive_drop_shared : 1507 ClangBuiltin<"__nvvm_mbarrier_arrive_drop_shared">, 1508 Intrinsic<[llvm_i64_ty],[llvm_shared_ptr_ty],[IntrConvergent, IntrNoCallback]>; 1509def int_nvvm_mbarrier_arrive_drop_noComplete : 1510 ClangBuiltin<"__nvvm_mbarrier_arrive_drop_noComplete">, 1511 Intrinsic<[llvm_i64_ty],[llvm_ptr_ty, llvm_i32_ty],[IntrConvergent, IntrNoCallback]>; 1512def int_nvvm_mbarrier_arrive_drop_noComplete_shared : 1513 ClangBuiltin<"__nvvm_mbarrier_arrive_drop_noComplete_shared">, 1514 Intrinsic<[llvm_i64_ty],[llvm_shared_ptr_ty, 1515 llvm_i32_ty],[IntrConvergent, IntrNoCallback]>; 1516 1517def int_nvvm_mbarrier_test_wait : 1518 ClangBuiltin<"__nvvm_mbarrier_test_wait">, 1519 Intrinsic<[llvm_i1_ty],[llvm_ptr_ty, llvm_i64_ty],[IntrConvergent, IntrNoCallback]>; 1520def int_nvvm_mbarrier_test_wait_shared : 1521 ClangBuiltin<"__nvvm_mbarrier_test_wait_shared">, 1522 Intrinsic<[llvm_i1_ty],[llvm_shared_ptr_ty, llvm_i64_ty],[IntrConvergent, IntrNoCallback]>; 1523 1524def int_nvvm_mbarrier_pending_count : 1525 ClangBuiltin<"__nvvm_mbarrier_pending_count">, 1526 Intrinsic<[llvm_i32_ty],[llvm_i64_ty],[IntrNoMem, IntrConvergent, IntrNoCallback]>; 1527 1528// Generated within nvvm. Use for ldu on sm_20 or later. Second arg is the 1529// pointer's alignment. 1530def int_nvvm_ldu_global_i : Intrinsic<[llvm_anyint_ty], 1531 [llvm_anyptr_ty, llvm_i32_ty], 1532 [IntrReadMem, IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>], 1533 "llvm.nvvm.ldu.global.i">; 1534def int_nvvm_ldu_global_f : Intrinsic<[llvm_anyfloat_ty], 1535 [llvm_anyptr_ty, llvm_i32_ty], 1536 [IntrReadMem, IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>], 1537 "llvm.nvvm.ldu.global.f">; 1538def int_nvvm_ldu_global_p : Intrinsic<[llvm_anyptr_ty], 1539 [llvm_anyptr_ty, llvm_i32_ty], 1540 [IntrReadMem, IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>], 1541 "llvm.nvvm.ldu.global.p">; 1542 1543// Generated within nvvm. Use for ldg on sm_35 or later. Second arg is the 1544// pointer's alignment. 1545def int_nvvm_ldg_global_i : Intrinsic<[llvm_anyint_ty], 1546 [llvm_anyptr_ty, llvm_i32_ty], 1547 [IntrReadMem, IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>], 1548 "llvm.nvvm.ldg.global.i">; 1549def int_nvvm_ldg_global_f : Intrinsic<[llvm_anyfloat_ty], 1550 [llvm_anyptr_ty, llvm_i32_ty], 1551 [IntrReadMem, IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>], 1552 "llvm.nvvm.ldg.global.f">; 1553def int_nvvm_ldg_global_p : Intrinsic<[llvm_anyptr_ty], 1554 [llvm_anyptr_ty, llvm_i32_ty], 1555 [IntrReadMem, IntrArgMemOnly, IntrNoCallback, NoCapture<ArgIndex<0>>], 1556 "llvm.nvvm.ldg.global.p">; 1557 1558// Use for generic pointers 1559// - These intrinsics are used to convert address spaces. 1560// - The input pointer and output pointer must have the same type, except for 1561// the address-space. (This restriction is not enforced here as there is 1562// currently no way to describe it). 1563// - This complements the llvm bitcast, which can be used to cast one type 1564// of pointer to another type of pointer, while the address space remains 1565// the same. 1566def int_nvvm_ptr_local_to_gen: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1567 [llvm_anyptr_ty], [IntrNoMem, IntrSpeculatable], 1568 "llvm.nvvm.ptr.local.to.gen">; 1569def int_nvvm_ptr_shared_to_gen: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1570 [llvm_anyptr_ty], [IntrNoMem, IntrSpeculatable], 1571 "llvm.nvvm.ptr.shared.to.gen">; 1572def int_nvvm_ptr_global_to_gen: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1573 [llvm_anyptr_ty], [IntrNoMem, IntrSpeculatable], 1574 "llvm.nvvm.ptr.global.to.gen">; 1575def int_nvvm_ptr_constant_to_gen: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1576 [llvm_anyptr_ty], [IntrNoMem, IntrSpeculatable], 1577 "llvm.nvvm.ptr.constant.to.gen">; 1578 1579def int_nvvm_ptr_gen_to_global: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1580 [llvm_anyptr_ty], [IntrNoMem, IntrSpeculatable], 1581 "llvm.nvvm.ptr.gen.to.global">; 1582def int_nvvm_ptr_gen_to_shared: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1583 [llvm_anyptr_ty], [IntrNoMem, IntrSpeculatable], 1584 "llvm.nvvm.ptr.gen.to.shared">; 1585def int_nvvm_ptr_gen_to_local: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1586 [llvm_anyptr_ty], [IntrNoMem, IntrSpeculatable], 1587 "llvm.nvvm.ptr.gen.to.local">; 1588def int_nvvm_ptr_gen_to_constant: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1589 [llvm_anyptr_ty], [IntrNoMem, IntrSpeculatable], 1590 "llvm.nvvm.ptr.gen.to.constant">; 1591 1592// Used in nvvm internally to help address space opt and ptx code generation 1593// This is for params that are passed to kernel functions by pointer by-val. 1594def int_nvvm_ptr_gen_to_param: Intrinsic<[llvm_anyptr_ty], 1595 [llvm_anyptr_ty], 1596 [IntrNoMem, IntrSpeculatable, IntrNoCallback], 1597 "llvm.nvvm.ptr.gen.to.param">; 1598 1599// sm70+, PTX7.7+ 1600def int_nvvm_ptr_param_to_gen: DefaultAttrsIntrinsic<[llvm_anyptr_ty], 1601 [llvm_anyptr_ty], 1602 [IntrNoMem, IntrSpeculatable, IntrNoCallback], 1603 "llvm.nvvm.ptr.param.to.gen">; 1604 1605// Move intrinsics, used in nvvm internally 1606 1607def int_nvvm_move_i16 : Intrinsic<[llvm_i16_ty], [llvm_i16_ty], [IntrNoMem], 1608 "llvm.nvvm.move.i16">; 1609def int_nvvm_move_i32 : Intrinsic<[llvm_i32_ty], [llvm_i32_ty], [IntrNoMem], 1610 "llvm.nvvm.move.i32">; 1611def int_nvvm_move_i64 : Intrinsic<[llvm_i64_ty], [llvm_i64_ty], [IntrNoMem], 1612 "llvm.nvvm.move.i64">; 1613def int_nvvm_move_float : Intrinsic<[llvm_float_ty], [llvm_float_ty], 1614 [IntrNoMem], "llvm.nvvm.move.float">; 1615def int_nvvm_move_double : Intrinsic<[llvm_double_ty], [llvm_double_ty], 1616 [IntrNoMem], "llvm.nvvm.move.double">; 1617def int_nvvm_move_ptr : Intrinsic<[llvm_anyptr_ty], [llvm_anyptr_ty], 1618 [IntrNoMem, NoCapture<ArgIndex<0>>], "llvm.nvvm.move.ptr">; 1619 1620 1621// For getting the handle from a texture or surface variable 1622def int_nvvm_texsurf_handle 1623 : Intrinsic<[llvm_i64_ty], [llvm_metadata_ty, llvm_anyptr_ty], 1624 [IntrNoMem], "llvm.nvvm.texsurf.handle">; 1625def int_nvvm_texsurf_handle_internal 1626 : Intrinsic<[llvm_i64_ty], [llvm_anyptr_ty], 1627 [IntrNoMem], "llvm.nvvm.texsurf.handle.internal">; 1628 1629/// Error / Warn 1630def int_nvvm_compiler_error : 1631 Intrinsic<[], [llvm_anyptr_ty], [], "llvm.nvvm.compiler.error">; 1632def int_nvvm_compiler_warn : 1633 Intrinsic<[], [llvm_anyptr_ty], [], "llvm.nvvm.compiler.warn">; 1634 1635def int_nvvm_reflect : 1636 Intrinsic<[llvm_i32_ty], [llvm_ptr_ty], [IntrNoMem], "llvm.nvvm.reflect">, 1637 ClangBuiltin<"__nvvm_reflect">; 1638 1639// isspacep.{const, global, local, shared} 1640def int_nvvm_isspacep_const 1641 : DefaultAttrsIntrinsic<[llvm_i1_ty], [llvm_ptr_ty], 1642 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 1643 "llvm.nvvm.isspacep.const">, 1644 ClangBuiltin<"__nvvm_isspacep_const">; 1645def int_nvvm_isspacep_global 1646 : DefaultAttrsIntrinsic<[llvm_i1_ty], [llvm_ptr_ty], 1647 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 1648 "llvm.nvvm.isspacep.global">, 1649 ClangBuiltin<"__nvvm_isspacep_global">; 1650def int_nvvm_isspacep_local 1651 : DefaultAttrsIntrinsic<[llvm_i1_ty], [llvm_ptr_ty], 1652 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 1653 "llvm.nvvm.isspacep.local">, 1654 ClangBuiltin<"__nvvm_isspacep_local">; 1655def int_nvvm_isspacep_shared 1656 : DefaultAttrsIntrinsic<[llvm_i1_ty], [llvm_ptr_ty], 1657 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 1658 "llvm.nvvm.isspacep.shared">, 1659 ClangBuiltin<"__nvvm_isspacep_shared">; 1660def int_nvvm_isspacep_shared_cluster 1661 : DefaultAttrsIntrinsic<[llvm_i1_ty], [llvm_ptr_ty], 1662 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 1663 "llvm.nvvm.isspacep.shared.cluster">; 1664 1665// Environment register read 1666def int_nvvm_read_ptx_sreg_envreg0 1667 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1668 "llvm.nvvm.read.ptx.sreg.envreg0">, 1669 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg0">; 1670def int_nvvm_read_ptx_sreg_envreg1 1671 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1672 "llvm.nvvm.read.ptx.sreg.envreg1">, 1673 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg1">; 1674def int_nvvm_read_ptx_sreg_envreg2 1675 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1676 "llvm.nvvm.read.ptx.sreg.envreg2">, 1677 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg2">; 1678def int_nvvm_read_ptx_sreg_envreg3 1679 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1680 "llvm.nvvm.read.ptx.sreg.envreg3">, 1681 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg3">; 1682def int_nvvm_read_ptx_sreg_envreg4 1683 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1684 "llvm.nvvm.read.ptx.sreg.envreg4">, 1685 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg4">; 1686def int_nvvm_read_ptx_sreg_envreg5 1687 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1688 "llvm.nvvm.read.ptx.sreg.envreg5">, 1689 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg5">; 1690def int_nvvm_read_ptx_sreg_envreg6 1691 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1692 "llvm.nvvm.read.ptx.sreg.envreg6">, 1693 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg6">; 1694def int_nvvm_read_ptx_sreg_envreg7 1695 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1696 "llvm.nvvm.read.ptx.sreg.envreg7">, 1697 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg7">; 1698def int_nvvm_read_ptx_sreg_envreg8 1699 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1700 "llvm.nvvm.read.ptx.sreg.envreg8">, 1701 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg8">; 1702def int_nvvm_read_ptx_sreg_envreg9 1703 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1704 "llvm.nvvm.read.ptx.sreg.envreg9">, 1705 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg9">; 1706def int_nvvm_read_ptx_sreg_envreg10 1707 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1708 "llvm.nvvm.read.ptx.sreg.envreg10">, 1709 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg10">; 1710def int_nvvm_read_ptx_sreg_envreg11 1711 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1712 "llvm.nvvm.read.ptx.sreg.envreg11">, 1713 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg11">; 1714def int_nvvm_read_ptx_sreg_envreg12 1715 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1716 "llvm.nvvm.read.ptx.sreg.envreg12">, 1717 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg12">; 1718def int_nvvm_read_ptx_sreg_envreg13 1719 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1720 "llvm.nvvm.read.ptx.sreg.envreg13">, 1721 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg13">; 1722def int_nvvm_read_ptx_sreg_envreg14 1723 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1724 "llvm.nvvm.read.ptx.sreg.envreg14">, 1725 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg14">; 1726def int_nvvm_read_ptx_sreg_envreg15 1727 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1728 "llvm.nvvm.read.ptx.sreg.envreg15">, 1729 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg15">; 1730def int_nvvm_read_ptx_sreg_envreg16 1731 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1732 "llvm.nvvm.read.ptx.sreg.envreg16">, 1733 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg16">; 1734def int_nvvm_read_ptx_sreg_envreg17 1735 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1736 "llvm.nvvm.read.ptx.sreg.envreg17">, 1737 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg17">; 1738def int_nvvm_read_ptx_sreg_envreg18 1739 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1740 "llvm.nvvm.read.ptx.sreg.envreg18">, 1741 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg18">; 1742def int_nvvm_read_ptx_sreg_envreg19 1743 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1744 "llvm.nvvm.read.ptx.sreg.envreg19">, 1745 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg19">; 1746def int_nvvm_read_ptx_sreg_envreg20 1747 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1748 "llvm.nvvm.read.ptx.sreg.envreg20">, 1749 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg20">; 1750def int_nvvm_read_ptx_sreg_envreg21 1751 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1752 "llvm.nvvm.read.ptx.sreg.envreg21">, 1753 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg21">; 1754def int_nvvm_read_ptx_sreg_envreg22 1755 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1756 "llvm.nvvm.read.ptx.sreg.envreg22">, 1757 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg22">; 1758def int_nvvm_read_ptx_sreg_envreg23 1759 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1760 "llvm.nvvm.read.ptx.sreg.envreg23">, 1761 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg23">; 1762def int_nvvm_read_ptx_sreg_envreg24 1763 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1764 "llvm.nvvm.read.ptx.sreg.envreg24">, 1765 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg24">; 1766def int_nvvm_read_ptx_sreg_envreg25 1767 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1768 "llvm.nvvm.read.ptx.sreg.envreg25">, 1769 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg25">; 1770def int_nvvm_read_ptx_sreg_envreg26 1771 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1772 "llvm.nvvm.read.ptx.sreg.envreg26">, 1773 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg26">; 1774def int_nvvm_read_ptx_sreg_envreg27 1775 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1776 "llvm.nvvm.read.ptx.sreg.envreg27">, 1777 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg27">; 1778def int_nvvm_read_ptx_sreg_envreg28 1779 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1780 "llvm.nvvm.read.ptx.sreg.envreg28">, 1781 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg28">; 1782def int_nvvm_read_ptx_sreg_envreg29 1783 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1784 "llvm.nvvm.read.ptx.sreg.envreg29">, 1785 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg29">; 1786def int_nvvm_read_ptx_sreg_envreg30 1787 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1788 "llvm.nvvm.read.ptx.sreg.envreg30">, 1789 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg30">; 1790def int_nvvm_read_ptx_sreg_envreg31 1791 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 1792 "llvm.nvvm.read.ptx.sreg.envreg31">, 1793 ClangBuiltin<"__nvvm_read_ptx_sreg_envreg31">; 1794 1795 1796// Texture Fetch 1797// texmode_independent 1798def int_nvvm_tex_1d_v4f32_s32 1799 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1800 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty], [], 1801 "llvm.nvvm.tex.1d.v4f32.s32">; 1802def int_nvvm_tex_1d_v4f32_f32 1803 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1804 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty], [], 1805 "llvm.nvvm.tex.1d.v4f32.f32">; 1806def int_nvvm_tex_1d_level_v4f32_f32 1807 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1808 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 1809 "llvm.nvvm.tex.1d.level.v4f32.f32">; 1810def int_nvvm_tex_1d_grad_v4f32_f32 1811 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1812 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1813 llvm_float_ty], [], 1814 "llvm.nvvm.tex.1d.grad.v4f32.f32">; 1815def int_nvvm_tex_1d_v4s32_s32 1816 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1817 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty], [], 1818 "llvm.nvvm.tex.1d.v4s32.s32">; 1819def int_nvvm_tex_1d_v4s32_f32 1820 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1821 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty], [], 1822 "llvm.nvvm.tex.1d.v4s32.f32">; 1823def int_nvvm_tex_1d_level_v4s32_f32 1824 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1825 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 1826 "llvm.nvvm.tex.1d.level.v4s32.f32">; 1827def int_nvvm_tex_1d_grad_v4s32_f32 1828 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1829 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1830 llvm_float_ty], [], 1831 "llvm.nvvm.tex.1d.grad.v4s32.f32">; 1832def int_nvvm_tex_1d_v4u32_s32 1833 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1834 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty], [], 1835 "llvm.nvvm.tex.1d.v4u32.s32">; 1836def int_nvvm_tex_1d_v4u32_f32 1837 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1838 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty], [], 1839 "llvm.nvvm.tex.1d.v4u32.f32">; 1840def int_nvvm_tex_1d_level_v4u32_f32 1841 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1842 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 1843 "llvm.nvvm.tex.1d.level.v4u32.f32">; 1844def int_nvvm_tex_1d_grad_v4u32_f32 1845 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1846 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1847 llvm_float_ty], [], 1848 "llvm.nvvm.tex.1d.grad.v4u32.f32">; 1849 1850def int_nvvm_tex_1d_array_v4f32_s32 1851 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1852 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 1853 "llvm.nvvm.tex.1d.array.v4f32.s32">; 1854def int_nvvm_tex_1d_array_v4f32_f32 1855 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1856 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty], [], 1857 "llvm.nvvm.tex.1d.array.v4f32.f32">; 1858def int_nvvm_tex_1d_array_level_v4f32_f32 1859 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1860 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1861 llvm_float_ty], [], 1862 "llvm.nvvm.tex.1d.array.level.v4f32.f32">; 1863def int_nvvm_tex_1d_array_grad_v4f32_f32 1864 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1865 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1866 llvm_float_ty, llvm_float_ty], [], 1867 "llvm.nvvm.tex.1d.array.grad.v4f32.f32">; 1868def int_nvvm_tex_1d_array_v4s32_s32 1869 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1870 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 1871 "llvm.nvvm.tex.1d.array.v4s32.s32">; 1872def int_nvvm_tex_1d_array_v4s32_f32 1873 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1874 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty], [], 1875 "llvm.nvvm.tex.1d.array.v4s32.f32">; 1876def int_nvvm_tex_1d_array_level_v4s32_f32 1877 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1878 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1879 llvm_float_ty], [], 1880 "llvm.nvvm.tex.1d.array.level.v4s32.f32">; 1881def int_nvvm_tex_1d_array_grad_v4s32_f32 1882 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1883 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1884 llvm_float_ty, llvm_float_ty], [], 1885 "llvm.nvvm.tex.1d.array.grad.v4s32.f32">; 1886def int_nvvm_tex_1d_array_v4u32_s32 1887 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1888 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 1889 "llvm.nvvm.tex.1d.array.v4u32.s32">; 1890def int_nvvm_tex_1d_array_v4u32_f32 1891 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1892 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty], [], 1893 "llvm.nvvm.tex.1d.array.v4u32.f32">; 1894def int_nvvm_tex_1d_array_level_v4u32_f32 1895 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1896 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1897 llvm_float_ty], [], 1898 "llvm.nvvm.tex.1d.array.level.v4u32.f32">; 1899def int_nvvm_tex_1d_array_grad_v4u32_f32 1900 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1901 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1902 llvm_float_ty, llvm_float_ty], [], 1903 "llvm.nvvm.tex.1d.array.grad.v4u32.f32">; 1904 1905def int_nvvm_tex_2d_v4f32_s32 1906 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1907 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 1908 "llvm.nvvm.tex.2d.v4f32.s32">; 1909def int_nvvm_tex_2d_v4f32_f32 1910 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1911 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 1912 "llvm.nvvm.tex.2d.v4f32.f32">; 1913def int_nvvm_tex_2d_level_v4f32_f32 1914 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1915 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1916 llvm_float_ty], [], 1917 "llvm.nvvm.tex.2d.level.v4f32.f32">; 1918def int_nvvm_tex_2d_grad_v4f32_f32 1919 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1920 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1921 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 1922 "llvm.nvvm.tex.2d.grad.v4f32.f32">; 1923def int_nvvm_tex_2d_v4s32_s32 1924 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1925 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 1926 "llvm.nvvm.tex.2d.v4s32.s32">; 1927def int_nvvm_tex_2d_v4s32_f32 1928 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1929 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 1930 "llvm.nvvm.tex.2d.v4s32.f32">; 1931def int_nvvm_tex_2d_level_v4s32_f32 1932 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1933 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1934 llvm_float_ty], [], 1935 "llvm.nvvm.tex.2d.level.v4s32.f32">; 1936def int_nvvm_tex_2d_grad_v4s32_f32 1937 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1938 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1939 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 1940 "llvm.nvvm.tex.2d.grad.v4s32.f32">; 1941def int_nvvm_tex_2d_v4u32_s32 1942 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1943 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 1944 "llvm.nvvm.tex.2d.v4u32.s32">; 1945def int_nvvm_tex_2d_v4u32_f32 1946 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1947 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 1948 "llvm.nvvm.tex.2d.v4u32.f32">; 1949def int_nvvm_tex_2d_level_v4u32_f32 1950 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1951 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1952 llvm_float_ty], [], 1953 "llvm.nvvm.tex.2d.level.v4u32.f32">; 1954def int_nvvm_tex_2d_grad_v4u32_f32 1955 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1956 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 1957 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 1958 "llvm.nvvm.tex.2d.grad.v4u32.f32">; 1959 1960def int_nvvm_tex_2d_array_v4f32_s32 1961 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1962 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 1963 llvm_i32_ty], [], 1964 "llvm.nvvm.tex.2d.array.v4f32.s32">; 1965def int_nvvm_tex_2d_array_v4f32_f32 1966 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1967 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1968 llvm_float_ty], [], 1969 "llvm.nvvm.tex.2d.array.v4f32.f32">; 1970def int_nvvm_tex_2d_array_level_v4f32_f32 1971 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1972 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1973 llvm_float_ty, llvm_float_ty], [], 1974 "llvm.nvvm.tex.2d.array.level.v4f32.f32">; 1975def int_nvvm_tex_2d_array_grad_v4f32_f32 1976 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 1977 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1978 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 1979 llvm_float_ty], [], 1980 "llvm.nvvm.tex.2d.array.grad.v4f32.f32">; 1981def int_nvvm_tex_2d_array_v4s32_s32 1982 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1983 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 1984 llvm_i32_ty], [], 1985 "llvm.nvvm.tex.2d.array.v4s32.s32">; 1986def int_nvvm_tex_2d_array_v4s32_f32 1987 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1988 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1989 llvm_float_ty], [], 1990 "llvm.nvvm.tex.2d.array.v4s32.f32">; 1991def int_nvvm_tex_2d_array_level_v4s32_f32 1992 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1993 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1994 llvm_float_ty, llvm_float_ty], [], 1995 "llvm.nvvm.tex.2d.array.level.v4s32.f32">; 1996def int_nvvm_tex_2d_array_grad_v4s32_f32 1997 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 1998 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 1999 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2000 llvm_float_ty], [], 2001 "llvm.nvvm.tex.2d.array.grad.v4s32.f32">; 2002def int_nvvm_tex_2d_array_v4u32_s32 2003 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2004 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 2005 llvm_i32_ty], [], 2006 "llvm.nvvm.tex.2d.array.v4u32.s32">; 2007def int_nvvm_tex_2d_array_v4u32_f32 2008 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2009 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2010 llvm_float_ty], [], 2011 "llvm.nvvm.tex.2d.array.v4u32.f32">; 2012def int_nvvm_tex_2d_array_level_v4u32_f32 2013 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2014 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2015 llvm_float_ty, llvm_float_ty], [], 2016 "llvm.nvvm.tex.2d.array.level.v4u32.f32">; 2017def int_nvvm_tex_2d_array_grad_v4u32_f32 2018 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2019 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2020 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2021 llvm_float_ty], [], 2022 "llvm.nvvm.tex.2d.array.grad.v4u32.f32">; 2023 2024def int_nvvm_tex_3d_v4f32_s32 2025 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2026 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2027 [], "llvm.nvvm.tex.3d.v4f32.s32">; 2028def int_nvvm_tex_3d_v4f32_f32 2029 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2030 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2031 llvm_float_ty], [], 2032 "llvm.nvvm.tex.3d.v4f32.f32">; 2033def int_nvvm_tex_3d_level_v4f32_f32 2034 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2035 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2036 llvm_float_ty, llvm_float_ty], [], 2037 "llvm.nvvm.tex.3d.level.v4f32.f32">; 2038def int_nvvm_tex_3d_grad_v4f32_f32 2039 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2040 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2041 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2042 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2043 "llvm.nvvm.tex.3d.grad.v4f32.f32">; 2044def int_nvvm_tex_3d_v4s32_s32 2045 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2046 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2047 [], "llvm.nvvm.tex.3d.v4s32.s32">; 2048def int_nvvm_tex_3d_v4s32_f32 2049 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2050 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2051 llvm_float_ty], [], 2052 "llvm.nvvm.tex.3d.v4s32.f32">; 2053def int_nvvm_tex_3d_level_v4s32_f32 2054 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2055 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2056 llvm_float_ty, llvm_float_ty], [], 2057 "llvm.nvvm.tex.3d.level.v4s32.f32">; 2058def int_nvvm_tex_3d_grad_v4s32_f32 2059 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2060 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2061 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2062 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2063 "llvm.nvvm.tex.3d.grad.v4s32.f32">; 2064def int_nvvm_tex_3d_v4u32_s32 2065 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2066 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2067 [], "llvm.nvvm.tex.3d.v4u32.s32">; 2068def int_nvvm_tex_3d_v4u32_f32 2069 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2070 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2071 llvm_float_ty], [], 2072 "llvm.nvvm.tex.3d.v4u32.f32">; 2073def int_nvvm_tex_3d_level_v4u32_f32 2074 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2075 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2076 llvm_float_ty, llvm_float_ty], [], 2077 "llvm.nvvm.tex.3d.level.v4u32.f32">; 2078def int_nvvm_tex_3d_grad_v4u32_f32 2079 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2080 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2081 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2082 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2083 "llvm.nvvm.tex.3d.grad.v4u32.f32">; 2084 2085def int_nvvm_tex_cube_v4f32_f32 2086 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2087 [llvm_i64_ty, llvm_i64_ty, 2088 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2089 "llvm.nvvm.tex.cube.v4f32.f32">; 2090def int_nvvm_tex_cube_level_v4f32_f32 2091 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2092 [llvm_i64_ty, llvm_i64_ty, 2093 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2094 "llvm.nvvm.tex.cube.level.v4f32.f32">; 2095def int_nvvm_tex_cube_v4s32_f32 2096 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2097 [llvm_i64_ty, llvm_i64_ty, 2098 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2099 "llvm.nvvm.tex.cube.v4s32.f32">; 2100def int_nvvm_tex_cube_level_v4s32_f32 2101 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2102 [llvm_i64_ty, llvm_i64_ty, 2103 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2104 "llvm.nvvm.tex.cube.level.v4s32.f32">; 2105def int_nvvm_tex_cube_v4u32_f32 2106 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2107 [llvm_i64_ty, llvm_i64_ty, 2108 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2109 "llvm.nvvm.tex.cube.v4u32.f32">; 2110def int_nvvm_tex_cube_level_v4u32_f32 2111 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2112 [llvm_i64_ty, llvm_i64_ty, 2113 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2114 "llvm.nvvm.tex.cube.level.v4u32.f32">; 2115 2116def int_nvvm_tex_cube_array_v4f32_f32 2117 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2118 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, 2119 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2120 "llvm.nvvm.tex.cube.array.v4f32.f32">; 2121def int_nvvm_tex_cube_array_level_v4f32_f32 2122 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2123 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, 2124 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2125 "llvm.nvvm.tex.cube.array.level.v4f32.f32">; 2126def int_nvvm_tex_cube_array_v4s32_f32 2127 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2128 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, 2129 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2130 "llvm.nvvm.tex.cube.array.v4s32.f32">; 2131def int_nvvm_tex_cube_array_level_v4s32_f32 2132 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2133 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, 2134 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2135 "llvm.nvvm.tex.cube.array.level.v4s32.f32">; 2136def int_nvvm_tex_cube_array_v4u32_f32 2137 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2138 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, 2139 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2140 "llvm.nvvm.tex.cube.array.v4u32.f32">; 2141def int_nvvm_tex_cube_array_level_v4u32_f32 2142 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2143 [llvm_i64_ty, llvm_i64_ty, llvm_i32_ty, 2144 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2145 "llvm.nvvm.tex.cube.array.level.v4u32.f32">; 2146 2147def int_nvvm_tld4_r_2d_v4f32_f32 2148 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2149 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2150 "llvm.nvvm.tld4.r.2d.v4f32.f32">; 2151def int_nvvm_tld4_g_2d_v4f32_f32 2152 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2153 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2154 "llvm.nvvm.tld4.g.2d.v4f32.f32">; 2155def int_nvvm_tld4_b_2d_v4f32_f32 2156 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2157 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2158 "llvm.nvvm.tld4.b.2d.v4f32.f32">; 2159def int_nvvm_tld4_a_2d_v4f32_f32 2160 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2161 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2162 "llvm.nvvm.tld4.a.2d.v4f32.f32">; 2163def int_nvvm_tld4_r_2d_v4s32_f32 2164 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2165 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2166 "llvm.nvvm.tld4.r.2d.v4s32.f32">; 2167def int_nvvm_tld4_g_2d_v4s32_f32 2168 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2169 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2170 "llvm.nvvm.tld4.g.2d.v4s32.f32">; 2171def int_nvvm_tld4_b_2d_v4s32_f32 2172 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2173 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2174 "llvm.nvvm.tld4.b.2d.v4s32.f32">; 2175def int_nvvm_tld4_a_2d_v4s32_f32 2176 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2177 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2178 "llvm.nvvm.tld4.a.2d.v4s32.f32">; 2179def int_nvvm_tld4_r_2d_v4u32_f32 2180 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2181 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2182 "llvm.nvvm.tld4.r.2d.v4u32.f32">; 2183def int_nvvm_tld4_g_2d_v4u32_f32 2184 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2185 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2186 "llvm.nvvm.tld4.g.2d.v4u32.f32">; 2187def int_nvvm_tld4_b_2d_v4u32_f32 2188 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2189 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2190 "llvm.nvvm.tld4.b.2d.v4u32.f32">; 2191def int_nvvm_tld4_a_2d_v4u32_f32 2192 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2193 [llvm_i64_ty, llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2194 "llvm.nvvm.tld4.a.2d.v4u32.f32">; 2195 2196 2197// texmode_unified 2198def int_nvvm_tex_unified_1d_v4f32_s32 2199 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2200 [llvm_i64_ty, llvm_i32_ty], [], 2201 "llvm.nvvm.tex.unified.1d.v4f32.s32">; 2202def int_nvvm_tex_unified_1d_v4f32_f32 2203 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2204 [llvm_i64_ty, llvm_float_ty], [], 2205 "llvm.nvvm.tex.unified.1d.v4f32.f32">; 2206def int_nvvm_tex_unified_1d_level_v4f32_f32 2207 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2208 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2209 "llvm.nvvm.tex.unified.1d.level.v4f32.f32">; 2210def int_nvvm_tex_unified_1d_grad_v4f32_f32 2211 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2212 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2213 llvm_float_ty], [], 2214 "llvm.nvvm.tex.unified.1d.grad.v4f32.f32">; 2215def int_nvvm_tex_unified_1d_v4s32_s32 2216 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2217 [llvm_i64_ty, llvm_i32_ty], [], 2218 "llvm.nvvm.tex.unified.1d.v4s32.s32">; 2219def int_nvvm_tex_unified_1d_v4s32_f32 2220 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2221 [llvm_i64_ty, llvm_float_ty], [], 2222 "llvm.nvvm.tex.unified.1d.v4s32.f32">; 2223def int_nvvm_tex_unified_1d_level_v4s32_f32 2224 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2225 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2226 "llvm.nvvm.tex.unified.1d.level.v4s32.f32">; 2227def int_nvvm_tex_unified_1d_grad_v4s32_f32 2228 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2229 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2230 llvm_float_ty], [], 2231 "llvm.nvvm.tex.unified.1d.grad.v4s32.f32">; 2232def int_nvvm_tex_unified_1d_v4u32_s32 2233 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2234 [llvm_i64_ty, llvm_i32_ty], [], 2235 "llvm.nvvm.tex.unified.1d.v4u32.s32">; 2236def int_nvvm_tex_unified_1d_v4u32_f32 2237 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2238 [llvm_i64_ty, llvm_float_ty], [], 2239 "llvm.nvvm.tex.unified.1d.v4u32.f32">; 2240def int_nvvm_tex_unified_1d_level_v4u32_f32 2241 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2242 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2243 "llvm.nvvm.tex.unified.1d.level.v4u32.f32">; 2244def int_nvvm_tex_unified_1d_grad_v4u32_f32 2245 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2246 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2247 llvm_float_ty], [], 2248 "llvm.nvvm.tex.unified.1d.grad.v4u32.f32">; 2249 2250def int_nvvm_tex_unified_1d_array_v4f32_s32 2251 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2252 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2253 "llvm.nvvm.tex.unified.1d.array.v4f32.s32">; 2254def int_nvvm_tex_unified_1d_array_v4f32_f32 2255 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2256 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty], [], 2257 "llvm.nvvm.tex.unified.1d.array.v4f32.f32">; 2258def int_nvvm_tex_unified_1d_array_level_v4f32_f32 2259 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2260 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2261 llvm_float_ty], [], 2262 "llvm.nvvm.tex.unified.1d.array.level.v4f32.f32">; 2263def int_nvvm_tex_unified_1d_array_grad_v4f32_f32 2264 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2265 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2266 llvm_float_ty, llvm_float_ty], [], 2267 "llvm.nvvm.tex.unified.1d.array.grad.v4f32.f32">; 2268def int_nvvm_tex_unified_1d_array_v4s32_s32 2269 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2270 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2271 "llvm.nvvm.tex.unified.1d.array.v4s32.s32">; 2272def int_nvvm_tex_unified_1d_array_v4s32_f32 2273 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2274 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty], [], 2275 "llvm.nvvm.tex.unified.1d.array.v4s32.f32">; 2276def int_nvvm_tex_unified_1d_array_level_v4s32_f32 2277 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2278 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2279 llvm_float_ty], [], 2280 "llvm.nvvm.tex.unified.1d.array.level.v4s32.f32">; 2281def int_nvvm_tex_unified_1d_array_grad_v4s32_f32 2282 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2283 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2284 llvm_float_ty, llvm_float_ty], [], 2285 "llvm.nvvm.tex.unified.1d.array.grad.v4s32.f32">; 2286def int_nvvm_tex_unified_1d_array_v4u32_s32 2287 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2288 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2289 "llvm.nvvm.tex.unified.1d.array.v4u32.s32">; 2290def int_nvvm_tex_unified_1d_array_v4u32_f32 2291 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2292 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty], [], 2293 "llvm.nvvm.tex.unified.1d.array.v4u32.f32">; 2294def int_nvvm_tex_unified_1d_array_level_v4u32_f32 2295 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2296 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2297 llvm_float_ty], [], 2298 "llvm.nvvm.tex.unified.1d.array.level.v4u32.f32">; 2299def int_nvvm_tex_unified_1d_array_grad_v4u32_f32 2300 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2301 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2302 llvm_float_ty, llvm_float_ty], [], 2303 "llvm.nvvm.tex.unified.1d.array.grad.v4u32.f32">; 2304 2305def int_nvvm_tex_unified_2d_v4f32_s32 2306 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2307 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2308 "llvm.nvvm.tex.unified.2d.v4f32.s32">; 2309def int_nvvm_tex_unified_2d_v4f32_f32 2310 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2311 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2312 "llvm.nvvm.tex.unified.2d.v4f32.f32">; 2313def int_nvvm_tex_unified_2d_level_v4f32_f32 2314 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2315 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2316 llvm_float_ty], [], 2317 "llvm.nvvm.tex.unified.2d.level.v4f32.f32">; 2318def int_nvvm_tex_unified_2d_grad_v4f32_f32 2319 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2320 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2321 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2322 "llvm.nvvm.tex.unified.2d.grad.v4f32.f32">; 2323def int_nvvm_tex_unified_2d_v4s32_s32 2324 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2325 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2326 "llvm.nvvm.tex.unified.2d.v4s32.s32">; 2327def int_nvvm_tex_unified_2d_v4s32_f32 2328 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2329 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2330 "llvm.nvvm.tex.unified.2d.v4s32.f32">; 2331def int_nvvm_tex_unified_2d_level_v4s32_f32 2332 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2333 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2334 llvm_float_ty], [], 2335 "llvm.nvvm.tex.unified.2d.level.v4s32.f32">; 2336def int_nvvm_tex_unified_2d_grad_v4s32_f32 2337 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2338 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2339 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2340 "llvm.nvvm.tex.unified.2d.grad.v4s32.f32">; 2341def int_nvvm_tex_unified_2d_v4u32_s32 2342 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2343 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2344 "llvm.nvvm.tex.unified.2d.v4u32.s32">; 2345def int_nvvm_tex_unified_2d_v4u32_f32 2346 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2347 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2348 "llvm.nvvm.tex.unified.2d.v4u32.f32">; 2349def int_nvvm_tex_unified_2d_level_v4u32_f32 2350 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2351 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2352 llvm_float_ty], [], 2353 "llvm.nvvm.tex.unified.2d.level.v4u32.f32">; 2354def int_nvvm_tex_unified_2d_grad_v4u32_f32 2355 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2356 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2357 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2358 "llvm.nvvm.tex.unified.2d.grad.v4u32.f32">; 2359 2360def int_nvvm_tex_unified_2d_array_v4f32_s32 2361 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2362 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 2363 llvm_i32_ty], [], 2364 "llvm.nvvm.tex.unified.2d.array.v4f32.s32">; 2365def int_nvvm_tex_unified_2d_array_v4f32_f32 2366 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2367 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2368 llvm_float_ty], [], 2369 "llvm.nvvm.tex.unified.2d.array.v4f32.f32">; 2370def int_nvvm_tex_unified_2d_array_level_v4f32_f32 2371 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2372 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2373 llvm_float_ty, llvm_float_ty], [], 2374 "llvm.nvvm.tex.unified.2d.array.level.v4f32.f32">; 2375def int_nvvm_tex_unified_2d_array_grad_v4f32_f32 2376 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2377 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2378 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2379 llvm_float_ty], [], 2380 "llvm.nvvm.tex.unified.2d.array.grad.v4f32.f32">; 2381def int_nvvm_tex_unified_2d_array_v4s32_s32 2382 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2383 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 2384 llvm_i32_ty], [], 2385 "llvm.nvvm.tex.unified.2d.array.v4s32.s32">; 2386def int_nvvm_tex_unified_2d_array_v4s32_f32 2387 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2388 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2389 llvm_float_ty], [], 2390 "llvm.nvvm.tex.unified.2d.array.v4s32.f32">; 2391def int_nvvm_tex_unified_2d_array_level_v4s32_f32 2392 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2393 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2394 llvm_float_ty, llvm_float_ty], [], 2395 "llvm.nvvm.tex.unified.2d.array.level.v4s32.f32">; 2396def int_nvvm_tex_unified_2d_array_grad_v4s32_f32 2397 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2398 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2399 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2400 llvm_float_ty], [], 2401 "llvm.nvvm.tex.unified.2d.array.grad.v4s32.f32">; 2402def int_nvvm_tex_unified_2d_array_v4u32_s32 2403 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2404 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 2405 llvm_i32_ty], [], 2406 "llvm.nvvm.tex.unified.2d.array.v4u32.s32">; 2407def int_nvvm_tex_unified_2d_array_v4u32_f32 2408 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2409 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2410 llvm_float_ty], [], 2411 "llvm.nvvm.tex.unified.2d.array.v4u32.f32">; 2412def int_nvvm_tex_unified_2d_array_level_v4u32_f32 2413 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2414 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2415 llvm_float_ty, llvm_float_ty], [], 2416 "llvm.nvvm.tex.unified.2d.array.level.v4u32.f32">; 2417def int_nvvm_tex_unified_2d_array_grad_v4u32_f32 2418 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2419 [llvm_i64_ty, llvm_i32_ty, llvm_float_ty, 2420 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2421 llvm_float_ty], [], 2422 "llvm.nvvm.tex.unified.2d.array.grad.v4u32.f32">; 2423 2424def int_nvvm_tex_unified_3d_v4f32_s32 2425 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2426 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2427 [], "llvm.nvvm.tex.unified.3d.v4f32.s32">; 2428def int_nvvm_tex_unified_3d_v4f32_f32 2429 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2430 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2431 llvm_float_ty], [], 2432 "llvm.nvvm.tex.unified.3d.v4f32.f32">; 2433def int_nvvm_tex_unified_3d_level_v4f32_f32 2434 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2435 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2436 llvm_float_ty, llvm_float_ty], [], 2437 "llvm.nvvm.tex.unified.3d.level.v4f32.f32">; 2438def int_nvvm_tex_unified_3d_grad_v4f32_f32 2439 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2440 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2441 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2442 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2443 "llvm.nvvm.tex.unified.3d.grad.v4f32.f32">; 2444def int_nvvm_tex_unified_3d_v4s32_s32 2445 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2446 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2447 [], "llvm.nvvm.tex.unified.3d.v4s32.s32">; 2448def int_nvvm_tex_unified_3d_v4s32_f32 2449 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2450 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2451 llvm_float_ty], [], 2452 "llvm.nvvm.tex.unified.3d.v4s32.f32">; 2453def int_nvvm_tex_unified_3d_level_v4s32_f32 2454 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2455 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2456 llvm_float_ty, llvm_float_ty], [], 2457 "llvm.nvvm.tex.unified.3d.level.v4s32.f32">; 2458def int_nvvm_tex_unified_3d_grad_v4s32_f32 2459 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2460 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2461 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2462 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2463 "llvm.nvvm.tex.unified.3d.grad.v4s32.f32">; 2464def int_nvvm_tex_unified_3d_v4u32_s32 2465 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2466 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2467 [], "llvm.nvvm.tex.unified.3d.v4u32.s32">; 2468def int_nvvm_tex_unified_3d_v4u32_f32 2469 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2470 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2471 llvm_float_ty], [], 2472 "llvm.nvvm.tex.unified.3d.v4u32.f32">; 2473def int_nvvm_tex_unified_3d_level_v4u32_f32 2474 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2475 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2476 llvm_float_ty, llvm_float_ty], [], 2477 "llvm.nvvm.tex.unified.3d.level.v4u32.f32">; 2478def int_nvvm_tex_unified_3d_grad_v4u32_f32 2479 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2480 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2481 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2482 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2483 "llvm.nvvm.tex.unified.3d.grad.v4u32.f32">; 2484 2485def int_nvvm_tex_unified_cube_v4f32_f32 2486 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2487 [llvm_i64_ty, 2488 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2489 "llvm.nvvm.tex.unified.cube.v4f32.f32">; 2490def int_nvvm_tex_unified_cube_level_v4f32_f32 2491 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2492 [llvm_i64_ty, 2493 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2494 "llvm.nvvm.tex.unified.cube.level.v4f32.f32">; 2495def int_nvvm_tex_unified_cube_v4s32_f32 2496 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2497 [llvm_i64_ty, 2498 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2499 "llvm.nvvm.tex.unified.cube.v4s32.f32">; 2500def int_nvvm_tex_unified_cube_level_v4s32_f32 2501 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2502 [llvm_i64_ty, 2503 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2504 "llvm.nvvm.tex.unified.cube.level.v4s32.f32">; 2505def int_nvvm_tex_unified_cube_v4u32_f32 2506 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2507 [llvm_i64_ty, 2508 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2509 "llvm.nvvm.tex.unified.cube.v4u32.f32">; 2510def int_nvvm_tex_unified_cube_level_v4u32_f32 2511 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2512 [llvm_i64_ty, 2513 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2514 "llvm.nvvm.tex.unified.cube.level.v4u32.f32">; 2515 2516def int_nvvm_tex_unified_cube_array_v4f32_f32 2517 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2518 [llvm_i64_ty, llvm_i32_ty, 2519 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2520 "llvm.nvvm.tex.unified.cube.array.v4f32.f32">; 2521def int_nvvm_tex_unified_cube_array_level_v4f32_f32 2522 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2523 [llvm_i64_ty, llvm_i32_ty, 2524 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2525 "llvm.nvvm.tex.unified.cube.array.level.v4f32.f32">; 2526def int_nvvm_tex_unified_cube_array_v4s32_f32 2527 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2528 [llvm_i64_ty, llvm_i32_ty, 2529 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2530 "llvm.nvvm.tex.unified.cube.array.v4s32.f32">; 2531def int_nvvm_tex_unified_cube_array_level_v4s32_f32 2532 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2533 [llvm_i64_ty, llvm_i32_ty, 2534 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2535 "llvm.nvvm.tex.unified.cube.array.level.v4s32.f32">; 2536def int_nvvm_tex_unified_cube_array_v4u32_f32 2537 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2538 [llvm_i64_ty, llvm_i32_ty, 2539 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2540 "llvm.nvvm.tex.unified.cube.array.v4u32.f32">; 2541def int_nvvm_tex_unified_cube_array_level_v4u32_f32 2542 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2543 [llvm_i64_ty, llvm_i32_ty, 2544 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2545 "llvm.nvvm.tex.unified.cube.array.level.v4u32.f32">; 2546 2547def int_nvvm_tex_unified_cube_grad_v4f32_f32 2548 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2549 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2550 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2551 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2552 "llvm.nvvm.tex.unified.cube.grad.v4f32.f32">; 2553def int_nvvm_tex_unified_cube_grad_v4s32_f32 2554 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2555 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2556 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2557 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2558 "llvm.nvvm.tex.unified.cube.grad.v4s32.f32">; 2559def int_nvvm_tex_unified_cube_grad_v4u32_f32 2560 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2561 [llvm_i64_ty, llvm_float_ty, llvm_float_ty, 2562 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2563 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2564 "llvm.nvvm.tex.unified.cube.grad.v4u32.f32">; 2565 2566def int_nvvm_tex_unified_cube_array_grad_v4f32_f32 2567 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2568 [llvm_i64_ty, llvm_i32_ty, 2569 llvm_float_ty, llvm_float_ty, 2570 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2571 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2572 "llvm.nvvm.tex.unified.cube.array.grad.v4f32.f32">; 2573def int_nvvm_tex_unified_cube_array_grad_v4s32_f32 2574 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2575 [llvm_i64_ty, llvm_i32_ty, 2576 llvm_float_ty, llvm_float_ty, 2577 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2578 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2579 "llvm.nvvm.tex.unified.cube.array.grad.v4s32.f32">; 2580def int_nvvm_tex_unified_cube_array_grad_v4u32_f32 2581 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2582 [llvm_i64_ty, llvm_i32_ty, 2583 llvm_float_ty, llvm_float_ty, 2584 llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty, 2585 llvm_float_ty, llvm_float_ty, llvm_float_ty], [], 2586 "llvm.nvvm.tex.unified.cube.array.grad.v4u32.f32">; 2587 2588def int_nvvm_tld4_unified_r_2d_v4f32_f32 2589 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2590 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2591 "llvm.nvvm.tld4.unified.r.2d.v4f32.f32">; 2592def int_nvvm_tld4_unified_g_2d_v4f32_f32 2593 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2594 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2595 "llvm.nvvm.tld4.unified.g.2d.v4f32.f32">; 2596def int_nvvm_tld4_unified_b_2d_v4f32_f32 2597 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2598 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2599 "llvm.nvvm.tld4.unified.b.2d.v4f32.f32">; 2600def int_nvvm_tld4_unified_a_2d_v4f32_f32 2601 : Intrinsic<[llvm_float_ty, llvm_float_ty, llvm_float_ty, llvm_float_ty], 2602 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2603 "llvm.nvvm.tld4.unified.a.2d.v4f32.f32">; 2604def int_nvvm_tld4_unified_r_2d_v4s32_f32 2605 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2606 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2607 "llvm.nvvm.tld4.unified.r.2d.v4s32.f32">; 2608def int_nvvm_tld4_unified_g_2d_v4s32_f32 2609 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2610 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2611 "llvm.nvvm.tld4.unified.g.2d.v4s32.f32">; 2612def int_nvvm_tld4_unified_b_2d_v4s32_f32 2613 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2614 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2615 "llvm.nvvm.tld4.unified.b.2d.v4s32.f32">; 2616def int_nvvm_tld4_unified_a_2d_v4s32_f32 2617 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2618 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2619 "llvm.nvvm.tld4.unified.a.2d.v4s32.f32">; 2620def int_nvvm_tld4_unified_r_2d_v4u32_f32 2621 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2622 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2623 "llvm.nvvm.tld4.unified.r.2d.v4u32.f32">; 2624def int_nvvm_tld4_unified_g_2d_v4u32_f32 2625 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2626 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2627 "llvm.nvvm.tld4.unified.g.2d.v4u32.f32">; 2628def int_nvvm_tld4_unified_b_2d_v4u32_f32 2629 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2630 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2631 "llvm.nvvm.tld4.unified.b.2d.v4u32.f32">; 2632def int_nvvm_tld4_unified_a_2d_v4u32_f32 2633 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2634 [llvm_i64_ty, llvm_float_ty, llvm_float_ty], [], 2635 "llvm.nvvm.tld4.unified.a.2d.v4u32.f32">; 2636 2637 2638//=== Surface Load 2639// .clamp variants 2640def int_nvvm_suld_1d_i8_clamp 2641 : Intrinsic<[llvm_i16_ty], 2642 [llvm_i64_ty, llvm_i32_ty], [], 2643 "llvm.nvvm.suld.1d.i8.clamp">; 2644def int_nvvm_suld_1d_i16_clamp 2645 : Intrinsic<[llvm_i16_ty], 2646 [llvm_i64_ty, llvm_i32_ty], [], 2647 "llvm.nvvm.suld.1d.i16.clamp">; 2648def int_nvvm_suld_1d_i32_clamp 2649 : Intrinsic<[llvm_i32_ty], 2650 [llvm_i64_ty, llvm_i32_ty], [], 2651 "llvm.nvvm.suld.1d.i32.clamp">; 2652def int_nvvm_suld_1d_i64_clamp 2653 : Intrinsic<[llvm_i64_ty], 2654 [llvm_i64_ty, llvm_i32_ty], [], 2655 "llvm.nvvm.suld.1d.i64.clamp">; 2656def int_nvvm_suld_1d_v2i8_clamp 2657 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2658 [llvm_i64_ty, llvm_i32_ty], [], 2659 "llvm.nvvm.suld.1d.v2i8.clamp">; 2660def int_nvvm_suld_1d_v2i16_clamp 2661 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2662 [llvm_i64_ty, llvm_i32_ty], [], 2663 "llvm.nvvm.suld.1d.v2i16.clamp">; 2664def int_nvvm_suld_1d_v2i32_clamp 2665 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 2666 [llvm_i64_ty, llvm_i32_ty], [], 2667 "llvm.nvvm.suld.1d.v2i32.clamp">; 2668def int_nvvm_suld_1d_v2i64_clamp 2669 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 2670 [llvm_i64_ty, llvm_i32_ty], [], 2671 "llvm.nvvm.suld.1d.v2i64.clamp">; 2672def int_nvvm_suld_1d_v4i8_clamp 2673 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2674 [llvm_i64_ty, llvm_i32_ty], [], 2675 "llvm.nvvm.suld.1d.v4i8.clamp">; 2676def int_nvvm_suld_1d_v4i16_clamp 2677 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2678 [llvm_i64_ty, llvm_i32_ty], [], 2679 "llvm.nvvm.suld.1d.v4i16.clamp">; 2680def int_nvvm_suld_1d_v4i32_clamp 2681 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2682 [llvm_i64_ty, llvm_i32_ty], [], 2683 "llvm.nvvm.suld.1d.v4i32.clamp">; 2684 2685def int_nvvm_suld_1d_array_i8_clamp 2686 : Intrinsic<[llvm_i16_ty], 2687 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2688 "llvm.nvvm.suld.1d.array.i8.clamp">; 2689def int_nvvm_suld_1d_array_i16_clamp 2690 : Intrinsic<[llvm_i16_ty], 2691 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2692 "llvm.nvvm.suld.1d.array.i16.clamp">; 2693def int_nvvm_suld_1d_array_i32_clamp 2694 : Intrinsic<[llvm_i32_ty], 2695 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2696 "llvm.nvvm.suld.1d.array.i32.clamp">; 2697def int_nvvm_suld_1d_array_i64_clamp 2698 : Intrinsic<[llvm_i64_ty], 2699 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2700 "llvm.nvvm.suld.1d.array.i64.clamp">; 2701def int_nvvm_suld_1d_array_v2i8_clamp 2702 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2703 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2704 "llvm.nvvm.suld.1d.array.v2i8.clamp">; 2705def int_nvvm_suld_1d_array_v2i16_clamp 2706 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2707 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2708 "llvm.nvvm.suld.1d.array.v2i16.clamp">; 2709def int_nvvm_suld_1d_array_v2i32_clamp 2710 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 2711 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2712 "llvm.nvvm.suld.1d.array.v2i32.clamp">; 2713def int_nvvm_suld_1d_array_v2i64_clamp 2714 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 2715 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2716 "llvm.nvvm.suld.1d.array.v2i64.clamp">; 2717def int_nvvm_suld_1d_array_v4i8_clamp 2718 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2719 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2720 "llvm.nvvm.suld.1d.array.v4i8.clamp">; 2721def int_nvvm_suld_1d_array_v4i16_clamp 2722 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2723 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2724 "llvm.nvvm.suld.1d.array.v4i16.clamp">; 2725def int_nvvm_suld_1d_array_v4i32_clamp 2726 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2727 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2728 "llvm.nvvm.suld.1d.array.v4i32.clamp">; 2729 2730def int_nvvm_suld_2d_i8_clamp 2731 : Intrinsic<[llvm_i16_ty], 2732 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2733 "llvm.nvvm.suld.2d.i8.clamp">; 2734def int_nvvm_suld_2d_i16_clamp 2735 : Intrinsic<[llvm_i16_ty], 2736 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2737 "llvm.nvvm.suld.2d.i16.clamp">; 2738def int_nvvm_suld_2d_i32_clamp 2739 : Intrinsic<[llvm_i32_ty], 2740 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2741 "llvm.nvvm.suld.2d.i32.clamp">; 2742def int_nvvm_suld_2d_i64_clamp 2743 : Intrinsic<[llvm_i64_ty], 2744 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2745 "llvm.nvvm.suld.2d.i64.clamp">; 2746def int_nvvm_suld_2d_v2i8_clamp 2747 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2748 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2749 "llvm.nvvm.suld.2d.v2i8.clamp">; 2750def int_nvvm_suld_2d_v2i16_clamp 2751 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2752 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2753 "llvm.nvvm.suld.2d.v2i16.clamp">; 2754def int_nvvm_suld_2d_v2i32_clamp 2755 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 2756 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2757 "llvm.nvvm.suld.2d.v2i32.clamp">; 2758def int_nvvm_suld_2d_v2i64_clamp 2759 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 2760 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2761 "llvm.nvvm.suld.2d.v2i64.clamp">; 2762def int_nvvm_suld_2d_v4i8_clamp 2763 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2764 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2765 "llvm.nvvm.suld.2d.v4i8.clamp">; 2766def int_nvvm_suld_2d_v4i16_clamp 2767 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2768 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2769 "llvm.nvvm.suld.2d.v4i16.clamp">; 2770def int_nvvm_suld_2d_v4i32_clamp 2771 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2772 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2773 "llvm.nvvm.suld.2d.v4i32.clamp">; 2774 2775def int_nvvm_suld_2d_array_i8_clamp 2776 : Intrinsic<[llvm_i16_ty], 2777 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2778 "llvm.nvvm.suld.2d.array.i8.clamp">; 2779def int_nvvm_suld_2d_array_i16_clamp 2780 : Intrinsic<[llvm_i16_ty], 2781 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2782 "llvm.nvvm.suld.2d.array.i16.clamp">; 2783def int_nvvm_suld_2d_array_i32_clamp 2784 : Intrinsic<[llvm_i32_ty], 2785 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2786 "llvm.nvvm.suld.2d.array.i32.clamp">; 2787def int_nvvm_suld_2d_array_i64_clamp 2788 : Intrinsic<[llvm_i64_ty], 2789 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2790 "llvm.nvvm.suld.2d.array.i64.clamp">; 2791def int_nvvm_suld_2d_array_v2i8_clamp 2792 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2793 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2794 "llvm.nvvm.suld.2d.array.v2i8.clamp">; 2795def int_nvvm_suld_2d_array_v2i16_clamp 2796 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2797 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2798 "llvm.nvvm.suld.2d.array.v2i16.clamp">; 2799def int_nvvm_suld_2d_array_v2i32_clamp 2800 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 2801 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2802 "llvm.nvvm.suld.2d.array.v2i32.clamp">; 2803def int_nvvm_suld_2d_array_v2i64_clamp 2804 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 2805 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2806 "llvm.nvvm.suld.2d.array.v2i64.clamp">; 2807def int_nvvm_suld_2d_array_v4i8_clamp 2808 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2809 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2810 "llvm.nvvm.suld.2d.array.v4i8.clamp">; 2811def int_nvvm_suld_2d_array_v4i16_clamp 2812 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2813 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2814 "llvm.nvvm.suld.2d.array.v4i16.clamp">; 2815def int_nvvm_suld_2d_array_v4i32_clamp 2816 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2817 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2818 "llvm.nvvm.suld.2d.array.v4i32.clamp">; 2819 2820def int_nvvm_suld_3d_i8_clamp 2821 : Intrinsic<[llvm_i16_ty], 2822 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2823 "llvm.nvvm.suld.3d.i8.clamp">; 2824def int_nvvm_suld_3d_i16_clamp 2825 : Intrinsic<[llvm_i16_ty], 2826 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2827 "llvm.nvvm.suld.3d.i16.clamp">; 2828def int_nvvm_suld_3d_i32_clamp 2829 : Intrinsic<[llvm_i32_ty], 2830 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2831 "llvm.nvvm.suld.3d.i32.clamp">; 2832def int_nvvm_suld_3d_i64_clamp 2833 : Intrinsic<[llvm_i64_ty], 2834 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2835 "llvm.nvvm.suld.3d.i64.clamp">; 2836def int_nvvm_suld_3d_v2i8_clamp 2837 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2838 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2839 "llvm.nvvm.suld.3d.v2i8.clamp">; 2840def int_nvvm_suld_3d_v2i16_clamp 2841 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2842 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2843 "llvm.nvvm.suld.3d.v2i16.clamp">; 2844def int_nvvm_suld_3d_v2i32_clamp 2845 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 2846 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2847 "llvm.nvvm.suld.3d.v2i32.clamp">; 2848def int_nvvm_suld_3d_v2i64_clamp 2849 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 2850 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2851 "llvm.nvvm.suld.3d.v2i64.clamp">; 2852def int_nvvm_suld_3d_v4i8_clamp 2853 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2854 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2855 "llvm.nvvm.suld.3d.v4i8.clamp">; 2856def int_nvvm_suld_3d_v4i16_clamp 2857 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2858 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2859 "llvm.nvvm.suld.3d.v4i16.clamp">; 2860def int_nvvm_suld_3d_v4i32_clamp 2861 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2862 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 2863 "llvm.nvvm.suld.3d.v4i32.clamp">; 2864 2865// .trap variants 2866def int_nvvm_suld_1d_i8_trap 2867 : Intrinsic<[llvm_i16_ty], 2868 [llvm_i64_ty, llvm_i32_ty], [], 2869 "llvm.nvvm.suld.1d.i8.trap">; 2870def int_nvvm_suld_1d_i16_trap 2871 : Intrinsic<[llvm_i16_ty], 2872 [llvm_i64_ty, llvm_i32_ty], [], 2873 "llvm.nvvm.suld.1d.i16.trap">; 2874def int_nvvm_suld_1d_i32_trap 2875 : Intrinsic<[llvm_i32_ty], 2876 [llvm_i64_ty, llvm_i32_ty], [], 2877 "llvm.nvvm.suld.1d.i32.trap">; 2878def int_nvvm_suld_1d_i64_trap 2879 : Intrinsic<[llvm_i64_ty], 2880 [llvm_i64_ty, llvm_i32_ty], [], 2881 "llvm.nvvm.suld.1d.i64.trap">; 2882def int_nvvm_suld_1d_v2i8_trap 2883 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2884 [llvm_i64_ty, llvm_i32_ty], [], 2885 "llvm.nvvm.suld.1d.v2i8.trap">; 2886def int_nvvm_suld_1d_v2i16_trap 2887 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2888 [llvm_i64_ty, llvm_i32_ty], [], 2889 "llvm.nvvm.suld.1d.v2i16.trap">; 2890def int_nvvm_suld_1d_v2i32_trap 2891 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 2892 [llvm_i64_ty, llvm_i32_ty], [], 2893 "llvm.nvvm.suld.1d.v2i32.trap">; 2894def int_nvvm_suld_1d_v2i64_trap 2895 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 2896 [llvm_i64_ty, llvm_i32_ty], [], 2897 "llvm.nvvm.suld.1d.v2i64.trap">; 2898def int_nvvm_suld_1d_v4i8_trap 2899 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2900 [llvm_i64_ty, llvm_i32_ty], [], 2901 "llvm.nvvm.suld.1d.v4i8.trap">; 2902def int_nvvm_suld_1d_v4i16_trap 2903 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2904 [llvm_i64_ty, llvm_i32_ty], [], 2905 "llvm.nvvm.suld.1d.v4i16.trap">; 2906def int_nvvm_suld_1d_v4i32_trap 2907 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2908 [llvm_i64_ty, llvm_i32_ty], [], 2909 "llvm.nvvm.suld.1d.v4i32.trap">; 2910 2911def int_nvvm_suld_1d_array_i8_trap 2912 : Intrinsic<[llvm_i16_ty], 2913 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2914 "llvm.nvvm.suld.1d.array.i8.trap">; 2915def int_nvvm_suld_1d_array_i16_trap 2916 : Intrinsic<[llvm_i16_ty], 2917 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2918 "llvm.nvvm.suld.1d.array.i16.trap">; 2919def int_nvvm_suld_1d_array_i32_trap 2920 : Intrinsic<[llvm_i32_ty], 2921 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2922 "llvm.nvvm.suld.1d.array.i32.trap">; 2923def int_nvvm_suld_1d_array_i64_trap 2924 : Intrinsic<[llvm_i64_ty], 2925 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2926 "llvm.nvvm.suld.1d.array.i64.trap">; 2927def int_nvvm_suld_1d_array_v2i8_trap 2928 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2929 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2930 "llvm.nvvm.suld.1d.array.v2i8.trap">; 2931def int_nvvm_suld_1d_array_v2i16_trap 2932 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2933 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2934 "llvm.nvvm.suld.1d.array.v2i16.trap">; 2935def int_nvvm_suld_1d_array_v2i32_trap 2936 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 2937 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2938 "llvm.nvvm.suld.1d.array.v2i32.trap">; 2939def int_nvvm_suld_1d_array_v2i64_trap 2940 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 2941 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2942 "llvm.nvvm.suld.1d.array.v2i64.trap">; 2943def int_nvvm_suld_1d_array_v4i8_trap 2944 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2945 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2946 "llvm.nvvm.suld.1d.array.v4i8.trap">; 2947def int_nvvm_suld_1d_array_v4i16_trap 2948 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2949 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2950 "llvm.nvvm.suld.1d.array.v4i16.trap">; 2951def int_nvvm_suld_1d_array_v4i32_trap 2952 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2953 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2954 "llvm.nvvm.suld.1d.array.v4i32.trap">; 2955 2956def int_nvvm_suld_2d_i8_trap 2957 : Intrinsic<[llvm_i16_ty], 2958 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2959 "llvm.nvvm.suld.2d.i8.trap">; 2960def int_nvvm_suld_2d_i16_trap 2961 : Intrinsic<[llvm_i16_ty], 2962 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2963 "llvm.nvvm.suld.2d.i16.trap">; 2964def int_nvvm_suld_2d_i32_trap 2965 : Intrinsic<[llvm_i32_ty], 2966 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2967 "llvm.nvvm.suld.2d.i32.trap">; 2968def int_nvvm_suld_2d_i64_trap 2969 : Intrinsic<[llvm_i64_ty], 2970 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2971 "llvm.nvvm.suld.2d.i64.trap">; 2972def int_nvvm_suld_2d_v2i8_trap 2973 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2974 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2975 "llvm.nvvm.suld.2d.v2i8.trap">; 2976def int_nvvm_suld_2d_v2i16_trap 2977 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 2978 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2979 "llvm.nvvm.suld.2d.v2i16.trap">; 2980def int_nvvm_suld_2d_v2i32_trap 2981 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 2982 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2983 "llvm.nvvm.suld.2d.v2i32.trap">; 2984def int_nvvm_suld_2d_v2i64_trap 2985 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 2986 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2987 "llvm.nvvm.suld.2d.v2i64.trap">; 2988def int_nvvm_suld_2d_v4i8_trap 2989 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2990 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2991 "llvm.nvvm.suld.2d.v4i8.trap">; 2992def int_nvvm_suld_2d_v4i16_trap 2993 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 2994 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2995 "llvm.nvvm.suld.2d.v4i16.trap">; 2996def int_nvvm_suld_2d_v4i32_trap 2997 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 2998 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 2999 "llvm.nvvm.suld.2d.v4i32.trap">; 3000 3001def int_nvvm_suld_2d_array_i8_trap 3002 : Intrinsic<[llvm_i16_ty], 3003 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3004 "llvm.nvvm.suld.2d.array.i8.trap">; 3005def int_nvvm_suld_2d_array_i16_trap 3006 : Intrinsic<[llvm_i16_ty], 3007 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3008 "llvm.nvvm.suld.2d.array.i16.trap">; 3009def int_nvvm_suld_2d_array_i32_trap 3010 : Intrinsic<[llvm_i32_ty], 3011 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3012 "llvm.nvvm.suld.2d.array.i32.trap">; 3013def int_nvvm_suld_2d_array_i64_trap 3014 : Intrinsic<[llvm_i64_ty], 3015 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3016 "llvm.nvvm.suld.2d.array.i64.trap">; 3017def int_nvvm_suld_2d_array_v2i8_trap 3018 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3019 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3020 "llvm.nvvm.suld.2d.array.v2i8.trap">; 3021def int_nvvm_suld_2d_array_v2i16_trap 3022 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3023 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3024 "llvm.nvvm.suld.2d.array.v2i16.trap">; 3025def int_nvvm_suld_2d_array_v2i32_trap 3026 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 3027 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3028 "llvm.nvvm.suld.2d.array.v2i32.trap">; 3029def int_nvvm_suld_2d_array_v2i64_trap 3030 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 3031 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3032 "llvm.nvvm.suld.2d.array.v2i64.trap">; 3033def int_nvvm_suld_2d_array_v4i8_trap 3034 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3035 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3036 "llvm.nvvm.suld.2d.array.v4i8.trap">; 3037def int_nvvm_suld_2d_array_v4i16_trap 3038 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3039 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3040 "llvm.nvvm.suld.2d.array.v4i16.trap">; 3041def int_nvvm_suld_2d_array_v4i32_trap 3042 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 3043 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3044 "llvm.nvvm.suld.2d.array.v4i32.trap">; 3045 3046def int_nvvm_suld_3d_i8_trap 3047 : Intrinsic<[llvm_i16_ty], 3048 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3049 "llvm.nvvm.suld.3d.i8.trap">; 3050def int_nvvm_suld_3d_i16_trap 3051 : Intrinsic<[llvm_i16_ty], 3052 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3053 "llvm.nvvm.suld.3d.i16.trap">; 3054def int_nvvm_suld_3d_i32_trap 3055 : Intrinsic<[llvm_i32_ty], 3056 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3057 "llvm.nvvm.suld.3d.i32.trap">; 3058def int_nvvm_suld_3d_i64_trap 3059 : Intrinsic<[llvm_i64_ty], 3060 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3061 "llvm.nvvm.suld.3d.i64.trap">; 3062def int_nvvm_suld_3d_v2i8_trap 3063 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3064 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3065 "llvm.nvvm.suld.3d.v2i8.trap">; 3066def int_nvvm_suld_3d_v2i16_trap 3067 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3068 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3069 "llvm.nvvm.suld.3d.v2i16.trap">; 3070def int_nvvm_suld_3d_v2i32_trap 3071 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 3072 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3073 "llvm.nvvm.suld.3d.v2i32.trap">; 3074def int_nvvm_suld_3d_v2i64_trap 3075 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 3076 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3077 "llvm.nvvm.suld.3d.v2i64.trap">; 3078def int_nvvm_suld_3d_v4i8_trap 3079 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3080 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3081 "llvm.nvvm.suld.3d.v4i8.trap">; 3082def int_nvvm_suld_3d_v4i16_trap 3083 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3084 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3085 "llvm.nvvm.suld.3d.v4i16.trap">; 3086def int_nvvm_suld_3d_v4i32_trap 3087 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 3088 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3089 "llvm.nvvm.suld.3d.v4i32.trap">; 3090 3091// .zero variants 3092def int_nvvm_suld_1d_i8_zero 3093 : Intrinsic<[llvm_i16_ty], 3094 [llvm_i64_ty, llvm_i32_ty], [], 3095 "llvm.nvvm.suld.1d.i8.zero">; 3096def int_nvvm_suld_1d_i16_zero 3097 : Intrinsic<[llvm_i16_ty], 3098 [llvm_i64_ty, llvm_i32_ty], [], 3099 "llvm.nvvm.suld.1d.i16.zero">; 3100def int_nvvm_suld_1d_i32_zero 3101 : Intrinsic<[llvm_i32_ty], 3102 [llvm_i64_ty, llvm_i32_ty], [], 3103 "llvm.nvvm.suld.1d.i32.zero">; 3104def int_nvvm_suld_1d_i64_zero 3105 : Intrinsic<[llvm_i64_ty], 3106 [llvm_i64_ty, llvm_i32_ty], [], 3107 "llvm.nvvm.suld.1d.i64.zero">; 3108def int_nvvm_suld_1d_v2i8_zero 3109 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3110 [llvm_i64_ty, llvm_i32_ty], [], 3111 "llvm.nvvm.suld.1d.v2i8.zero">; 3112def int_nvvm_suld_1d_v2i16_zero 3113 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3114 [llvm_i64_ty, llvm_i32_ty], [], 3115 "llvm.nvvm.suld.1d.v2i16.zero">; 3116def int_nvvm_suld_1d_v2i32_zero 3117 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 3118 [llvm_i64_ty, llvm_i32_ty], [], 3119 "llvm.nvvm.suld.1d.v2i32.zero">; 3120def int_nvvm_suld_1d_v2i64_zero 3121 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 3122 [llvm_i64_ty, llvm_i32_ty], [], 3123 "llvm.nvvm.suld.1d.v2i64.zero">; 3124def int_nvvm_suld_1d_v4i8_zero 3125 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3126 [llvm_i64_ty, llvm_i32_ty], [], 3127 "llvm.nvvm.suld.1d.v4i8.zero">; 3128def int_nvvm_suld_1d_v4i16_zero 3129 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3130 [llvm_i64_ty, llvm_i32_ty], [], 3131 "llvm.nvvm.suld.1d.v4i16.zero">; 3132def int_nvvm_suld_1d_v4i32_zero 3133 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 3134 [llvm_i64_ty, llvm_i32_ty], [], 3135 "llvm.nvvm.suld.1d.v4i32.zero">; 3136 3137def int_nvvm_suld_1d_array_i8_zero 3138 : Intrinsic<[llvm_i16_ty], 3139 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3140 "llvm.nvvm.suld.1d.array.i8.zero">; 3141def int_nvvm_suld_1d_array_i16_zero 3142 : Intrinsic<[llvm_i16_ty], 3143 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3144 "llvm.nvvm.suld.1d.array.i16.zero">; 3145def int_nvvm_suld_1d_array_i32_zero 3146 : Intrinsic<[llvm_i32_ty], 3147 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3148 "llvm.nvvm.suld.1d.array.i32.zero">; 3149def int_nvvm_suld_1d_array_i64_zero 3150 : Intrinsic<[llvm_i64_ty], 3151 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3152 "llvm.nvvm.suld.1d.array.i64.zero">; 3153def int_nvvm_suld_1d_array_v2i8_zero 3154 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3155 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3156 "llvm.nvvm.suld.1d.array.v2i8.zero">; 3157def int_nvvm_suld_1d_array_v2i16_zero 3158 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3159 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3160 "llvm.nvvm.suld.1d.array.v2i16.zero">; 3161def int_nvvm_suld_1d_array_v2i32_zero 3162 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 3163 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3164 "llvm.nvvm.suld.1d.array.v2i32.zero">; 3165def int_nvvm_suld_1d_array_v2i64_zero 3166 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 3167 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3168 "llvm.nvvm.suld.1d.array.v2i64.zero">; 3169def int_nvvm_suld_1d_array_v4i8_zero 3170 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3171 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3172 "llvm.nvvm.suld.1d.array.v4i8.zero">; 3173def int_nvvm_suld_1d_array_v4i16_zero 3174 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3175 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3176 "llvm.nvvm.suld.1d.array.v4i16.zero">; 3177def int_nvvm_suld_1d_array_v4i32_zero 3178 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 3179 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3180 "llvm.nvvm.suld.1d.array.v4i32.zero">; 3181 3182def int_nvvm_suld_2d_i8_zero 3183 : Intrinsic<[llvm_i16_ty], 3184 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3185 "llvm.nvvm.suld.2d.i8.zero">; 3186def int_nvvm_suld_2d_i16_zero 3187 : Intrinsic<[llvm_i16_ty], 3188 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3189 "llvm.nvvm.suld.2d.i16.zero">; 3190def int_nvvm_suld_2d_i32_zero 3191 : Intrinsic<[llvm_i32_ty], 3192 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3193 "llvm.nvvm.suld.2d.i32.zero">; 3194def int_nvvm_suld_2d_i64_zero 3195 : Intrinsic<[llvm_i64_ty], 3196 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3197 "llvm.nvvm.suld.2d.i64.zero">; 3198def int_nvvm_suld_2d_v2i8_zero 3199 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3200 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3201 "llvm.nvvm.suld.2d.v2i8.zero">; 3202def int_nvvm_suld_2d_v2i16_zero 3203 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3204 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3205 "llvm.nvvm.suld.2d.v2i16.zero">; 3206def int_nvvm_suld_2d_v2i32_zero 3207 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 3208 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3209 "llvm.nvvm.suld.2d.v2i32.zero">; 3210def int_nvvm_suld_2d_v2i64_zero 3211 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 3212 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3213 "llvm.nvvm.suld.2d.v2i64.zero">; 3214def int_nvvm_suld_2d_v4i8_zero 3215 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3216 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3217 "llvm.nvvm.suld.2d.v4i8.zero">; 3218def int_nvvm_suld_2d_v4i16_zero 3219 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3220 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3221 "llvm.nvvm.suld.2d.v4i16.zero">; 3222def int_nvvm_suld_2d_v4i32_zero 3223 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 3224 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3225 "llvm.nvvm.suld.2d.v4i32.zero">; 3226 3227def int_nvvm_suld_2d_array_i8_zero 3228 : Intrinsic<[llvm_i16_ty], 3229 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3230 "llvm.nvvm.suld.2d.array.i8.zero">; 3231def int_nvvm_suld_2d_array_i16_zero 3232 : Intrinsic<[llvm_i16_ty], 3233 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3234 "llvm.nvvm.suld.2d.array.i16.zero">; 3235def int_nvvm_suld_2d_array_i32_zero 3236 : Intrinsic<[llvm_i32_ty], 3237 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3238 "llvm.nvvm.suld.2d.array.i32.zero">; 3239def int_nvvm_suld_2d_array_i64_zero 3240 : Intrinsic<[llvm_i64_ty], 3241 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3242 "llvm.nvvm.suld.2d.array.i64.zero">; 3243def int_nvvm_suld_2d_array_v2i8_zero 3244 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3245 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3246 "llvm.nvvm.suld.2d.array.v2i8.zero">; 3247def int_nvvm_suld_2d_array_v2i16_zero 3248 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3249 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3250 "llvm.nvvm.suld.2d.array.v2i16.zero">; 3251def int_nvvm_suld_2d_array_v2i32_zero 3252 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 3253 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3254 "llvm.nvvm.suld.2d.array.v2i32.zero">; 3255def int_nvvm_suld_2d_array_v2i64_zero 3256 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 3257 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3258 "llvm.nvvm.suld.2d.array.v2i64.zero">; 3259def int_nvvm_suld_2d_array_v4i8_zero 3260 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3261 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3262 "llvm.nvvm.suld.2d.array.v4i8.zero">; 3263def int_nvvm_suld_2d_array_v4i16_zero 3264 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3265 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3266 "llvm.nvvm.suld.2d.array.v4i16.zero">; 3267def int_nvvm_suld_2d_array_v4i32_zero 3268 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 3269 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3270 "llvm.nvvm.suld.2d.array.v4i32.zero">; 3271 3272def int_nvvm_suld_3d_i8_zero 3273 : Intrinsic<[llvm_i16_ty], 3274 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3275 "llvm.nvvm.suld.3d.i8.zero">; 3276def int_nvvm_suld_3d_i16_zero 3277 : Intrinsic<[llvm_i16_ty], 3278 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3279 "llvm.nvvm.suld.3d.i16.zero">; 3280def int_nvvm_suld_3d_i32_zero 3281 : Intrinsic<[llvm_i32_ty], 3282 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3283 "llvm.nvvm.suld.3d.i32.zero">; 3284def int_nvvm_suld_3d_i64_zero 3285 : Intrinsic<[llvm_i64_ty], 3286 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3287 "llvm.nvvm.suld.3d.i64.zero">; 3288def int_nvvm_suld_3d_v2i8_zero 3289 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3290 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3291 "llvm.nvvm.suld.3d.v2i8.zero">; 3292def int_nvvm_suld_3d_v2i16_zero 3293 : Intrinsic<[llvm_i16_ty, llvm_i16_ty], 3294 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3295 "llvm.nvvm.suld.3d.v2i16.zero">; 3296def int_nvvm_suld_3d_v2i32_zero 3297 : Intrinsic<[llvm_i32_ty, llvm_i32_ty], 3298 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3299 "llvm.nvvm.suld.3d.v2i32.zero">; 3300def int_nvvm_suld_3d_v2i64_zero 3301 : Intrinsic<[llvm_i64_ty, llvm_i64_ty], 3302 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3303 "llvm.nvvm.suld.3d.v2i64.zero">; 3304def int_nvvm_suld_3d_v4i8_zero 3305 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3306 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3307 "llvm.nvvm.suld.3d.v4i8.zero">; 3308def int_nvvm_suld_3d_v4i16_zero 3309 : Intrinsic<[llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], 3310 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3311 "llvm.nvvm.suld.3d.v4i16.zero">; 3312def int_nvvm_suld_3d_v4i32_zero 3313 : Intrinsic<[llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], 3314 [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3315 "llvm.nvvm.suld.3d.v4i32.zero">; 3316 3317//===- Texture Query ------------------------------------------------------===// 3318 3319def int_nvvm_txq_channel_order 3320 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3321 "llvm.nvvm.txq.channel.order">, 3322 ClangBuiltin<"__nvvm_txq_channel_order">; 3323def int_nvvm_txq_channel_data_type 3324 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3325 "llvm.nvvm.txq.channel.data.type">, 3326 ClangBuiltin<"__nvvm_txq_channel_data_type">; 3327def int_nvvm_txq_width 3328 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3329 "llvm.nvvm.txq.width">, 3330 ClangBuiltin<"__nvvm_txq_width">; 3331def int_nvvm_txq_height 3332 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3333 "llvm.nvvm.txq.height">, 3334 ClangBuiltin<"__nvvm_txq_height">; 3335def int_nvvm_txq_depth 3336 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3337 "llvm.nvvm.txq.depth">, 3338 ClangBuiltin<"__nvvm_txq_depth">; 3339def int_nvvm_txq_array_size 3340 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3341 "llvm.nvvm.txq.array.size">, 3342 ClangBuiltin<"__nvvm_txq_array_size">; 3343def int_nvvm_txq_num_samples 3344 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3345 "llvm.nvvm.txq.num.samples">, 3346 ClangBuiltin<"__nvvm_txq_num_samples">; 3347def int_nvvm_txq_num_mipmap_levels 3348 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3349 "llvm.nvvm.txq.num.mipmap.levels">, 3350 ClangBuiltin<"__nvvm_txq_num_mipmap_levels">; 3351 3352//===- Surface Query ------------------------------------------------------===// 3353 3354def int_nvvm_suq_channel_order 3355 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3356 "llvm.nvvm.suq.channel.order">, 3357 ClangBuiltin<"__nvvm_suq_channel_order">; 3358def int_nvvm_suq_channel_data_type 3359 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3360 "llvm.nvvm.suq.channel.data.type">, 3361 ClangBuiltin<"__nvvm_suq_channel_data_type">; 3362def int_nvvm_suq_width 3363 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3364 "llvm.nvvm.suq.width">, 3365 ClangBuiltin<"__nvvm_suq_width">; 3366def int_nvvm_suq_height 3367 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3368 "llvm.nvvm.suq.height">, 3369 ClangBuiltin<"__nvvm_suq_height">; 3370def int_nvvm_suq_depth 3371 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3372 "llvm.nvvm.suq.depth">, 3373 ClangBuiltin<"__nvvm_suq_depth">; 3374def int_nvvm_suq_array_size 3375 : Intrinsic<[llvm_i32_ty], [llvm_i64_ty], [IntrNoMem], 3376 "llvm.nvvm.suq.array.size">, 3377 ClangBuiltin<"__nvvm_suq_array_size">; 3378 3379 3380//===- Handle Query -------------------------------------------------------===// 3381 3382def int_nvvm_istypep_sampler 3383 : Intrinsic<[llvm_i1_ty], [llvm_i64_ty], [IntrNoMem], 3384 "llvm.nvvm.istypep.sampler">, 3385 ClangBuiltin<"__nvvm_istypep_sampler">; 3386def int_nvvm_istypep_surface 3387 : Intrinsic<[llvm_i1_ty], [llvm_i64_ty], [IntrNoMem], 3388 "llvm.nvvm.istypep.surface">, 3389 ClangBuiltin<"__nvvm_istypep_surface">; 3390def int_nvvm_istypep_texture 3391 : Intrinsic<[llvm_i1_ty], [llvm_i64_ty], [IntrNoMem], 3392 "llvm.nvvm.istypep.texture">, 3393 ClangBuiltin<"__nvvm_istypep_texture">; 3394 3395 3396 3397//===- Surface Stores -----------------------------------------------------===// 3398 3399// Unformatted 3400// .clamp variant 3401def int_nvvm_sust_b_1d_i8_clamp 3402 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty], [], 3403 "llvm.nvvm.sust.b.1d.i8.clamp">, 3404 ClangBuiltin<"__nvvm_sust_b_1d_i8_clamp">; 3405def int_nvvm_sust_b_1d_i16_clamp 3406 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty], [], 3407 "llvm.nvvm.sust.b.1d.i16.clamp">, 3408 ClangBuiltin<"__nvvm_sust_b_1d_i16_clamp">; 3409def int_nvvm_sust_b_1d_i32_clamp 3410 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3411 "llvm.nvvm.sust.b.1d.i32.clamp">, 3412 ClangBuiltin<"__nvvm_sust_b_1d_i32_clamp">; 3413def int_nvvm_sust_b_1d_i64_clamp 3414 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i64_ty], [], 3415 "llvm.nvvm.sust.b.1d.i64.clamp">, 3416 ClangBuiltin<"__nvvm_sust_b_1d_i64_clamp">; 3417def int_nvvm_sust_b_1d_v2i8_clamp 3418 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, llvm_i16_ty], [], 3419 "llvm.nvvm.sust.b.1d.v2i8.clamp">, 3420 ClangBuiltin<"__nvvm_sust_b_1d_v2i8_clamp">; 3421def int_nvvm_sust_b_1d_v2i16_clamp 3422 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, llvm_i16_ty], [], 3423 "llvm.nvvm.sust.b.1d.v2i16.clamp">, 3424 ClangBuiltin<"__nvvm_sust_b_1d_v2i16_clamp">; 3425def int_nvvm_sust_b_1d_v2i32_clamp 3426 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3427 "llvm.nvvm.sust.b.1d.v2i32.clamp">, 3428 ClangBuiltin<"__nvvm_sust_b_1d_v2i32_clamp">; 3429def int_nvvm_sust_b_1d_v2i64_clamp 3430 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i64_ty, llvm_i64_ty], [], 3431 "llvm.nvvm.sust.b.1d.v2i64.clamp">, 3432 ClangBuiltin<"__nvvm_sust_b_1d_v2i64_clamp">; 3433def int_nvvm_sust_b_1d_v4i8_clamp 3434 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, 3435 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3436 "llvm.nvvm.sust.b.1d.v4i8.clamp">, 3437 ClangBuiltin<"__nvvm_sust_b_1d_v4i8_clamp">; 3438def int_nvvm_sust_b_1d_v4i16_clamp 3439 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, 3440 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3441 "llvm.nvvm.sust.b.1d.v4i16.clamp">, 3442 ClangBuiltin<"__nvvm_sust_b_1d_v4i16_clamp">; 3443def int_nvvm_sust_b_1d_v4i32_clamp 3444 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3445 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3446 "llvm.nvvm.sust.b.1d.v4i32.clamp">, 3447 ClangBuiltin<"__nvvm_sust_b_1d_v4i32_clamp">; 3448 3449 3450def int_nvvm_sust_b_1d_array_i8_clamp 3451 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3452 "llvm.nvvm.sust.b.1d.array.i8.clamp">, 3453 ClangBuiltin<"__nvvm_sust_b_1d_array_i8_clamp">; 3454def int_nvvm_sust_b_1d_array_i16_clamp 3455 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3456 "llvm.nvvm.sust.b.1d.array.i16.clamp">, 3457 ClangBuiltin<"__nvvm_sust_b_1d_array_i16_clamp">; 3458def int_nvvm_sust_b_1d_array_i32_clamp 3459 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3460 "llvm.nvvm.sust.b.1d.array.i32.clamp">, 3461 ClangBuiltin<"__nvvm_sust_b_1d_array_i32_clamp">; 3462def int_nvvm_sust_b_1d_array_i64_clamp 3463 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i64_ty], [], 3464 "llvm.nvvm.sust.b.1d.array.i64.clamp">, 3465 ClangBuiltin<"__nvvm_sust_b_1d_array_i64_clamp">; 3466def int_nvvm_sust_b_1d_array_v2i8_clamp 3467 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3468 llvm_i16_ty, llvm_i16_ty], [], 3469 "llvm.nvvm.sust.b.1d.array.v2i8.clamp">, 3470 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i8_clamp">; 3471def int_nvvm_sust_b_1d_array_v2i16_clamp 3472 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3473 llvm_i16_ty, llvm_i16_ty], [], 3474 "llvm.nvvm.sust.b.1d.array.v2i16.clamp">, 3475 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i16_clamp">; 3476def int_nvvm_sust_b_1d_array_v2i32_clamp 3477 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3478 llvm_i32_ty, llvm_i32_ty], [], 3479 "llvm.nvvm.sust.b.1d.array.v2i32.clamp">, 3480 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i32_clamp">; 3481def int_nvvm_sust_b_1d_array_v2i64_clamp 3482 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3483 llvm_i64_ty, llvm_i64_ty], [], 3484 "llvm.nvvm.sust.b.1d.array.v2i64.clamp">, 3485 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i64_clamp">; 3486def int_nvvm_sust_b_1d_array_v4i8_clamp 3487 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 3488 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3489 "llvm.nvvm.sust.b.1d.array.v4i8.clamp">, 3490 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i8_clamp">; 3491def int_nvvm_sust_b_1d_array_v4i16_clamp 3492 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 3493 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3494 "llvm.nvvm.sust.b.1d.array.v4i16.clamp">, 3495 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i16_clamp">; 3496def int_nvvm_sust_b_1d_array_v4i32_clamp 3497 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3498 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3499 "llvm.nvvm.sust.b.1d.array.v4i32.clamp">, 3500 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i32_clamp">; 3501 3502 3503def int_nvvm_sust_b_2d_i8_clamp 3504 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3505 "llvm.nvvm.sust.b.2d.i8.clamp">, 3506 ClangBuiltin<"__nvvm_sust_b_2d_i8_clamp">; 3507def int_nvvm_sust_b_2d_i16_clamp 3508 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3509 "llvm.nvvm.sust.b.2d.i16.clamp">, 3510 ClangBuiltin<"__nvvm_sust_b_2d_i16_clamp">; 3511def int_nvvm_sust_b_2d_i32_clamp 3512 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3513 "llvm.nvvm.sust.b.2d.i32.clamp">, 3514 ClangBuiltin<"__nvvm_sust_b_2d_i32_clamp">; 3515def int_nvvm_sust_b_2d_i64_clamp 3516 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i64_ty], [], 3517 "llvm.nvvm.sust.b.2d.i64.clamp">, 3518 ClangBuiltin<"__nvvm_sust_b_2d_i64_clamp">; 3519def int_nvvm_sust_b_2d_v2i8_clamp 3520 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3521 llvm_i16_ty, llvm_i16_ty], [], 3522 "llvm.nvvm.sust.b.2d.v2i8.clamp">, 3523 ClangBuiltin<"__nvvm_sust_b_2d_v2i8_clamp">; 3524def int_nvvm_sust_b_2d_v2i16_clamp 3525 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3526 llvm_i16_ty, llvm_i16_ty], [], 3527 "llvm.nvvm.sust.b.2d.v2i16.clamp">, 3528 ClangBuiltin<"__nvvm_sust_b_2d_v2i16_clamp">; 3529def int_nvvm_sust_b_2d_v2i32_clamp 3530 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3531 llvm_i32_ty, llvm_i32_ty], [], 3532 "llvm.nvvm.sust.b.2d.v2i32.clamp">, 3533 ClangBuiltin<"__nvvm_sust_b_2d_v2i32_clamp">; 3534def int_nvvm_sust_b_2d_v2i64_clamp 3535 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3536 llvm_i64_ty, llvm_i64_ty], [], 3537 "llvm.nvvm.sust.b.2d.v2i64.clamp">, 3538 ClangBuiltin<"__nvvm_sust_b_2d_v2i64_clamp">; 3539def int_nvvm_sust_b_2d_v4i8_clamp 3540 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 3541 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3542 "llvm.nvvm.sust.b.2d.v4i8.clamp">, 3543 ClangBuiltin<"__nvvm_sust_b_2d_v4i8_clamp">; 3544def int_nvvm_sust_b_2d_v4i16_clamp 3545 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 3546 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3547 "llvm.nvvm.sust.b.2d.v4i16.clamp">, 3548 ClangBuiltin<"__nvvm_sust_b_2d_v4i16_clamp">; 3549def int_nvvm_sust_b_2d_v4i32_clamp 3550 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3551 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3552 "llvm.nvvm.sust.b.2d.v4i32.clamp">, 3553 ClangBuiltin<"__nvvm_sust_b_2d_v4i32_clamp">; 3554 3555 3556def int_nvvm_sust_b_2d_array_i8_clamp 3557 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3558 llvm_i32_ty, llvm_i16_ty], [], 3559 "llvm.nvvm.sust.b.2d.array.i8.clamp">, 3560 ClangBuiltin<"__nvvm_sust_b_2d_array_i8_clamp">; 3561def int_nvvm_sust_b_2d_array_i16_clamp 3562 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3563 llvm_i32_ty, llvm_i16_ty], [], 3564 "llvm.nvvm.sust.b.2d.array.i16.clamp">, 3565 ClangBuiltin<"__nvvm_sust_b_2d_array_i16_clamp">; 3566def int_nvvm_sust_b_2d_array_i32_clamp 3567 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3568 llvm_i32_ty, llvm_i32_ty], [], 3569 "llvm.nvvm.sust.b.2d.array.i32.clamp">, 3570 ClangBuiltin<"__nvvm_sust_b_2d_array_i32_clamp">; 3571def int_nvvm_sust_b_2d_array_i64_clamp 3572 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3573 llvm_i32_ty, llvm_i64_ty], [], 3574 "llvm.nvvm.sust.b.2d.array.i64.clamp">, 3575 ClangBuiltin<"__nvvm_sust_b_2d_array_i64_clamp">; 3576def int_nvvm_sust_b_2d_array_v2i8_clamp 3577 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3578 llvm_i16_ty, llvm_i16_ty], [], 3579 "llvm.nvvm.sust.b.2d.array.v2i8.clamp">, 3580 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i8_clamp">; 3581def int_nvvm_sust_b_2d_array_v2i16_clamp 3582 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3583 llvm_i16_ty, llvm_i16_ty], [], 3584 "llvm.nvvm.sust.b.2d.array.v2i16.clamp">, 3585 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i16_clamp">; 3586def int_nvvm_sust_b_2d_array_v2i32_clamp 3587 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3588 llvm_i32_ty, llvm_i32_ty], [], 3589 "llvm.nvvm.sust.b.2d.array.v2i32.clamp">, 3590 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i32_clamp">; 3591def int_nvvm_sust_b_2d_array_v2i64_clamp 3592 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3593 llvm_i64_ty, llvm_i64_ty], [], 3594 "llvm.nvvm.sust.b.2d.array.v2i64.clamp">, 3595 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i64_clamp">; 3596def int_nvvm_sust_b_2d_array_v4i8_clamp 3597 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3598 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3599 "llvm.nvvm.sust.b.2d.array.v4i8.clamp">, 3600 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i8_clamp">; 3601def int_nvvm_sust_b_2d_array_v4i16_clamp 3602 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3603 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3604 "llvm.nvvm.sust.b.2d.array.v4i16.clamp">, 3605 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i16_clamp">; 3606def int_nvvm_sust_b_2d_array_v4i32_clamp 3607 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3608 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3609 "llvm.nvvm.sust.b.2d.array.v4i32.clamp">, 3610 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i32_clamp">; 3611 3612 3613def int_nvvm_sust_b_3d_i8_clamp 3614 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3615 llvm_i32_ty, llvm_i16_ty], [], 3616 "llvm.nvvm.sust.b.3d.i8.clamp">, 3617 ClangBuiltin<"__nvvm_sust_b_3d_i8_clamp">; 3618def int_nvvm_sust_b_3d_i16_clamp 3619 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3620 llvm_i32_ty, llvm_i16_ty], [], 3621 "llvm.nvvm.sust.b.3d.i16.clamp">, 3622 ClangBuiltin<"__nvvm_sust_b_3d_i16_clamp">; 3623def int_nvvm_sust_b_3d_i32_clamp 3624 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3625 llvm_i32_ty, llvm_i32_ty], [], 3626 "llvm.nvvm.sust.b.3d.i32.clamp">, 3627 ClangBuiltin<"__nvvm_sust_b_3d_i32_clamp">; 3628def int_nvvm_sust_b_3d_i64_clamp 3629 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3630 llvm_i32_ty, llvm_i64_ty], [], 3631 "llvm.nvvm.sust.b.3d.i64.clamp">, 3632 ClangBuiltin<"__nvvm_sust_b_3d_i64_clamp">; 3633def int_nvvm_sust_b_3d_v2i8_clamp 3634 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3635 llvm_i16_ty, llvm_i16_ty], [], 3636 "llvm.nvvm.sust.b.3d.v2i8.clamp">, 3637 ClangBuiltin<"__nvvm_sust_b_3d_v2i8_clamp">; 3638def int_nvvm_sust_b_3d_v2i16_clamp 3639 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3640 llvm_i16_ty, llvm_i16_ty], [], 3641 "llvm.nvvm.sust.b.3d.v2i16.clamp">, 3642 ClangBuiltin<"__nvvm_sust_b_3d_v2i16_clamp">; 3643def int_nvvm_sust_b_3d_v2i32_clamp 3644 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3645 llvm_i32_ty, llvm_i32_ty], [], 3646 "llvm.nvvm.sust.b.3d.v2i32.clamp">, 3647 ClangBuiltin<"__nvvm_sust_b_3d_v2i32_clamp">; 3648def int_nvvm_sust_b_3d_v2i64_clamp 3649 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3650 llvm_i64_ty, llvm_i64_ty], [], 3651 "llvm.nvvm.sust.b.3d.v2i64.clamp">, 3652 ClangBuiltin<"__nvvm_sust_b_3d_v2i64_clamp">; 3653def int_nvvm_sust_b_3d_v4i8_clamp 3654 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3655 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3656 "llvm.nvvm.sust.b.3d.v4i8.clamp">, 3657 ClangBuiltin<"__nvvm_sust_b_3d_v4i8_clamp">; 3658def int_nvvm_sust_b_3d_v4i16_clamp 3659 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3660 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3661 "llvm.nvvm.sust.b.3d.v4i16.clamp">, 3662 ClangBuiltin<"__nvvm_sust_b_3d_v4i16_clamp">; 3663def int_nvvm_sust_b_3d_v4i32_clamp 3664 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3665 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3666 "llvm.nvvm.sust.b.3d.v4i32.clamp">, 3667 ClangBuiltin<"__nvvm_sust_b_3d_v4i32_clamp">; 3668 3669 3670// .trap variant 3671def int_nvvm_sust_b_1d_i8_trap 3672 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty], [], 3673 "llvm.nvvm.sust.b.1d.i8.trap">, 3674 ClangBuiltin<"__nvvm_sust_b_1d_i8_trap">; 3675def int_nvvm_sust_b_1d_i16_trap 3676 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty], [], 3677 "llvm.nvvm.sust.b.1d.i16.trap">, 3678 ClangBuiltin<"__nvvm_sust_b_1d_i16_trap">; 3679def int_nvvm_sust_b_1d_i32_trap 3680 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3681 "llvm.nvvm.sust.b.1d.i32.trap">, 3682 ClangBuiltin<"__nvvm_sust_b_1d_i32_trap">; 3683def int_nvvm_sust_b_1d_i64_trap 3684 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i64_ty], [], 3685 "llvm.nvvm.sust.b.1d.i64.trap">, 3686 ClangBuiltin<"__nvvm_sust_b_1d_i64_trap">; 3687def int_nvvm_sust_b_1d_v2i8_trap 3688 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, llvm_i16_ty], [], 3689 "llvm.nvvm.sust.b.1d.v2i8.trap">, 3690 ClangBuiltin<"__nvvm_sust_b_1d_v2i8_trap">; 3691def int_nvvm_sust_b_1d_v2i16_trap 3692 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, llvm_i16_ty], [], 3693 "llvm.nvvm.sust.b.1d.v2i16.trap">, 3694 ClangBuiltin<"__nvvm_sust_b_1d_v2i16_trap">; 3695def int_nvvm_sust_b_1d_v2i32_trap 3696 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3697 "llvm.nvvm.sust.b.1d.v2i32.trap">, 3698 ClangBuiltin<"__nvvm_sust_b_1d_v2i32_trap">; 3699def int_nvvm_sust_b_1d_v2i64_trap 3700 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i64_ty, llvm_i64_ty], [], 3701 "llvm.nvvm.sust.b.1d.v2i64.trap">, 3702 ClangBuiltin<"__nvvm_sust_b_1d_v2i64_trap">; 3703def int_nvvm_sust_b_1d_v4i8_trap 3704 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, 3705 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3706 "llvm.nvvm.sust.b.1d.v4i8.trap">, 3707 ClangBuiltin<"__nvvm_sust_b_1d_v4i8_trap">; 3708def int_nvvm_sust_b_1d_v4i16_trap 3709 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, 3710 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3711 "llvm.nvvm.sust.b.1d.v4i16.trap">, 3712 ClangBuiltin<"__nvvm_sust_b_1d_v4i16_trap">; 3713def int_nvvm_sust_b_1d_v4i32_trap 3714 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3715 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3716 "llvm.nvvm.sust.b.1d.v4i32.trap">, 3717 ClangBuiltin<"__nvvm_sust_b_1d_v4i32_trap">; 3718 3719 3720def int_nvvm_sust_b_1d_array_i8_trap 3721 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3722 "llvm.nvvm.sust.b.1d.array.i8.trap">, 3723 ClangBuiltin<"__nvvm_sust_b_1d_array_i8_trap">; 3724def int_nvvm_sust_b_1d_array_i16_trap 3725 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3726 "llvm.nvvm.sust.b.1d.array.i16.trap">, 3727 ClangBuiltin<"__nvvm_sust_b_1d_array_i16_trap">; 3728def int_nvvm_sust_b_1d_array_i32_trap 3729 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3730 "llvm.nvvm.sust.b.1d.array.i32.trap">, 3731 ClangBuiltin<"__nvvm_sust_b_1d_array_i32_trap">; 3732def int_nvvm_sust_b_1d_array_i64_trap 3733 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i64_ty], [], 3734 "llvm.nvvm.sust.b.1d.array.i64.trap">, 3735 ClangBuiltin<"__nvvm_sust_b_1d_array_i64_trap">; 3736def int_nvvm_sust_b_1d_array_v2i8_trap 3737 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3738 llvm_i16_ty, llvm_i16_ty], [], 3739 "llvm.nvvm.sust.b.1d.array.v2i8.trap">, 3740 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i8_trap">; 3741def int_nvvm_sust_b_1d_array_v2i16_trap 3742 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3743 llvm_i16_ty, llvm_i16_ty], [], 3744 "llvm.nvvm.sust.b.1d.array.v2i16.trap">, 3745 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i16_trap">; 3746def int_nvvm_sust_b_1d_array_v2i32_trap 3747 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3748 llvm_i32_ty, llvm_i32_ty], [], 3749 "llvm.nvvm.sust.b.1d.array.v2i32.trap">, 3750 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i32_trap">; 3751def int_nvvm_sust_b_1d_array_v2i64_trap 3752 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3753 llvm_i64_ty, llvm_i64_ty], [], 3754 "llvm.nvvm.sust.b.1d.array.v2i64.trap">, 3755 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i64_trap">; 3756def int_nvvm_sust_b_1d_array_v4i8_trap 3757 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 3758 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3759 "llvm.nvvm.sust.b.1d.array.v4i8.trap">, 3760 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i8_trap">; 3761def int_nvvm_sust_b_1d_array_v4i16_trap 3762 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 3763 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3764 "llvm.nvvm.sust.b.1d.array.v4i16.trap">, 3765 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i16_trap">; 3766def int_nvvm_sust_b_1d_array_v4i32_trap 3767 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3768 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3769 "llvm.nvvm.sust.b.1d.array.v4i32.trap">, 3770 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i32_trap">; 3771 3772 3773def int_nvvm_sust_b_2d_i8_trap 3774 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3775 "llvm.nvvm.sust.b.2d.i8.trap">, 3776 ClangBuiltin<"__nvvm_sust_b_2d_i8_trap">; 3777def int_nvvm_sust_b_2d_i16_trap 3778 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3779 "llvm.nvvm.sust.b.2d.i16.trap">, 3780 ClangBuiltin<"__nvvm_sust_b_2d_i16_trap">; 3781def int_nvvm_sust_b_2d_i32_trap 3782 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3783 "llvm.nvvm.sust.b.2d.i32.trap">, 3784 ClangBuiltin<"__nvvm_sust_b_2d_i32_trap">; 3785def int_nvvm_sust_b_2d_i64_trap 3786 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i64_ty], [], 3787 "llvm.nvvm.sust.b.2d.i64.trap">, 3788 ClangBuiltin<"__nvvm_sust_b_2d_i64_trap">; 3789def int_nvvm_sust_b_2d_v2i8_trap 3790 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3791 llvm_i16_ty, llvm_i16_ty], [], 3792 "llvm.nvvm.sust.b.2d.v2i8.trap">, 3793 ClangBuiltin<"__nvvm_sust_b_2d_v2i8_trap">; 3794def int_nvvm_sust_b_2d_v2i16_trap 3795 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3796 llvm_i16_ty, llvm_i16_ty], [], 3797 "llvm.nvvm.sust.b.2d.v2i16.trap">, 3798 ClangBuiltin<"__nvvm_sust_b_2d_v2i16_trap">; 3799def int_nvvm_sust_b_2d_v2i32_trap 3800 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3801 llvm_i32_ty, llvm_i32_ty], [], 3802 "llvm.nvvm.sust.b.2d.v2i32.trap">, 3803 ClangBuiltin<"__nvvm_sust_b_2d_v2i32_trap">; 3804def int_nvvm_sust_b_2d_v2i64_trap 3805 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3806 llvm_i64_ty, llvm_i64_ty], [], 3807 "llvm.nvvm.sust.b.2d.v2i64.trap">, 3808 ClangBuiltin<"__nvvm_sust_b_2d_v2i64_trap">; 3809def int_nvvm_sust_b_2d_v4i8_trap 3810 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 3811 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3812 "llvm.nvvm.sust.b.2d.v4i8.trap">, 3813 ClangBuiltin<"__nvvm_sust_b_2d_v4i8_trap">; 3814def int_nvvm_sust_b_2d_v4i16_trap 3815 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 3816 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3817 "llvm.nvvm.sust.b.2d.v4i16.trap">, 3818 ClangBuiltin<"__nvvm_sust_b_2d_v4i16_trap">; 3819def int_nvvm_sust_b_2d_v4i32_trap 3820 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3821 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3822 "llvm.nvvm.sust.b.2d.v4i32.trap">, 3823 ClangBuiltin<"__nvvm_sust_b_2d_v4i32_trap">; 3824 3825 3826def int_nvvm_sust_b_2d_array_i8_trap 3827 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3828 llvm_i32_ty, llvm_i16_ty], [], 3829 "llvm.nvvm.sust.b.2d.array.i8.trap">, 3830 ClangBuiltin<"__nvvm_sust_b_2d_array_i8_trap">; 3831def int_nvvm_sust_b_2d_array_i16_trap 3832 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3833 llvm_i32_ty, llvm_i16_ty], [], 3834 "llvm.nvvm.sust.b.2d.array.i16.trap">, 3835 ClangBuiltin<"__nvvm_sust_b_2d_array_i16_trap">; 3836def int_nvvm_sust_b_2d_array_i32_trap 3837 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3838 llvm_i32_ty, llvm_i32_ty], [], 3839 "llvm.nvvm.sust.b.2d.array.i32.trap">, 3840 ClangBuiltin<"__nvvm_sust_b_2d_array_i32_trap">; 3841def int_nvvm_sust_b_2d_array_i64_trap 3842 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3843 llvm_i32_ty, llvm_i64_ty], [], 3844 "llvm.nvvm.sust.b.2d.array.i64.trap">, 3845 ClangBuiltin<"__nvvm_sust_b_2d_array_i64_trap">; 3846def int_nvvm_sust_b_2d_array_v2i8_trap 3847 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3848 llvm_i16_ty, llvm_i16_ty], [], 3849 "llvm.nvvm.sust.b.2d.array.v2i8.trap">, 3850 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i8_trap">; 3851def int_nvvm_sust_b_2d_array_v2i16_trap 3852 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3853 llvm_i16_ty, llvm_i16_ty], [], 3854 "llvm.nvvm.sust.b.2d.array.v2i16.trap">, 3855 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i16_trap">; 3856def int_nvvm_sust_b_2d_array_v2i32_trap 3857 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3858 llvm_i32_ty, llvm_i32_ty], [], 3859 "llvm.nvvm.sust.b.2d.array.v2i32.trap">, 3860 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i32_trap">; 3861def int_nvvm_sust_b_2d_array_v2i64_trap 3862 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3863 llvm_i64_ty, llvm_i64_ty], [], 3864 "llvm.nvvm.sust.b.2d.array.v2i64.trap">, 3865 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i64_trap">; 3866def int_nvvm_sust_b_2d_array_v4i8_trap 3867 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3868 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3869 "llvm.nvvm.sust.b.2d.array.v4i8.trap">, 3870 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i8_trap">; 3871def int_nvvm_sust_b_2d_array_v4i16_trap 3872 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3873 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3874 "llvm.nvvm.sust.b.2d.array.v4i16.trap">, 3875 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i16_trap">; 3876def int_nvvm_sust_b_2d_array_v4i32_trap 3877 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3878 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3879 "llvm.nvvm.sust.b.2d.array.v4i32.trap">, 3880 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i32_trap">; 3881 3882 3883def int_nvvm_sust_b_3d_i8_trap 3884 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3885 llvm_i32_ty, llvm_i16_ty], [], 3886 "llvm.nvvm.sust.b.3d.i8.trap">, 3887 ClangBuiltin<"__nvvm_sust_b_3d_i8_trap">; 3888def int_nvvm_sust_b_3d_i16_trap 3889 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3890 llvm_i32_ty, llvm_i16_ty], [], 3891 "llvm.nvvm.sust.b.3d.i16.trap">, 3892 ClangBuiltin<"__nvvm_sust_b_3d_i16_trap">; 3893def int_nvvm_sust_b_3d_i32_trap 3894 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3895 llvm_i32_ty, llvm_i32_ty], [], 3896 "llvm.nvvm.sust.b.3d.i32.trap">, 3897 ClangBuiltin<"__nvvm_sust_b_3d_i32_trap">; 3898def int_nvvm_sust_b_3d_i64_trap 3899 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3900 llvm_i32_ty, llvm_i64_ty], [], 3901 "llvm.nvvm.sust.b.3d.i64.trap">, 3902 ClangBuiltin<"__nvvm_sust_b_3d_i64_trap">; 3903def int_nvvm_sust_b_3d_v2i8_trap 3904 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3905 llvm_i16_ty, llvm_i16_ty], [], 3906 "llvm.nvvm.sust.b.3d.v2i8.trap">, 3907 ClangBuiltin<"__nvvm_sust_b_3d_v2i8_trap">; 3908def int_nvvm_sust_b_3d_v2i16_trap 3909 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3910 llvm_i16_ty, llvm_i16_ty], [], 3911 "llvm.nvvm.sust.b.3d.v2i16.trap">, 3912 ClangBuiltin<"__nvvm_sust_b_3d_v2i16_trap">; 3913def int_nvvm_sust_b_3d_v2i32_trap 3914 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3915 llvm_i32_ty, llvm_i32_ty], [], 3916 "llvm.nvvm.sust.b.3d.v2i32.trap">, 3917 ClangBuiltin<"__nvvm_sust_b_3d_v2i32_trap">; 3918def int_nvvm_sust_b_3d_v2i64_trap 3919 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3920 llvm_i64_ty, llvm_i64_ty], [], 3921 "llvm.nvvm.sust.b.3d.v2i64.trap">, 3922 ClangBuiltin<"__nvvm_sust_b_3d_v2i64_trap">; 3923def int_nvvm_sust_b_3d_v4i8_trap 3924 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3925 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3926 "llvm.nvvm.sust.b.3d.v4i8.trap">, 3927 ClangBuiltin<"__nvvm_sust_b_3d_v4i8_trap">; 3928def int_nvvm_sust_b_3d_v4i16_trap 3929 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3930 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3931 "llvm.nvvm.sust.b.3d.v4i16.trap">, 3932 ClangBuiltin<"__nvvm_sust_b_3d_v4i16_trap">; 3933def int_nvvm_sust_b_3d_v4i32_trap 3934 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 3935 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3936 "llvm.nvvm.sust.b.3d.v4i32.trap">, 3937 ClangBuiltin<"__nvvm_sust_b_3d_v4i32_trap">; 3938 3939 3940// .zero variant 3941def int_nvvm_sust_b_1d_i8_zero 3942 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty], [], 3943 "llvm.nvvm.sust.b.1d.i8.zero">, 3944 ClangBuiltin<"__nvvm_sust_b_1d_i8_zero">; 3945def int_nvvm_sust_b_1d_i16_zero 3946 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty], [], 3947 "llvm.nvvm.sust.b.1d.i16.zero">, 3948 ClangBuiltin<"__nvvm_sust_b_1d_i16_zero">; 3949def int_nvvm_sust_b_1d_i32_zero 3950 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 3951 "llvm.nvvm.sust.b.1d.i32.zero">, 3952 ClangBuiltin<"__nvvm_sust_b_1d_i32_zero">; 3953def int_nvvm_sust_b_1d_i64_zero 3954 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i64_ty], [], 3955 "llvm.nvvm.sust.b.1d.i64.zero">, 3956 ClangBuiltin<"__nvvm_sust_b_1d_i64_zero">; 3957def int_nvvm_sust_b_1d_v2i8_zero 3958 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, llvm_i16_ty], [], 3959 "llvm.nvvm.sust.b.1d.v2i8.zero">, 3960 ClangBuiltin<"__nvvm_sust_b_1d_v2i8_zero">; 3961def int_nvvm_sust_b_1d_v2i16_zero 3962 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, llvm_i16_ty], [], 3963 "llvm.nvvm.sust.b.1d.v2i16.zero">, 3964 ClangBuiltin<"__nvvm_sust_b_1d_v2i16_zero">; 3965def int_nvvm_sust_b_1d_v2i32_zero 3966 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3967 "llvm.nvvm.sust.b.1d.v2i32.zero">, 3968 ClangBuiltin<"__nvvm_sust_b_1d_v2i32_zero">; 3969def int_nvvm_sust_b_1d_v2i64_zero 3970 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i64_ty, llvm_i64_ty], [], 3971 "llvm.nvvm.sust.b.1d.v2i64.zero">, 3972 ClangBuiltin<"__nvvm_sust_b_1d_v2i64_zero">; 3973def int_nvvm_sust_b_1d_v4i8_zero 3974 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, 3975 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3976 "llvm.nvvm.sust.b.1d.v4i8.zero">, 3977 ClangBuiltin<"__nvvm_sust_b_1d_v4i8_zero">; 3978def int_nvvm_sust_b_1d_v4i16_zero 3979 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, 3980 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 3981 "llvm.nvvm.sust.b.1d.v4i16.zero">, 3982 ClangBuiltin<"__nvvm_sust_b_1d_v4i16_zero">; 3983def int_nvvm_sust_b_1d_v4i32_zero 3984 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 3985 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 3986 "llvm.nvvm.sust.b.1d.v4i32.zero">, 3987 ClangBuiltin<"__nvvm_sust_b_1d_v4i32_zero">; 3988 3989 3990def int_nvvm_sust_b_1d_array_i8_zero 3991 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3992 "llvm.nvvm.sust.b.1d.array.i8.zero">, 3993 ClangBuiltin<"__nvvm_sust_b_1d_array_i8_zero">; 3994def int_nvvm_sust_b_1d_array_i16_zero 3995 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 3996 "llvm.nvvm.sust.b.1d.array.i16.zero">, 3997 ClangBuiltin<"__nvvm_sust_b_1d_array_i16_zero">; 3998def int_nvvm_sust_b_1d_array_i32_zero 3999 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4000 "llvm.nvvm.sust.b.1d.array.i32.zero">, 4001 ClangBuiltin<"__nvvm_sust_b_1d_array_i32_zero">; 4002def int_nvvm_sust_b_1d_array_i64_zero 4003 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i64_ty], [], 4004 "llvm.nvvm.sust.b.1d.array.i64.zero">, 4005 ClangBuiltin<"__nvvm_sust_b_1d_array_i64_zero">; 4006def int_nvvm_sust_b_1d_array_v2i8_zero 4007 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4008 llvm_i16_ty, llvm_i16_ty], [], 4009 "llvm.nvvm.sust.b.1d.array.v2i8.zero">, 4010 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i8_zero">; 4011def int_nvvm_sust_b_1d_array_v2i16_zero 4012 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4013 llvm_i16_ty, llvm_i16_ty], [], 4014 "llvm.nvvm.sust.b.1d.array.v2i16.zero">, 4015 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i16_zero">; 4016def int_nvvm_sust_b_1d_array_v2i32_zero 4017 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4018 llvm_i32_ty, llvm_i32_ty], [], 4019 "llvm.nvvm.sust.b.1d.array.v2i32.zero">, 4020 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i32_zero">; 4021def int_nvvm_sust_b_1d_array_v2i64_zero 4022 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4023 llvm_i64_ty, llvm_i64_ty], [], 4024 "llvm.nvvm.sust.b.1d.array.v2i64.zero">, 4025 ClangBuiltin<"__nvvm_sust_b_1d_array_v2i64_zero">; 4026def int_nvvm_sust_b_1d_array_v4i8_zero 4027 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 4028 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4029 "llvm.nvvm.sust.b.1d.array.v4i8.zero">, 4030 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i8_zero">; 4031def int_nvvm_sust_b_1d_array_v4i16_zero 4032 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 4033 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4034 "llvm.nvvm.sust.b.1d.array.v4i16.zero">, 4035 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i16_zero">; 4036def int_nvvm_sust_b_1d_array_v4i32_zero 4037 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4038 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4039 "llvm.nvvm.sust.b.1d.array.v4i32.zero">, 4040 ClangBuiltin<"__nvvm_sust_b_1d_array_v4i32_zero">; 4041 4042 4043def int_nvvm_sust_b_2d_i8_zero 4044 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 4045 "llvm.nvvm.sust.b.2d.i8.zero">, 4046 ClangBuiltin<"__nvvm_sust_b_2d_i8_zero">; 4047def int_nvvm_sust_b_2d_i16_zero 4048 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 4049 "llvm.nvvm.sust.b.2d.i16.zero">, 4050 ClangBuiltin<"__nvvm_sust_b_2d_i16_zero">; 4051def int_nvvm_sust_b_2d_i32_zero 4052 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4053 "llvm.nvvm.sust.b.2d.i32.zero">, 4054 ClangBuiltin<"__nvvm_sust_b_2d_i32_zero">; 4055def int_nvvm_sust_b_2d_i64_zero 4056 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i64_ty], [], 4057 "llvm.nvvm.sust.b.2d.i64.zero">, 4058 ClangBuiltin<"__nvvm_sust_b_2d_i64_zero">; 4059def int_nvvm_sust_b_2d_v2i8_zero 4060 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4061 llvm_i16_ty, llvm_i16_ty], [], 4062 "llvm.nvvm.sust.b.2d.v2i8.zero">, 4063 ClangBuiltin<"__nvvm_sust_b_2d_v2i8_zero">; 4064def int_nvvm_sust_b_2d_v2i16_zero 4065 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4066 llvm_i16_ty, llvm_i16_ty], [], 4067 "llvm.nvvm.sust.b.2d.v2i16.zero">, 4068 ClangBuiltin<"__nvvm_sust_b_2d_v2i16_zero">; 4069def int_nvvm_sust_b_2d_v2i32_zero 4070 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4071 llvm_i32_ty, llvm_i32_ty], [], 4072 "llvm.nvvm.sust.b.2d.v2i32.zero">, 4073 ClangBuiltin<"__nvvm_sust_b_2d_v2i32_zero">; 4074def int_nvvm_sust_b_2d_v2i64_zero 4075 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4076 llvm_i64_ty, llvm_i64_ty], [], 4077 "llvm.nvvm.sust.b.2d.v2i64.zero">, 4078 ClangBuiltin<"__nvvm_sust_b_2d_v2i64_zero">; 4079def int_nvvm_sust_b_2d_v4i8_zero 4080 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 4081 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4082 "llvm.nvvm.sust.b.2d.v4i8.zero">, 4083 ClangBuiltin<"__nvvm_sust_b_2d_v4i8_zero">; 4084def int_nvvm_sust_b_2d_v4i16_zero 4085 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 4086 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4087 "llvm.nvvm.sust.b.2d.v4i16.zero">, 4088 ClangBuiltin<"__nvvm_sust_b_2d_v4i16_zero">; 4089def int_nvvm_sust_b_2d_v4i32_zero 4090 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4091 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4092 "llvm.nvvm.sust.b.2d.v4i32.zero">, 4093 ClangBuiltin<"__nvvm_sust_b_2d_v4i32_zero">; 4094 4095 4096def int_nvvm_sust_b_2d_array_i8_zero 4097 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4098 llvm_i32_ty, llvm_i16_ty], [], 4099 "llvm.nvvm.sust.b.2d.array.i8.zero">, 4100 ClangBuiltin<"__nvvm_sust_b_2d_array_i8_zero">; 4101def int_nvvm_sust_b_2d_array_i16_zero 4102 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4103 llvm_i32_ty, llvm_i16_ty], [], 4104 "llvm.nvvm.sust.b.2d.array.i16.zero">, 4105 ClangBuiltin<"__nvvm_sust_b_2d_array_i16_zero">; 4106def int_nvvm_sust_b_2d_array_i32_zero 4107 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4108 llvm_i32_ty, llvm_i32_ty], [], 4109 "llvm.nvvm.sust.b.2d.array.i32.zero">, 4110 ClangBuiltin<"__nvvm_sust_b_2d_array_i32_zero">; 4111def int_nvvm_sust_b_2d_array_i64_zero 4112 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4113 llvm_i32_ty, llvm_i64_ty], [], 4114 "llvm.nvvm.sust.b.2d.array.i64.zero">, 4115 ClangBuiltin<"__nvvm_sust_b_2d_array_i64_zero">; 4116def int_nvvm_sust_b_2d_array_v2i8_zero 4117 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4118 llvm_i16_ty, llvm_i16_ty], [], 4119 "llvm.nvvm.sust.b.2d.array.v2i8.zero">, 4120 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i8_zero">; 4121def int_nvvm_sust_b_2d_array_v2i16_zero 4122 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4123 llvm_i16_ty, llvm_i16_ty], [], 4124 "llvm.nvvm.sust.b.2d.array.v2i16.zero">, 4125 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i16_zero">; 4126def int_nvvm_sust_b_2d_array_v2i32_zero 4127 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4128 llvm_i32_ty, llvm_i32_ty], [], 4129 "llvm.nvvm.sust.b.2d.array.v2i32.zero">, 4130 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i32_zero">; 4131def int_nvvm_sust_b_2d_array_v2i64_zero 4132 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4133 llvm_i64_ty, llvm_i64_ty], [], 4134 "llvm.nvvm.sust.b.2d.array.v2i64.zero">, 4135 ClangBuiltin<"__nvvm_sust_b_2d_array_v2i64_zero">; 4136def int_nvvm_sust_b_2d_array_v4i8_zero 4137 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4138 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4139 "llvm.nvvm.sust.b.2d.array.v4i8.zero">, 4140 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i8_zero">; 4141def int_nvvm_sust_b_2d_array_v4i16_zero 4142 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4143 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4144 "llvm.nvvm.sust.b.2d.array.v4i16.zero">, 4145 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i16_zero">; 4146def int_nvvm_sust_b_2d_array_v4i32_zero 4147 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4148 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4149 "llvm.nvvm.sust.b.2d.array.v4i32.zero">, 4150 ClangBuiltin<"__nvvm_sust_b_2d_array_v4i32_zero">; 4151 4152 4153def int_nvvm_sust_b_3d_i8_zero 4154 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4155 llvm_i32_ty, llvm_i16_ty], [], 4156 "llvm.nvvm.sust.b.3d.i8.zero">, 4157 ClangBuiltin<"__nvvm_sust_b_3d_i8_zero">; 4158def int_nvvm_sust_b_3d_i16_zero 4159 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4160 llvm_i32_ty, llvm_i16_ty], [], 4161 "llvm.nvvm.sust.b.3d.i16.zero">, 4162 ClangBuiltin<"__nvvm_sust_b_3d_i16_zero">; 4163def int_nvvm_sust_b_3d_i32_zero 4164 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4165 llvm_i32_ty, llvm_i32_ty], [], 4166 "llvm.nvvm.sust.b.3d.i32.zero">, 4167 ClangBuiltin<"__nvvm_sust_b_3d_i32_zero">; 4168def int_nvvm_sust_b_3d_i64_zero 4169 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4170 llvm_i32_ty, llvm_i64_ty], [], 4171 "llvm.nvvm.sust.b.3d.i64.zero">, 4172 ClangBuiltin<"__nvvm_sust_b_3d_i64_zero">; 4173def int_nvvm_sust_b_3d_v2i8_zero 4174 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4175 llvm_i16_ty, llvm_i16_ty], [], 4176 "llvm.nvvm.sust.b.3d.v2i8.zero">, 4177 ClangBuiltin<"__nvvm_sust_b_3d_v2i8_zero">; 4178def int_nvvm_sust_b_3d_v2i16_zero 4179 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4180 llvm_i16_ty, llvm_i16_ty], [], 4181 "llvm.nvvm.sust.b.3d.v2i16.zero">, 4182 ClangBuiltin<"__nvvm_sust_b_3d_v2i16_zero">; 4183def int_nvvm_sust_b_3d_v2i32_zero 4184 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4185 llvm_i32_ty, llvm_i32_ty], [], 4186 "llvm.nvvm.sust.b.3d.v2i32.zero">, 4187 ClangBuiltin<"__nvvm_sust_b_3d_v2i32_zero">; 4188def int_nvvm_sust_b_3d_v2i64_zero 4189 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4190 llvm_i64_ty, llvm_i64_ty], [], 4191 "llvm.nvvm.sust.b.3d.v2i64.zero">, 4192 ClangBuiltin<"__nvvm_sust_b_3d_v2i64_zero">; 4193def int_nvvm_sust_b_3d_v4i8_zero 4194 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4195 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4196 "llvm.nvvm.sust.b.3d.v4i8.zero">, 4197 ClangBuiltin<"__nvvm_sust_b_3d_v4i8_zero">; 4198def int_nvvm_sust_b_3d_v4i16_zero 4199 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4200 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4201 "llvm.nvvm.sust.b.3d.v4i16.zero">, 4202 ClangBuiltin<"__nvvm_sust_b_3d_v4i16_zero">; 4203def int_nvvm_sust_b_3d_v4i32_zero 4204 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4205 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4206 "llvm.nvvm.sust.b.3d.v4i32.zero">, 4207 ClangBuiltin<"__nvvm_sust_b_3d_v4i32_zero">; 4208 4209 4210 4211// Formatted 4212 4213def int_nvvm_sust_p_1d_i8_trap 4214 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty], [], 4215 "llvm.nvvm.sust.p.1d.i8.trap">, 4216 ClangBuiltin<"__nvvm_sust_p_1d_i8_trap">; 4217def int_nvvm_sust_p_1d_i16_trap 4218 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty], [], 4219 "llvm.nvvm.sust.p.1d.i16.trap">, 4220 ClangBuiltin<"__nvvm_sust_p_1d_i16_trap">; 4221def int_nvvm_sust_p_1d_i32_trap 4222 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty], [], 4223 "llvm.nvvm.sust.p.1d.i32.trap">, 4224 ClangBuiltin<"__nvvm_sust_p_1d_i32_trap">; 4225def int_nvvm_sust_p_1d_v2i8_trap 4226 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, llvm_i16_ty], [], 4227 "llvm.nvvm.sust.p.1d.v2i8.trap">, 4228 ClangBuiltin<"__nvvm_sust_p_1d_v2i8_trap">; 4229def int_nvvm_sust_p_1d_v2i16_trap 4230 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, llvm_i16_ty], [], 4231 "llvm.nvvm.sust.p.1d.v2i16.trap">, 4232 ClangBuiltin<"__nvvm_sust_p_1d_v2i16_trap">; 4233def int_nvvm_sust_p_1d_v2i32_trap 4234 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4235 "llvm.nvvm.sust.p.1d.v2i32.trap">, 4236 ClangBuiltin<"__nvvm_sust_p_1d_v2i32_trap">; 4237def int_nvvm_sust_p_1d_v4i8_trap 4238 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, 4239 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4240 "llvm.nvvm.sust.p.1d.v4i8.trap">, 4241 ClangBuiltin<"__nvvm_sust_p_1d_v4i8_trap">; 4242def int_nvvm_sust_p_1d_v4i16_trap 4243 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i16_ty, 4244 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4245 "llvm.nvvm.sust.p.1d.v4i16.trap">, 4246 ClangBuiltin<"__nvvm_sust_p_1d_v4i16_trap">; 4247def int_nvvm_sust_p_1d_v4i32_trap 4248 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4249 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4250 "llvm.nvvm.sust.p.1d.v4i32.trap">, 4251 ClangBuiltin<"__nvvm_sust_p_1d_v4i32_trap">; 4252 4253 4254def int_nvvm_sust_p_1d_array_i8_trap 4255 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 4256 "llvm.nvvm.sust.p.1d.array.i8.trap">, 4257 ClangBuiltin<"__nvvm_sust_p_1d_array_i8_trap">; 4258def int_nvvm_sust_p_1d_array_i16_trap 4259 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 4260 "llvm.nvvm.sust.p.1d.array.i16.trap">, 4261 ClangBuiltin<"__nvvm_sust_p_1d_array_i16_trap">; 4262def int_nvvm_sust_p_1d_array_i32_trap 4263 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4264 "llvm.nvvm.sust.p.1d.array.i32.trap">, 4265 ClangBuiltin<"__nvvm_sust_p_1d_array_i32_trap">; 4266def int_nvvm_sust_p_1d_array_v2i8_trap 4267 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4268 llvm_i16_ty, llvm_i16_ty], [], 4269 "llvm.nvvm.sust.p.1d.array.v2i8.trap">, 4270 ClangBuiltin<"__nvvm_sust_p_1d_array_v2i8_trap">; 4271def int_nvvm_sust_p_1d_array_v2i16_trap 4272 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4273 llvm_i16_ty, llvm_i16_ty], [], 4274 "llvm.nvvm.sust.p.1d.array.v2i16.trap">, 4275 ClangBuiltin<"__nvvm_sust_p_1d_array_v2i16_trap">; 4276def int_nvvm_sust_p_1d_array_v2i32_trap 4277 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4278 llvm_i32_ty, llvm_i32_ty], [], 4279 "llvm.nvvm.sust.p.1d.array.v2i32.trap">, 4280 ClangBuiltin<"__nvvm_sust_p_1d_array_v2i32_trap">; 4281def int_nvvm_sust_p_1d_array_v4i8_trap 4282 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 4283 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4284 "llvm.nvvm.sust.p.1d.array.v4i8.trap">, 4285 ClangBuiltin<"__nvvm_sust_p_1d_array_v4i8_trap">; 4286def int_nvvm_sust_p_1d_array_v4i16_trap 4287 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 4288 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4289 "llvm.nvvm.sust.p.1d.array.v4i16.trap">, 4290 ClangBuiltin<"__nvvm_sust_p_1d_array_v4i16_trap">; 4291def int_nvvm_sust_p_1d_array_v4i32_trap 4292 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4293 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4294 "llvm.nvvm.sust.p.1d.array.v4i32.trap">, 4295 ClangBuiltin<"__nvvm_sust_p_1d_array_v4i32_trap">; 4296 4297 4298def int_nvvm_sust_p_2d_i8_trap 4299 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 4300 "llvm.nvvm.sust.p.2d.i8.trap">, 4301 ClangBuiltin<"__nvvm_sust_p_2d_i8_trap">; 4302def int_nvvm_sust_p_2d_i16_trap 4303 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty], [], 4304 "llvm.nvvm.sust.p.2d.i16.trap">, 4305 ClangBuiltin<"__nvvm_sust_p_2d_i16_trap">; 4306def int_nvvm_sust_p_2d_i32_trap 4307 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4308 "llvm.nvvm.sust.p.2d.i32.trap">, 4309 ClangBuiltin<"__nvvm_sust_p_2d_i32_trap">; 4310def int_nvvm_sust_p_2d_v2i8_trap 4311 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4312 llvm_i16_ty, llvm_i16_ty], [], 4313 "llvm.nvvm.sust.p.2d.v2i8.trap">, 4314 ClangBuiltin<"__nvvm_sust_p_2d_v2i8_trap">; 4315def int_nvvm_sust_p_2d_v2i16_trap 4316 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4317 llvm_i16_ty, llvm_i16_ty], [], 4318 "llvm.nvvm.sust.p.2d.v2i16.trap">, 4319 ClangBuiltin<"__nvvm_sust_p_2d_v2i16_trap">; 4320def int_nvvm_sust_p_2d_v2i32_trap 4321 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4322 llvm_i32_ty, llvm_i32_ty], [], 4323 "llvm.nvvm.sust.p.2d.v2i32.trap">, 4324 ClangBuiltin<"__nvvm_sust_p_2d_v2i32_trap">; 4325def int_nvvm_sust_p_2d_v4i8_trap 4326 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 4327 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4328 "llvm.nvvm.sust.p.2d.v4i8.trap">, 4329 ClangBuiltin<"__nvvm_sust_p_2d_v4i8_trap">; 4330def int_nvvm_sust_p_2d_v4i16_trap 4331 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i16_ty, 4332 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4333 "llvm.nvvm.sust.p.2d.v4i16.trap">, 4334 ClangBuiltin<"__nvvm_sust_p_2d_v4i16_trap">; 4335def int_nvvm_sust_p_2d_v4i32_trap 4336 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4337 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4338 "llvm.nvvm.sust.p.2d.v4i32.trap">, 4339 ClangBuiltin<"__nvvm_sust_p_2d_v4i32_trap">; 4340 4341 4342def int_nvvm_sust_p_2d_array_i8_trap 4343 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4344 llvm_i32_ty, llvm_i16_ty], [], 4345 "llvm.nvvm.sust.p.2d.array.i8.trap">, 4346 ClangBuiltin<"__nvvm_sust_p_2d_array_i8_trap">; 4347def int_nvvm_sust_p_2d_array_i16_trap 4348 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4349 llvm_i32_ty, llvm_i16_ty], [], 4350 "llvm.nvvm.sust.p.2d.array.i16.trap">, 4351 ClangBuiltin<"__nvvm_sust_p_2d_array_i16_trap">; 4352def int_nvvm_sust_p_2d_array_i32_trap 4353 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4354 llvm_i32_ty, llvm_i32_ty], [], 4355 "llvm.nvvm.sust.p.2d.array.i32.trap">, 4356 ClangBuiltin<"__nvvm_sust_p_2d_array_i32_trap">; 4357def int_nvvm_sust_p_2d_array_v2i8_trap 4358 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4359 llvm_i16_ty, llvm_i16_ty], [], 4360 "llvm.nvvm.sust.p.2d.array.v2i8.trap">, 4361 ClangBuiltin<"__nvvm_sust_p_2d_array_v2i8_trap">; 4362def int_nvvm_sust_p_2d_array_v2i16_trap 4363 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4364 llvm_i16_ty, llvm_i16_ty], [], 4365 "llvm.nvvm.sust.p.2d.array.v2i16.trap">, 4366 ClangBuiltin<"__nvvm_sust_p_2d_array_v2i16_trap">; 4367def int_nvvm_sust_p_2d_array_v2i32_trap 4368 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4369 llvm_i32_ty, llvm_i32_ty], [], 4370 "llvm.nvvm.sust.p.2d.array.v2i32.trap">, 4371 ClangBuiltin<"__nvvm_sust_p_2d_array_v2i32_trap">; 4372def int_nvvm_sust_p_2d_array_v4i8_trap 4373 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4374 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4375 "llvm.nvvm.sust.p.2d.array.v4i8.trap">, 4376 ClangBuiltin<"__nvvm_sust_p_2d_array_v4i8_trap">; 4377def int_nvvm_sust_p_2d_array_v4i16_trap 4378 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4379 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4380 "llvm.nvvm.sust.p.2d.array.v4i16.trap">, 4381 ClangBuiltin<"__nvvm_sust_p_2d_array_v4i16_trap">; 4382def int_nvvm_sust_p_2d_array_v4i32_trap 4383 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4384 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4385 "llvm.nvvm.sust.p.2d.array.v4i32.trap">, 4386 ClangBuiltin<"__nvvm_sust_p_2d_array_v4i32_trap">; 4387 4388 4389def int_nvvm_sust_p_3d_i8_trap 4390 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4391 llvm_i32_ty, llvm_i16_ty], [], 4392 "llvm.nvvm.sust.p.3d.i8.trap">, 4393 ClangBuiltin<"__nvvm_sust_p_3d_i8_trap">; 4394def int_nvvm_sust_p_3d_i16_trap 4395 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4396 llvm_i32_ty, llvm_i16_ty], [], 4397 "llvm.nvvm.sust.p.3d.i16.trap">, 4398 ClangBuiltin<"__nvvm_sust_p_3d_i16_trap">; 4399def int_nvvm_sust_p_3d_i32_trap 4400 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, 4401 llvm_i32_ty, llvm_i32_ty], [], 4402 "llvm.nvvm.sust.p.3d.i32.trap">, 4403 ClangBuiltin<"__nvvm_sust_p_3d_i32_trap">; 4404def int_nvvm_sust_p_3d_v2i8_trap 4405 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4406 llvm_i16_ty, llvm_i16_ty], [], 4407 "llvm.nvvm.sust.p.3d.v2i8.trap">, 4408 ClangBuiltin<"__nvvm_sust_p_3d_v2i8_trap">; 4409def int_nvvm_sust_p_3d_v2i16_trap 4410 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4411 llvm_i16_ty, llvm_i16_ty], [], 4412 "llvm.nvvm.sust.p.3d.v2i16.trap">, 4413 ClangBuiltin<"__nvvm_sust_p_3d_v2i16_trap">; 4414def int_nvvm_sust_p_3d_v2i32_trap 4415 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4416 llvm_i32_ty, llvm_i32_ty], [], 4417 "llvm.nvvm.sust.p.3d.v2i32.trap">, 4418 ClangBuiltin<"__nvvm_sust_p_3d_v2i32_trap">; 4419def int_nvvm_sust_p_3d_v4i8_trap 4420 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4421 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4422 "llvm.nvvm.sust.p.3d.v4i8.trap">, 4423 ClangBuiltin<"__nvvm_sust_p_3d_v4i8_trap">; 4424def int_nvvm_sust_p_3d_v4i16_trap 4425 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4426 llvm_i16_ty, llvm_i16_ty, llvm_i16_ty, llvm_i16_ty], [], 4427 "llvm.nvvm.sust.p.3d.v4i16.trap">, 4428 ClangBuiltin<"__nvvm_sust_p_3d_v4i16_trap">; 4429def int_nvvm_sust_p_3d_v4i32_trap 4430 : Intrinsic<[], [llvm_i64_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, 4431 llvm_i32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], [], 4432 "llvm.nvvm.sust.p.3d.v4i32.trap">, 4433 ClangBuiltin<"__nvvm_sust_p_3d_v4i32_trap">; 4434 4435 4436def int_nvvm_rotate_b32 4437 : DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4438 [IntrNoMem, IntrSpeculatable], "llvm.nvvm.rotate.b32">, 4439 ClangBuiltin<"__nvvm_rotate_b32">; 4440 4441def int_nvvm_rotate_b64 4442 : DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_i64_ty, llvm_i32_ty], 4443 [IntrNoMem, IntrSpeculatable], "llvm.nvvm.rotate.b64">, 4444 ClangBuiltin<"__nvvm_rotate_b64">; 4445 4446def int_nvvm_rotate_right_b64 4447 : DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_i64_ty, llvm_i32_ty], 4448 [IntrNoMem, IntrSpeculatable], "llvm.nvvm.rotate.right.b64">, 4449 ClangBuiltin<"__nvvm_rotate_right_b64">; 4450 4451def int_nvvm_swap_lo_hi_b64 4452 : DefaultAttrsIntrinsic<[llvm_i64_ty], [llvm_i64_ty], 4453 [IntrNoMem, IntrSpeculatable], "llvm.nvvm.swap.lo.hi.b64">, 4454 ClangBuiltin<"__nvvm_swap_lo_hi_b64">; 4455 4456 4457// Accessing special registers. 4458 4459class PTXReadSRegIntrinsicNB_r32 4460 : DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>]>; 4461class PTXReadSRegIntrinsic_r32<string name> 4462 : PTXReadSRegIntrinsicNB_r32, ClangBuiltin<"__nvvm_read_ptx_sreg_" # name>; 4463 4464multiclass PTXReadSRegIntrinsic_v4i32<string regname> { 4465// FIXME: Do we need the 128-bit integer type version? 4466// def _r64 : Intrinsic<[llvm_i128_ty], [], [IntrNoMem, IntrSpeculatable]>; 4467 4468// FIXME: Enable this once v4i32 support is enabled in back-end. 4469// def _v4i16 : Intrinsic<[llvm_v4i32_ty], [], [IntrNoMem, IntrSpeculatable]>; 4470 foreach suffix = ["_x", "_y", "_z", "_w"] in 4471 def suffix : PTXReadSRegIntrinsic_r32<regname # suffix>; 4472} 4473 4474// Same, but without automatic clang builtins. It will be used for 4475// registers that require particular GPU or PTX version. 4476multiclass PTXReadSRegIntrinsicNB_v4i32 { 4477 foreach suffix = ["_x", "_y", "_z", "_w"] in 4478 def suffix : PTXReadSRegIntrinsicNB_r32; 4479} 4480 4481class PTXReadSRegIntrinsic_r64<string name> 4482 : DefaultAttrsIntrinsic<[llvm_i64_ty], [], [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>]>, 4483 ClangBuiltin<"__nvvm_read_ptx_sreg_" # name>; 4484 4485// Intrinsics to read registers with non-constant values. E.g. the values that 4486// do change over the kernel lifetime. Such reads should not be CSE'd. 4487class PTXReadNCSRegIntrinsic_r32<string name> 4488 : Intrinsic<[llvm_i32_ty], [], [IntrInaccessibleMemOnly, IntrNoCallback, NoUndef<RetIndex>]>, 4489 ClangBuiltin<"__nvvm_read_ptx_sreg_" # name>; 4490class PTXReadNCSRegIntrinsic_r64<string name> 4491 : Intrinsic<[llvm_i64_ty], [], [IntrInaccessibleMemOnly, IntrNoCallback, NoUndef<RetIndex>]>, 4492 ClangBuiltin<"__nvvm_read_ptx_sreg_" # name>; 4493 4494defm int_nvvm_read_ptx_sreg_tid : PTXReadSRegIntrinsic_v4i32<"tid">; 4495defm int_nvvm_read_ptx_sreg_ntid : PTXReadSRegIntrinsic_v4i32<"ntid">; 4496 4497def int_nvvm_read_ptx_sreg_laneid : PTXReadSRegIntrinsic_r32<"laneid">; 4498def int_nvvm_read_ptx_sreg_warpid : PTXReadSRegIntrinsic_r32<"warpid">; 4499def int_nvvm_read_ptx_sreg_nwarpid : PTXReadSRegIntrinsic_r32<"nwarpid">; 4500 4501defm int_nvvm_read_ptx_sreg_ctaid : PTXReadSRegIntrinsic_v4i32<"ctaid">; 4502defm int_nvvm_read_ptx_sreg_nctaid : PTXReadSRegIntrinsic_v4i32<"nctaid">; 4503 4504def int_nvvm_read_ptx_sreg_smid : PTXReadSRegIntrinsic_r32<"smid">; 4505def int_nvvm_read_ptx_sreg_nsmid : PTXReadSRegIntrinsic_r32<"nsmid">; 4506def int_nvvm_read_ptx_sreg_gridid : PTXReadSRegIntrinsic_r32<"gridid">; 4507 4508def int_nvvm_read_ptx_sreg_lanemask_eq : 4509 PTXReadSRegIntrinsic_r32<"lanemask_eq">; 4510def int_nvvm_read_ptx_sreg_lanemask_le : 4511 PTXReadSRegIntrinsic_r32<"lanemask_le">; 4512def int_nvvm_read_ptx_sreg_lanemask_lt : 4513 PTXReadSRegIntrinsic_r32<"lanemask_lt">; 4514def int_nvvm_read_ptx_sreg_lanemask_ge : 4515 PTXReadSRegIntrinsic_r32<"lanemask_ge">; 4516def int_nvvm_read_ptx_sreg_lanemask_gt : 4517 PTXReadSRegIntrinsic_r32<"lanemask_gt">; 4518 4519def int_nvvm_read_ptx_sreg_clock : PTXReadNCSRegIntrinsic_r32<"clock">; 4520def int_nvvm_read_ptx_sreg_clock64 : PTXReadNCSRegIntrinsic_r64<"clock64">; 4521 4522def int_nvvm_read_ptx_sreg_globaltimer : PTXReadNCSRegIntrinsic_r64<"globaltimer">; 4523 4524def int_nvvm_read_ptx_sreg_pm0 : PTXReadNCSRegIntrinsic_r32<"pm0">; 4525def int_nvvm_read_ptx_sreg_pm1 : PTXReadNCSRegIntrinsic_r32<"pm1">; 4526def int_nvvm_read_ptx_sreg_pm2 : PTXReadNCSRegIntrinsic_r32<"pm2">; 4527def int_nvvm_read_ptx_sreg_pm3 : PTXReadNCSRegIntrinsic_r32<"pm3">; 4528 4529def int_nvvm_read_ptx_sreg_warpsize : PTXReadSRegIntrinsic_r32<"warpsize">; 4530 4531// sm90+, PTX7.8+ 4532defm int_nvvm_read_ptx_sreg_clusterid : PTXReadSRegIntrinsicNB_v4i32; 4533defm int_nvvm_read_ptx_sreg_nclusterid : PTXReadSRegIntrinsicNB_v4i32; 4534defm int_nvvm_read_ptx_sreg_cluster_ctaid : PTXReadSRegIntrinsicNB_v4i32; 4535defm int_nvvm_read_ptx_sreg_cluster_nctaid : PTXReadSRegIntrinsicNB_v4i32; 4536 4537def int_nvvm_read_ptx_sreg_cluster_ctarank : PTXReadSRegIntrinsicNB_r32; 4538def int_nvvm_read_ptx_sreg_cluster_nctarank : PTXReadSRegIntrinsicNB_r32; 4539 4540// 4541// SHUFFLE 4542// 4543// Generate intrinsics for all variants of shfl instruction. 4544foreach sync = [false, true] in { 4545 foreach mode = ["up", "down", "bfly", "idx"] in { 4546 foreach type = ["i32", "f32"] in { 4547 foreach return_pred = [false, true] in { 4548 foreach i = [SHFL_INFO<sync, mode, type, return_pred>] in { 4549 if i.withGccBuiltin then { 4550 def i.Name : ClangBuiltin<i.Builtin>, 4551 Intrinsic<i.RetTy, i.ArgsTy, 4552 [IntrInaccessibleMemOnly, IntrConvergent, 4553 IntrNoCallback], 4554 i.IntrName>; 4555 } 4556 if i.withoutGccBuiltin then { 4557 def i.Name : Intrinsic<i.RetTy, i.ArgsTy, 4558 [IntrInaccessibleMemOnly, IntrConvergent, 4559 IntrNoCallback], i.IntrName>; 4560 } 4561 } 4562 } 4563 } 4564 } 4565} 4566 4567// 4568// VOTE 4569// 4570 4571// vote.all pred 4572def int_nvvm_vote_all : 4573 Intrinsic<[llvm_i1_ty], [llvm_i1_ty], 4574 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.vote.all">, 4575 ClangBuiltin<"__nvvm_vote_all">; 4576// vote.any pred 4577def int_nvvm_vote_any : 4578 Intrinsic<[llvm_i1_ty], [llvm_i1_ty], 4579 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.vote.any">, 4580 ClangBuiltin<"__nvvm_vote_any">; 4581// vote.uni pred 4582def int_nvvm_vote_uni : 4583 Intrinsic<[llvm_i1_ty], [llvm_i1_ty], 4584 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.vote.uni">, 4585 ClangBuiltin<"__nvvm_vote_uni">; 4586// vote.ballot pred 4587def int_nvvm_vote_ballot : 4588 Intrinsic<[llvm_i32_ty], [llvm_i1_ty], 4589 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.vote.ballot">, 4590 ClangBuiltin<"__nvvm_vote_ballot">; 4591 4592// 4593// VOTE.SYNC 4594// 4595 4596// vote.sync.all mask, pred 4597def int_nvvm_vote_all_sync : 4598 Intrinsic<[llvm_i1_ty], [llvm_i32_ty, llvm_i1_ty], 4599 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.vote.all.sync">, 4600 ClangBuiltin<"__nvvm_vote_all_sync">; 4601// vote.sync.any mask, pred 4602def int_nvvm_vote_any_sync : 4603 Intrinsic<[llvm_i1_ty], [llvm_i32_ty, llvm_i1_ty], 4604 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.vote.any.sync">, 4605 ClangBuiltin<"__nvvm_vote_any_sync">; 4606// vote.sync.uni mask, pred 4607def int_nvvm_vote_uni_sync : 4608 Intrinsic<[llvm_i1_ty], [llvm_i32_ty, llvm_i1_ty], 4609 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.vote.uni.sync">, 4610 ClangBuiltin<"__nvvm_vote_uni_sync">; 4611// vote.sync.ballot mask, pred 4612def int_nvvm_vote_ballot_sync : 4613 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i1_ty], 4614 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.vote.ballot.sync">, 4615 ClangBuiltin<"__nvvm_vote_ballot_sync">; 4616 4617// 4618// ACTIVEMASK 4619// 4620def int_nvvm_activemask : 4621 Intrinsic<[llvm_i32_ty], [], 4622 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback, IntrHasSideEffects], "llvm.nvvm.activemask">, 4623 ClangBuiltin<"__nvvm_activemask">; 4624 4625// 4626// MATCH.SYNC 4627// 4628// match.any.sync.b32 mask, value 4629def int_nvvm_match_any_sync_i32 : 4630 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4631 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.match.any.sync.i32">, 4632 ClangBuiltin<"__nvvm_match_any_sync_i32">; 4633// match.any.sync.b64 mask, value 4634def int_nvvm_match_any_sync_i64 : 4635 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i64_ty], 4636 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.match.any.sync.i64">, 4637 ClangBuiltin<"__nvvm_match_any_sync_i64">; 4638 4639// match.all instruction have two variants -- one returns a single value, another 4640// returns a pair {value, predicate}. We currently only implement the latter as 4641// that's the variant exposed by CUDA API. 4642 4643// match.all.sync.b32p mask, value 4644def int_nvvm_match_all_sync_i32p : 4645 Intrinsic<[llvm_i32_ty, llvm_i1_ty], [llvm_i32_ty, llvm_i32_ty], 4646 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.match.all.sync.i32p">; 4647// match.all.sync.b64p mask, value 4648def int_nvvm_match_all_sync_i64p : 4649 Intrinsic<[llvm_i32_ty, llvm_i1_ty], [llvm_i32_ty, llvm_i64_ty], 4650 [IntrInaccessibleMemOnly, IntrConvergent, IntrNoCallback], "llvm.nvvm.match.all.sync.i64p">; 4651 4652// 4653// REDUX.SYNC 4654// 4655// redux.sync.min.u32 dst, src, membermask; 4656def int_nvvm_redux_sync_umin : ClangBuiltin<"__nvvm_redux_sync_umin">, 4657 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4658 [IntrConvergent, IntrInaccessibleMemOnly, IntrNoCallback]>; 4659 4660// redux.sync.max.u32 dst, src, membermask; 4661def int_nvvm_redux_sync_umax : ClangBuiltin<"__nvvm_redux_sync_umax">, 4662 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4663 [IntrConvergent, IntrInaccessibleMemOnly, IntrNoCallback]>; 4664 4665// redux.sync.add.s32 dst, src, membermask; 4666def int_nvvm_redux_sync_add : ClangBuiltin<"__nvvm_redux_sync_add">, 4667 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4668 [IntrConvergent, IntrInaccessibleMemOnly, IntrNoCallback]>; 4669 4670// redux.sync.min.s32 dst, src, membermask; 4671def int_nvvm_redux_sync_min : ClangBuiltin<"__nvvm_redux_sync_min">, 4672 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4673 [IntrConvergent, IntrInaccessibleMemOnly, IntrNoCallback]>; 4674 4675// redux.sync.max.s32 dst, src, membermask; 4676def int_nvvm_redux_sync_max : ClangBuiltin<"__nvvm_redux_sync_max">, 4677 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4678 [IntrConvergent, IntrInaccessibleMemOnly, IntrNoCallback]>; 4679 4680// redux.sync.and.b32 dst, src, membermask; 4681def int_nvvm_redux_sync_and : ClangBuiltin<"__nvvm_redux_sync_and">, 4682 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4683 [IntrConvergent, IntrInaccessibleMemOnly, IntrNoCallback]>; 4684 4685// redux.sync.xor.b32 dst, src, membermask; 4686def int_nvvm_redux_sync_xor : ClangBuiltin<"__nvvm_redux_sync_xor">, 4687 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4688 [IntrConvergent, IntrInaccessibleMemOnly, IntrNoCallback]>; 4689 4690// redux.sync.or.b32 dst, src, membermask; 4691def int_nvvm_redux_sync_or : ClangBuiltin<"__nvvm_redux_sync_or">, 4692 Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], 4693 [IntrConvergent, IntrInaccessibleMemOnly, IntrNoCallback]>; 4694 4695// 4696// WMMA instructions 4697// 4698// WMMA.LOAD 4699class NVVM_WMMA_LD<WMMA_REGS Frag, string Layout, int WithStride> 4700 : Intrinsic<Frag.regs, 4701 !if(WithStride, [llvm_anyptr_ty, llvm_i32_ty], [llvm_anyptr_ty]), 4702 [IntrReadMem, IntrArgMemOnly, IntrNoCallback, ReadOnly<ArgIndex<0>>, NoCapture<ArgIndex<0>>], 4703 WMMA_NAME_LDST<"load", Frag, Layout, WithStride>.intr>; 4704 4705// WMMA.STORE.D 4706class NVVM_WMMA_ST<WMMA_REGS Frag, string Layout, int WithStride> 4707 : Intrinsic<[], 4708 !listconcat( 4709 [llvm_anyptr_ty], 4710 Frag.regs, 4711 !if(WithStride, [llvm_i32_ty], [])), 4712 [IntrWriteMem, IntrArgMemOnly, IntrNoCallback, WriteOnly<ArgIndex<0>>, NoCapture<ArgIndex<0>>], 4713 WMMA_NAME_LDST<"store", Frag, Layout, WithStride>.intr>; 4714 4715// Create all load/store variants 4716foreach layout = ["row", "col"] in { 4717 foreach stride = [0, 1] in { 4718 foreach frag = NVVM_MMA_OPS.all_ld_ops in 4719 if NVVM_WMMA_LDST_SUPPORTED<frag, layout>.ret then 4720 def WMMA_NAME_LDST<"load", frag, layout, stride>.record 4721 : NVVM_WMMA_LD<frag, layout, stride>; 4722 foreach frag = NVVM_MMA_OPS.all_st_ops in 4723 if NVVM_WMMA_LDST_SUPPORTED<frag, layout>.ret then 4724 def WMMA_NAME_LDST<"store", frag, layout, stride>.record 4725 : NVVM_WMMA_ST<frag, layout, stride>; 4726 } 4727} 4728 4729// WMMA.MMA 4730class NVVM_WMMA_MMA<string ALayout, string BLayout, int Satfinite, string rnd, string b1op, 4731 WMMA_REGS A, WMMA_REGS B, 4732 WMMA_REGS C, WMMA_REGS D> 4733 : Intrinsic<D.regs, 4734 !listconcat(A.regs, B.regs, C.regs), 4735 [IntrNoMem, IntrNoCallback], 4736 WMMA_NAME<ALayout, BLayout, Satfinite, rnd, b1op, A, B, C, D>.llvm>; 4737 4738foreach layout_a = ["row", "col"] in { 4739 foreach layout_b = ["row", "col"] in { 4740 foreach satf = [0, 1] in { 4741 foreach rnd = ["", "rn", "rz", "rm", "rp"] in { 4742 foreach op = NVVM_MMA_OPS.all_wmma_ops in { 4743 foreach b1op = NVVM_MMA_B1OPS<op>.ret in { 4744 if NVVM_WMMA_SUPPORTED<op, layout_a, layout_b, satf, rnd>.ret then { 4745 def WMMA_NAME<layout_a, layout_b, satf, rnd, b1op, 4746 op[0], op[1], op[2], op[3]>.record 4747 : NVVM_WMMA_MMA<layout_a, layout_b, satf, rnd, b1op, 4748 op[0], op[1], op[2], op[3]>; 4749 } 4750 } // b1op 4751 } // op 4752 } // rnd 4753 } // satf 4754 } // layout_b 4755} // layout_a 4756 4757// MMA 4758class NVVM_MMA<string ALayout, string BLayout, int Satfinite, string b1op, 4759 WMMA_REGS A, WMMA_REGS B, WMMA_REGS C, WMMA_REGS D> 4760 : Intrinsic<D.regs, 4761 !listconcat(A.regs, B.regs, C.regs), 4762 [IntrNoMem, IntrNoCallback], 4763 MMA_NAME<ALayout, BLayout, Satfinite, b1op, A, B, C, D>.llvm>; 4764 4765foreach layout_a = ["row", "col"] in { 4766 foreach layout_b = ["row", "col"] in { 4767 foreach satf = [0, 1] in { 4768 foreach op = NVVM_MMA_OPS.all_mma_ops in { 4769 foreach b1op = NVVM_MMA_B1OPS<op>.ret in { 4770 if NVVM_MMA_SUPPORTED<op, layout_a, layout_b, satf>.ret then { 4771 def MMA_NAME<layout_a, layout_b, satf, b1op, op[0], op[1], op[2], op[3]>.record 4772 : NVVM_MMA<layout_a, layout_b, satf, b1op, op[0], op[1], op[2], op[3]>; 4773 } 4774 } // b1op 4775 } // op 4776 } // satf 4777 } // layout_b 4778} // layout_a 4779 4780// LDMATRIX 4781class NVVM_LDMATRIX<WMMA_REGS Frag, int Transposed> 4782 : Intrinsic<Frag.regs, [llvm_anyptr_ty], 4783 [IntrReadMem, IntrArgMemOnly, IntrNoCallback, ReadOnly<ArgIndex<0>>, 4784 NoCapture<ArgIndex<0>>], 4785 LDMATRIX_NAME<Frag, Transposed>.intr>; 4786 4787foreach transposed = [0, 1] in { 4788 foreach frag = NVVM_MMA_OPS.all_ldmatrix_ops in { 4789 if NVVM_LDMATRIX_SUPPORTED<frag>.ret then { 4790 def LDMATRIX_NAME<frag, transposed>.record 4791 : NVVM_LDMATRIX<frag, transposed>; 4792 } 4793 } 4794} 4795 4796def int_nvvm_mapa 4797 : DefaultAttrsIntrinsic<[llvm_ptr_ty], [llvm_ptr_ty, llvm_i32_ty], 4798 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 4799 "llvm.nvvm.mapa">; 4800def int_nvvm_mapa_shared_cluster 4801 : DefaultAttrsIntrinsic<[llvm_shared_ptr_ty], [llvm_shared_ptr_ty, llvm_i32_ty], 4802 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 4803 "llvm.nvvm.mapa.shared.cluster">; 4804def int_nvvm_getctarank 4805 : DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_ptr_ty], 4806 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 4807 "llvm.nvvm.getctarank">; 4808def int_nvvm_getctarank_shared_cluster 4809 : DefaultAttrsIntrinsic<[llvm_i32_ty], [llvm_shared_ptr_ty], 4810 [IntrNoMem, IntrSpeculatable, NoCapture<ArgIndex<0>>], 4811 "llvm.nvvm.getctarank.shared.cluster">; 4812def int_nvvm_is_explicit_cluster 4813 : DefaultAttrsIntrinsic<[llvm_i1_ty], [], 4814 [IntrNoMem, IntrSpeculatable, NoUndef<RetIndex>], 4815 "llvm.nvvm.is_explicit_cluster">; 4816 4817// Setmaxnreg inc/dec intrinsics 4818def int_nvvm_setmaxnreg_inc_sync_aligned_u32 4819 : DefaultAttrsIntrinsic<[], [llvm_i32_ty], 4820 [IntrConvergent, IntrNoMem, IntrHasSideEffects, ImmArg<ArgIndex<0>>], 4821 "llvm.nvvm.setmaxnreg.inc.sync.aligned.u32">; 4822def int_nvvm_setmaxnreg_dec_sync_aligned_u32 4823 : DefaultAttrsIntrinsic<[], [llvm_i32_ty], 4824 [IntrConvergent, IntrNoMem, IntrHasSideEffects, ImmArg<ArgIndex<0>>], 4825 "llvm.nvvm.setmaxnreg.dec.sync.aligned.u32">; 4826 4827// Exit 4828def int_nvvm_exit : ClangBuiltin<"__nvvm_exit">, 4829 Intrinsic<[], [], [IntrConvergent, IntrInaccessibleMemOnly, IntrNoReturn]>; 4830 4831} // let TargetPrefix = "nvvm" 4832