| 1 |
// Test that NEON types are defined, even when arm_neon.h is not included. |
| 2 |
// as required by AAPCS64 "Support for Advanced SIMD Extensions". |
| 3 |
|
| 4 |
// RUN: %clang_cc1 -ast-dump -triple aarch64-linux-gnu %s -x c | FileCheck %s |
| 5 |
// RUN: %clang_cc1 -ast-dump -triple aarch64-linux-gnu %s -x c++ | FileCheck %s |
| 6 |
// RUN: %clang_cc1 -verify -verify-ignore-unexpected=note -triple x86_64 %s -x c |
| 7 |
// RUN: %clang_cc1 -verify -verify-ignore-unexpected=note -triple x86_64 %s -x c++ |
| 8 |
// RUN: %clang_cc1 -verify -verify-ignore-unexpected=note -triple arm-linux-gnu %s -x c |
| 9 |
// RUN: %clang_cc1 -verify -verify-ignore-unexpected=note -triple arm-linux-gnu %s -x c++ |
| 10 |
|
| 11 |
__Int8x8_t Int8x8; |
| 12 |
// CHECK: Int8x8 '__Int8x8_t':'__attribute__((neon_vector_type(8))) signed char' |
| 13 |
// expected-error@-2{{unknown type name '__Int8x8_t'}} |
| 14 |
|
| 15 |
__Int16x4_t Int16x4; |
| 16 |
// CHECK: Int16x4 '__Int16x4_t':'__attribute__((neon_vector_type(4))) short' |
| 17 |
// expected-error@-2{{unknown type name '__Int16x4_t'}} |
| 18 |
|
| 19 |
__Int32x2_t Int32x2; |
| 20 |
// CHECK: Int32x2 '__Int32x2_t':'__attribute__((neon_vector_type(2))) int' |
| 21 |
// expected-error@-2{{unknown type name '__Int32x2_t'}} |
| 22 |
|
| 23 |
__Uint8x8_t Uint8x8; |
| 24 |
// CHECK: Uint8x8 '__Uint8x8_t':'__attribute__((neon_vector_type(8))) unsigned char' |
| 25 |
// expected-error@-2{{unknown type name '__Uint8x8_t'}} |
| 26 |
|
| 27 |
__Uint16x4_t Uint16x4; |
| 28 |
// CHECK: Uint16x4 '__Uint16x4_t':'__attribute__((neon_vector_type(4))) unsigned short' |
| 29 |
// expected-error@-2{{unknown type name '__Uint16x4_t'}} |
| 30 |
|
| 31 |
__Uint32x2_t Uint32x2; |
| 32 |
// CHECK: Uint32x2 '__Uint32x2_t':'__attribute__((neon_vector_type(2))) unsigned int' |
| 33 |
// expected-error@-2{{unknown type name '__Uint32x2_t'}} |
| 34 |
|
| 35 |
__Float16x4_t Float16x4; |
| 36 |
// CHECK: Float16x4 '__Float16x4_t':'__attribute__((neon_vector_type(4))) __fp16' |
| 37 |
// expected-error@-2{{unknown type name '__Float16x4_t'}} |
| 38 |
|
| 39 |
__Float32x2_t Float32x2; |
| 40 |
// CHECK: Float32x2 '__Float32x2_t':'__attribute__((neon_vector_type(2))) float' |
| 41 |
// expected-error@-2{{unknown type name '__Float32x2_t'}} |
| 42 |
|
| 43 |
__Poly8x8_t Poly8x8; |
| 44 |
// CHECK: Poly8x8 '__Poly8x8_t':'__attribute__((neon_polyvector_type(8))) unsigned char' |
| 45 |
// expected-error@-2{{unknown type name '__Poly8x8_t'}} |
| 46 |
|
| 47 |
__Poly16x4_t Poly16x4; |
| 48 |
// CHECK: Poly16x4 '__Poly16x4_t':'__attribute__((neon_polyvector_type(4))) unsigned short' |
| 49 |
// expected-error@-2{{unknown type name '__Poly16x4_t'}} |
| 50 |
|
| 51 |
__Bfloat16x4_t Bfloat16x4; |
| 52 |
// CHECK: Bfloat16x4 '__Bfloat16x4_t':'__attribute__((neon_vector_type(4))) __bf16' |
| 53 |
// expected-error@-2{{unknown type name '__Bfloat16x4_t'}} |
| 54 |
|
| 55 |
__Int8x16_t Int8x16; |
| 56 |
// CHECK: Int8x16 '__Int8x16_t':'__attribute__((neon_vector_type(16))) signed char' |
| 57 |
// expected-error@-2{{unknown type name '__Int8x16_t'}} |
| 58 |
|
| 59 |
__Int16x8_t Int16x8; |
| 60 |
// CHECK: Int16x8 '__Int16x8_t':'__attribute__((neon_vector_type(8))) short' |
| 61 |
// expected-error@-2{{unknown type name '__Int16x8_t'}} |
| 62 |
|
| 63 |
__Int32x4_t Int32x4; |
| 64 |
// CHECK: Int32x4 '__Int32x4_t':'__attribute__((neon_vector_type(4))) int' |
| 65 |
// expected-error@-2{{unknown type name '__Int32x4_t'}} |
| 66 |
|
| 67 |
__Int64x2_t Int64x2; |
| 68 |
// CHECK: Int64x2 '__Int64x2_t':'__attribute__((neon_vector_type(2))) long' |
| 69 |
// expected-error@-2{{unknown type name '__Int64x2_t'}} |
| 70 |
|
| 71 |
__Uint8x16_t Uint8x16; |
| 72 |
// CHECK: Uint8x16 '__Uint8x16_t':'__attribute__((neon_vector_type(16))) unsigned char' |
| 73 |
// expected-error@-2{{unknown type name '__Uint8x16_t'}} |
| 74 |
|
| 75 |
__Uint16x8_t Uint16x8; |
| 76 |
// CHECK: Uint16x8 '__Uint16x8_t':'__attribute__((neon_vector_type(8))) unsigned short' |
| 77 |
// expected-error@-2{{unknown type name '__Uint16x8_t'}} |
| 78 |
|
| 79 |
__Uint32x4_t Uint32x4; |
| 80 |
// CHECK: Uint32x4 '__Uint32x4_t':'__attribute__((neon_vector_type(4))) unsigned int' |
| 81 |
// expected-error@-2{{unknown type name '__Uint32x4_t'}} |
| 82 |
|
| 83 |
__Uint64x2_t Uint64x2; |
| 84 |
// CHECK: Uint64x2 '__Uint64x2_t':'__attribute__((neon_vector_type(2))) unsigned long' |
| 85 |
// expected-error@-2{{unknown type name '__Uint64x2_t'}} |
| 86 |
|
| 87 |
__Float16x8_t Float16x8; |
| 88 |
// CHECK: Float16x8 '__Float16x8_t':'__attribute__((neon_vector_type(8))) __fp16' |
| 89 |
// expected-error@-2{{unknown type name '__Float16x8_t'}} |
| 90 |
|
| 91 |
__Float32x4_t Float32x4; |
| 92 |
// CHECK: Float32x4 '__Float32x4_t':'__attribute__((neon_vector_type(4))) float' |
| 93 |
// expected-error@-2{{unknown type name '__Float32x4_t'}} |
| 94 |
|
| 95 |
__Float64x2_t Float64x2; |
| 96 |
// CHECK: Float64x2 '__Float64x2_t':'__attribute__((neon_vector_type(2))) double' |
| 97 |
// expected-error@-2{{unknown type name '__Float64x2_t'}} |
| 98 |
|
| 99 |
__Poly8x16_t Poly8x16; |
| 100 |
// CHECK: Poly8x16 '__Poly8x16_t':'__attribute__((neon_polyvector_type(16))) unsigned char' |
| 101 |
// expected-error@-2{{unknown type name '__Poly8x16_t'}} |
| 102 |
|
| 103 |
__Poly16x8_t Poly16x8; |
| 104 |
// CHECK: Poly16x8 '__Poly16x8_t':'__attribute__((neon_polyvector_type(8))) unsigned short' |
| 105 |
// expected-error@-2{{unknown type name '__Poly16x8_t'}} |
| 106 |
|
| 107 |
__Poly64x2_t Poly64x2; |
| 108 |
// CHECK: Poly64x2 '__Poly64x2_t':'__attribute__((neon_polyvector_type(2))) unsigned long' |
| 109 |
// expected-error@-2{{unknown type name '__Poly64x2_t'}} |
| 110 |
|
| 111 |
__Bfloat16x8_t Bfloat16x8; |
| 112 |
// CHECK: Bfloat16x8 '__Bfloat16x8_t':'__attribute__((neon_vector_type(8))) __bf16' |
| 113 |
// expected-error@-2{{unknown type name '__Bfloat16x8_t'}} |
| 114 |
|
| 115 |
__mfp8 mfp8; |
| 116 |
// CHECK: mfp8 '__mfp8' |
| 117 |
// expected-error@-2{{unknown type name '__mfp8'}} |
| 118 |
|
| 119 |
__Mfloat8x8_t Mfloat8x8; |
| 120 |
// CHECK: Mfloat8x8 '__Mfloat8x8_t':'__attribute__((neon_vector_type(8))) __mfp8' |
| 121 |
// expected-error@-2{{unknown type name '__Mfloat8x8_t'}} |
| 122 |
|
| 123 |
__Mfloat8x16_t Mfloat8x16; |
| 124 |
// CHECK: Mfloat8x16 '__Mfloat8x16_t':'__attribute__((neon_vector_type(16))) __mfp8' |
| 125 |
// expected-error@-2{{unknown type name '__Mfloat8x16_t'}} |