|
4 | 4 |
|
5 | 5 | typedef unsigned int uint;
|
6 | 6 |
|
7 |
| -kernel void test_builtins_amdgcn_gws_insts(uint a, uint b) { |
| 7 | +#pragma OPENCL EXTENSION cl_khr_fp64:enable |
| 8 | + |
| 9 | +typedef float v2f __attribute__((ext_vector_type(2))); |
| 10 | +typedef float v4f __attribute__((ext_vector_type(4))); |
| 11 | +typedef float v16f __attribute__((ext_vector_type(16))); |
| 12 | +typedef float v32f __attribute__((ext_vector_type(32))); |
| 13 | +typedef half v4h __attribute__((ext_vector_type(4))); |
| 14 | +typedef half v8h __attribute__((ext_vector_type(8))); |
| 15 | +typedef half v16h __attribute__((ext_vector_type(16))); |
| 16 | +typedef half v32h __attribute__((ext_vector_type(32))); |
| 17 | +typedef int v2i __attribute__((ext_vector_type(2))); |
| 18 | +typedef int v4i __attribute__((ext_vector_type(4))); |
| 19 | +typedef int v16i __attribute__((ext_vector_type(16))); |
| 20 | +typedef int v32i __attribute__((ext_vector_type(32))); |
| 21 | +typedef short v2s __attribute__((ext_vector_type(2))); |
| 22 | +typedef short v4s __attribute__((ext_vector_type(4))); |
| 23 | +typedef short v8s __attribute__((ext_vector_type(8))); |
| 24 | +typedef short v16s __attribute__((ext_vector_type(16))); |
| 25 | +typedef short v32s __attribute__((ext_vector_type(32))); |
| 26 | +typedef double v4d __attribute__((ext_vector_type(4))); |
| 27 | + |
| 28 | +void builtin_test_unsupported(global v32f* out_v32f, |
| 29 | + global v16f* out_v16f, |
| 30 | + global v4f* out_v4f, |
| 31 | + global v32i* out_v32i, |
| 32 | + global v16i* out_v16i, |
| 33 | + global v4i* out_v4i, |
| 34 | + global v4d* out_v4d, |
| 35 | + global double* out_double, |
| 36 | + double a_double , double b_double , double c_double, |
| 37 | + float a_float , float b_float , float c_float, |
| 38 | + int a_int , int b_int , int c_int, |
| 39 | + long a_long , long b_long , long c_long, |
| 40 | + v4d a_v4d , v4d b_v4d , v4d c_v4d, |
| 41 | + v8s a_v8s , v8s b_v8s , v8s c_v8s, |
| 42 | + v4s a_v4s , v4s b_v4s , v4s c_v4s, |
| 43 | + v2s a_v2s , v2s b_v2s , v2s c_v2s, |
| 44 | + v2i a_v2i , v2i b_v2i , v2i c_v2i, |
| 45 | + v16i a_v16i , v16i b_v16i , v16i c_v16i, |
| 46 | + v32i a_v32i , v32i b_v32i , v32i c_v32i, |
| 47 | + v4i a_v4i , v4i b_v4i , v4i c_v4i, |
| 48 | + v2f a_v2f , v2f b_v2f , v2f c_v2f, |
| 49 | + v4f a_v4f , v4f b_v4f , v4f c_v4f, |
| 50 | + v16f a_v16f , v16f b_v16f , v16f c_v16f, |
| 51 | + v32f a_v32f , v32f b_v32f , v32f c_v32f, |
| 52 | + v4h a_v4h , v4h b_v4h , v4h c_v4h, |
| 53 | + v8h a_v8h , v8h b_v8h , v8h c_v8h, |
| 54 | + int idx, |
| 55 | + |
| 56 | + uint a, uint b) { |
| 57 | + |
8 | 58 | __builtin_amdgcn_ds_gws_init(a, b); // expected-error {{'__builtin_amdgcn_ds_gws_init' needs target feature gws}}
|
9 | 59 | __builtin_amdgcn_ds_gws_barrier(a, b); // expected-error {{'__builtin_amdgcn_ds_gws_barrier' needs target feature gws}}
|
10 | 60 | __builtin_amdgcn_ds_gws_sema_v(a); // expected-error {{'__builtin_amdgcn_ds_gws_sema_v' needs target feature gws}}
|
11 | 61 | __builtin_amdgcn_ds_gws_sema_br(a, b); // expected-error {{'__builtin_amdgcn_ds_gws_sema_br' needs target feature gws}}
|
12 | 62 | __builtin_amdgcn_ds_gws_sema_p(a); // expected-error {{'__builtin_amdgcn_ds_gws_sema_p' needs target feature gws}}
|
| 63 | + |
| 64 | + *out_v32f = __builtin_amdgcn_mfma_f32_32x32x1f32(a_float, b_float, c_v32f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x1f32' needs target feature mai-insts}} |
| 65 | + *out_v16f = __builtin_amdgcn_mfma_f32_16x16x1f32(a_float, b_float, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x1f32' needs target feature mai-insts}} |
| 66 | + *out_v4f = __builtin_amdgcn_mfma_f32_4x4x1f32(a_float, b_float, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_4x4x1f32' needs target feature mai-insts}} |
| 67 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x2f32(a_float, b_float, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x2f32' needs target feature mai-insts}} |
| 68 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x4f32(a_float, b_float, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x4f32' needs target feature mai-insts}} |
| 69 | + *out_v32f = __builtin_amdgcn_mfma_f32_32x32x4f16(a_v4h, b_v4h, c_v32f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x4f16' needs target feature mai-insts}} |
| 70 | + *out_v16f = __builtin_amdgcn_mfma_f32_16x16x4f16(a_v4h, b_v4h, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x4f16' needs target feature mai-insts}} |
| 71 | + *out_v4f = __builtin_amdgcn_mfma_f32_4x4x4f16(a_v4h, b_v4h, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_4x4x4f16' needs target feature mai-insts}} |
| 72 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x8f16(a_v4h, b_v4h, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x8f16' needs target feature mai-insts}} |
| 73 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x16f16(a_v4h, b_v4h, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x16f16' needs target feature mai-insts}} |
| 74 | + *out_v32i = __builtin_amdgcn_mfma_i32_32x32x4i8(a_int, b_int, c_v32i, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_i32_32x32x4i8' needs target feature mai-insts}} |
| 75 | + *out_v16i = __builtin_amdgcn_mfma_i32_16x16x4i8(a_int, b_int, c_v16i, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_i32_16x16x4i8' needs target feature mai-insts}} |
| 76 | + *out_v4i = __builtin_amdgcn_mfma_i32_4x4x4i8(a_int, b_int, c_v4i, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_i32_4x4x4i8' needs target feature mai-insts}} |
| 77 | + *out_v16i = __builtin_amdgcn_mfma_i32_32x32x8i8(a_int, b_int, c_v16i, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_i32_32x32x8i8' needs target feature mai-insts}} |
| 78 | + *out_v4i = __builtin_amdgcn_mfma_i32_16x16x16i8(a_int, b_int, c_v4i, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_i32_16x16x16i8' needs target feature mai-insts}} |
| 79 | + *out_v32f = __builtin_amdgcn_mfma_f32_32x32x2bf16(a_v2s, b_v2s, c_v32f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x2bf16' needs target feature mai-insts}} |
| 80 | + *out_v16f = __builtin_amdgcn_mfma_f32_16x16x2bf16(a_v2s, b_v2s, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x2bf16' needs target feature mai-insts}} |
| 81 | + *out_v4f = __builtin_amdgcn_mfma_f32_4x4x2bf16(a_v2s, b_v2s, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_4x4x2bf16' needs target feature mai-insts}} |
| 82 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x4bf16(a_v2s, b_v2s, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x4bf16' needs target feature mai-insts}} |
| 83 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x8bf16(a_v2s, b_v2s, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x8bf16' needs target feature mai-insts}} |
| 84 | + *out_v32f = __builtin_amdgcn_mfma_f32_32x32x4bf16_1k(a_v4s, b_v4s, c_v32f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x4bf16_1k' needs target feature mai-insts}} |
| 85 | + *out_v16f = __builtin_amdgcn_mfma_f32_16x16x4bf16_1k(a_v4s, b_v4s, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x4bf16_1k' needs target feature mai-insts}} |
| 86 | + *out_v4f = __builtin_amdgcn_mfma_f32_4x4x4bf16_1k(a_v4s, b_v4s, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_4x4x4bf16_1k' needs target feature mai-insts}} |
| 87 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x8bf16_1k(a_v4s, b_v4s, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x8bf16_1k' needs target feature mai-insts}} |
| 88 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x16bf16_1k(a_v4s, b_v4s, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x16bf16_1k' needs target feature mai-insts}} |
| 89 | + *out_v4d = __builtin_amdgcn_mfma_f64_16x16x4f64(a_double, b_double, c_v4d, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f64_16x16x4f64' needs target feature mai-insts}} |
| 90 | + *out_double = __builtin_amdgcn_mfma_f64_4x4x4f64(a_double, b_double, c_double, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f64_4x4x4f64' needs target feature mai-insts}} |
| 91 | + *out_v4i = __builtin_amdgcn_mfma_i32_16x16x32_i8(a_long, b_long, c_v4i, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_i32_16x16x32_i8' needs target feature mai-insts}} |
| 92 | + *out_v16i = __builtin_amdgcn_mfma_i32_32x32x16_i8(a_long, b_long, c_v16i, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_i32_32x32x16_i8' needs target feature mai-insts}} |
| 93 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x8_xf32(a_v2f, b_v2f, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x8_xf32' needs target feature mai-insts}} |
| 94 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x4_xf32(a_v2f, b_v2f, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x4_xf32' needs target feature mai-insts}} |
| 95 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x32_bf8_bf8(a_long, b_long, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x32_bf8_bf8' needs target feature fp8-insts}} |
| 96 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x32_bf8_fp8(a_long, b_long, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x32_bf8_fp8' needs target feature fp8-insts}} |
| 97 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x32_fp8_bf8(a_long, b_long, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x32_fp8_bf8' needs target feature fp8-insts}} |
| 98 | + *out_v4f = __builtin_amdgcn_mfma_f32_16x16x32_fp8_fp8(a_long, b_long, c_v4f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_16x16x32_fp8_fp8' needs target feature fp8-insts}} |
| 99 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x16_bf8_bf8(a_long, b_long, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x16_bf8_bf8' needs target feature fp8-insts}} |
| 100 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x16_bf8_fp8(a_long, b_long, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x16_bf8_fp8' needs target feature fp8-insts}} |
| 101 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x16_fp8_bf8(a_long, b_long, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x16_fp8_bf8' needs target feature fp8-insts}} |
| 102 | + *out_v16f = __builtin_amdgcn_mfma_f32_32x32x16_fp8_fp8(a_long, b_long, c_v16f, 0, 0, 0); // expected-error {{'__builtin_amdgcn_mfma_f32_32x32x16_fp8_fp8' needs target feature fp8-insts}} |
| 103 | + *out_v4f = __builtin_amdgcn_smfmac_f32_16x16x32_f16(a_v4h, b_v8h, c_v4f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_16x16x32_f16' needs target feature mai-insts}} |
| 104 | + *out_v16f = __builtin_amdgcn_smfmac_f32_32x32x16_f16(a_v4h, b_v8h, c_v16f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_32x32x16_f16' needs target feature mai-insts}} |
| 105 | + *out_v4f = __builtin_amdgcn_smfmac_f32_16x16x32_bf16(a_v4s, b_v8s, c_v4f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_16x16x32_bf16' needs target feature mai-insts}} |
| 106 | + *out_v16f = __builtin_amdgcn_smfmac_f32_32x32x16_bf16(a_v4s, b_v8s, c_v16f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_32x32x16_bf16' needs target feature mai-insts}} |
| 107 | + *out_v4i = __builtin_amdgcn_smfmac_i32_16x16x64_i8(a_v2i, b_v4i, c_v4i, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_i32_16x16x64_i8' needs target feature mai-insts}} |
| 108 | + *out_v16i = __builtin_amdgcn_smfmac_i32_32x32x32_i8(a_v2i, b_v4i, c_v16i, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_i32_32x32x32_i8' needs target feature mai-insts}} |
| 109 | + *out_v4f = __builtin_amdgcn_smfmac_f32_16x16x64_bf8_bf8(a_v2i, b_v4i, c_v4f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_16x16x64_bf8_bf8' needs target feature fp8-insts}} |
| 110 | + *out_v4f = __builtin_amdgcn_smfmac_f32_16x16x64_bf8_fp8(a_v2i, b_v4i, c_v4f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_16x16x64_bf8_fp8' needs target feature fp8-insts}} |
| 111 | + *out_v4f = __builtin_amdgcn_smfmac_f32_16x16x64_fp8_bf8(a_v2i, b_v4i, c_v4f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_16x16x64_fp8_bf8' needs target feature fp8-insts}} |
| 112 | + *out_v4f = __builtin_amdgcn_smfmac_f32_16x16x64_fp8_fp8(a_v2i, b_v4i, c_v4f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_16x16x64_fp8_fp8' needs target feature fp8-insts}} |
| 113 | + *out_v16f = __builtin_amdgcn_smfmac_f32_32x32x32_bf8_bf8(a_v2i, b_v4i, c_v16f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_32x32x32_bf8_bf8' needs target feature fp8-insts}} |
| 114 | + *out_v16f = __builtin_amdgcn_smfmac_f32_32x32x32_bf8_fp8(a_v2i, b_v4i, c_v16f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_32x32x32_bf8_fp8' needs target feature fp8-insts}} |
| 115 | + *out_v16f = __builtin_amdgcn_smfmac_f32_32x32x32_fp8_bf8(a_v2i, b_v4i, c_v16f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_32x32x32_fp8_bf8' needs target feature fp8-insts}} |
| 116 | + *out_v16f = __builtin_amdgcn_smfmac_f32_32x32x32_fp8_fp8(a_v2i, b_v4i, c_v16f, idx, 0, 0); // expected-error {{'__builtin_amdgcn_smfmac_f32_32x32x32_fp8_fp8' needs target feature fp8-insts}} |
13 | 117 | }
|
0 commit comments