OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.c-torture/] [execute/] [pr39228.c] - Rev 297

Compare with Previous | Blame | View Log

extern void abort (void);
 
static int __attribute__((always_inline)) testf (float b)
{
  float c = 1.01f * b;
 
  return __builtin_isinff (c);
}
 
static int __attribute__((always_inline)) test (double b)
{
  double c = 1.01 * b;
 
  return __builtin_isinf (c);
}
 
static int __attribute__((always_inline)) testl (long double b)
{
  long double c = 1.01L * b;
 
  return __builtin_isinfl (c);
}
 
int main()
{
  if (testf (__FLT_MAX__) < 1)
    abort ();
 
  if (test (__DBL_MAX__) < 1)
    abort ();
 
  if (testl (__LDBL_MAX__) < 1)
    abort ();
 
  return 0;
}
 

Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.