1  /* Test for "invalid" exceptions from __float128 comparisons.  */
       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 } */
       8  
       9  #include <fenv.h>
      10  #include <stdlib.h>
      11  
      12  int
      13  main (void)
      14  {
      15    volatile __float128 a = __builtin_nanq (""), b = 0.0q;
      16    volatile int r = a < b;
      17    if (!fetestexcept (FE_INVALID))
      18      abort ();
      19    if (r)
      20      abort ();
      21    exit (0);
      22  }