1// RUN: llvm-tblgen -gen-intrinsic-impl %s | FileCheck %s 2// XFAIL: vg_leak 3 4class IntrinsicProperty; 5class SDNodeProperty; 6 7class ValueType<int size, int value> { 8 string Namespace = "MVT"; 9 int Size = size; 10 int Value = value; 11} 12 13class LLVMType<ValueType vt> { 14 ValueType VT = vt; 15} 16 17class Intrinsic<string name, list<LLVMType> param_types = []> { 18 string LLVMName = name; 19 bit isTarget = 0; 20 string TargetPrefix = ""; 21 list<LLVMType> RetTypes = []; 22 list<LLVMType> ParamTypes = param_types; 23 list<IntrinsicProperty> IntrProperties = []; 24 list<SDNodeProperty> Properties = []; 25} 26 27// isVoid needs to match the definition in ValueTypes.td 28def isVoid : ValueType<0, 111>; // Produces no value 29def llvm_vararg_ty : LLVMType<isVoid>; // this means vararg here 30 31// CHECK: /* 0 */ 0, 29, 0, 32def int_foo : Intrinsic<"llvm.foo", [llvm_vararg_ty]>; 33