OSDN Git Service

Support AVX for cmpss/cmpsd.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gcc.target / i386 / pr32268.c
1 /* { dg-do run { target *-*-linux* } } */
2 /* { dg-options "-O2" } */
3
4 extern void abort(void);
5
6 int __attribute__ ((__noinline__))
7 test_lt(__float128 x, __float128 y)
8 {
9   return x < y;
10 }
11
12 int __attribute__ ((__noinline__))
13 test_gt (__float128 x, __float128 y)
14 {
15   return x > y;
16 }
17
18 int main()
19 {
20   __float128 a = 0.0;
21   __float128 b = 1.0;
22
23   int r;
24
25   r = test_lt (a, b);
26   if (r != ((double) a < (double) b))
27     abort();
28
29   r = test_gt (a, b);
30   if (r != ((double) a > (double) b))
31     abort();
32
33   return 0;
34 }