(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.target/
arm/
pr63408.c
       1  /* { dg-do run }  */
       2  /* { dg-options "-O2" } */
       3  void abort (void) __attribute__ ((noreturn));
       4  float __attribute__((noinline))
       5  f(float a, int b)
       6  {
       7    return a - (((float)b / 0x7fffffff) * 100);
       8  }
       9  
      10  int
      11  main (void)
      12  {
      13    float a[] = { 100.0, 0.0, 0.0};
      14    int b[] = { 0x7fffffff, 0x7fffffff/100.0f, -0x7fffffff / 100.0f};
      15    float c[] = { 0.0, -1.0, 1.0 };
      16    int i;
      17  
      18    for (i = 0; i < (sizeof(a) / sizeof (float)); i++)
      19      if (f (a[i], b[i]) != c[i])
      20  	abort ();
      21  
      22    return 0;
      23  }