Dead
[official-gcc.git] / gomp-20050608-branch / gcc / testsuite / gcc.target / x86_64 / abi / test_basic_struct_size_and_align.c
blob783da6ff56fd51977828b5863cbcc70be562658c
1 /* This checks size and alignment of structs with a single basic type
2 element. All basic types are checked. */
4 #include "defines.h"
5 #include "macros.h"
8 int
9 main (void)
11 /* Integral types. */
12 run_signed_tests3(check_basic_struct_size_and_align, char, TYPE_SIZE_CHAR, TYPE_ALIGN_CHAR);
13 run_signed_tests3(check_basic_struct_size_and_align, short, TYPE_SIZE_SHORT, TYPE_ALIGN_SHORT);
14 run_signed_tests3(check_basic_struct_size_and_align, int, TYPE_SIZE_INT, TYPE_ALIGN_INT);
15 run_signed_tests3(check_basic_struct_size_and_align, long, TYPE_SIZE_LONG, TYPE_ALIGN_LONG);
16 run_signed_tests3(check_basic_struct_size_and_align, long long, TYPE_SIZE_LONG_LONG, TYPE_ALIGN_LONG_LONG);
17 #ifdef CHECK_INT128
18 run_signed_tests3(check_basic_struct_size_and_align, __int128, TYPE_SIZE_INT128, TYPE_ALIGN_INT128);
19 #endif
20 check_basic_struct_size_and_align(enum dummytype, TYPE_SIZE_ENUM, TYPE_ALIGN_ENUM);
22 /* Floating point types. */
23 check_basic_struct_size_and_align(float, TYPE_SIZE_FLOAT, TYPE_ALIGN_FLOAT);
24 check_basic_struct_size_and_align(double, TYPE_SIZE_DOUBLE, TYPE_ALIGN_DOUBLE);
25 #ifdef CHECK_LONG_DOUBLE
26 check_basic_struct_size_and_align(long double, TYPE_SIZE_LONG_DOUBLE, TYPE_ALIGN_LONG_DOUBLE);
27 #endif
28 #ifdef CHECK_FLOAT128
29 check_basic_struct_size_and_align(__float128, TYPE_SIZE_FLOAT128, TYPE_ALIGN_FLOAT128);
30 #endif
32 /* Packed types - MMX, 3DNow!, SSE and SSE2. */
33 #ifdef CHECK_M64_M128
34 check_basic_struct_size_and_align(__m64, TYPE_SIZE_M64, TYPE_ALIGN_M64);
35 check_basic_struct_size_and_align(__m128, TYPE_SIZE_M128, TYPE_ALIGN_M128);
36 #endif
38 /* Pointer types. The function pointer doesn't work with these macros. */
39 check_basic_struct_size_and_align(void *, TYPE_SIZE_POINTER, TYPE_ALIGN_POINTER);
41 return 0;