blob: 09de38c6b7072292e93ce4aba2900218aeaec453 [file] [log] [blame]
David Chisnalla87d8592012-12-08 09:06:08 +00001// RUN: %clang_cc1 -triple mips64-unknown-freebsd -std=c11 -verify %s
2// RUN: %clang_cc1 -triple mips-unknown-freebsd -std=c11 -verify %s
Rafael Espindolac8c61892013-01-08 16:09:04 +00003// RUN: %clang_cc1 -triple mips-unknown-linux -std=c11 -verify %s
4// RUN: %clang_cc1 -triple mips64-unknown-linux -std=c11 -verify %s
David Chisnalla87d8592012-12-08 09:06:08 +00005// expected-no-diagnostics
6
7#ifdef _ABI64
8# ifdef __FreeBSD__
9_Static_assert(sizeof(long double) == 8, "sizeof long double is wrong");
10_Static_assert(_Alignof(long double) == 8, "alignof long double is wrong");
11# else
12_Static_assert(sizeof(long double) == 16, "sizeof long double is wrong");
13_Static_assert(_Alignof(long double) == 16, "alignof long double is wrong");
14# endif
15#else
16_Static_assert(sizeof(long double) == 8, "sizeof long double is wrong");
17_Static_assert(_Alignof(long double) == 8, "alignof long double is wrong");
18#endif
19