* gcc.dg/torture/stackalign/builtin-apply-2.c: Fix skip-if syntax.
[official-gcc.git] / gcc / testsuite / gcc.dg / torture / float128-div-underflow.c
blobdc284dec6dcb57abb683b62b4d90526fef2dfab6
1 /* Test for spurious underflow from __float128 division. */
2 /* { dg-do run } */
3 /* { dg-options "" } */
4 /* { dg-require-effective-target __float128 } */
5 /* { dg-require-effective-target base_quadfloat_support } */
6 /* { dg-require-effective-target fenv_exceptions } */
7 /* { dg-add-options __float128 } */
9 #include <fenv.h>
10 #include <stdlib.h>
12 int
13 main (void)
15 volatile __float128 a = 0x0.fffp-16382q, b = 0x0.fffp0q, c;
16 c = a / b;
17 if (fetestexcept (FE_UNDERFLOW | FE_INEXACT))
18 abort ();
19 if (c != 0x1p-16382q)
20 abort ();
21 exit (0);