Hi,
I've tested this with 64-bit gcc-11.3.0 and (both 32-bit and 64-bit)
gcc-13.1.0 nad am seeing the same brokenness.

The demo:
/****************/
/* isfinite.c */
#include <stdio.h>
#include <math.h>
#include <quadmath.h>

int main(void) {
  __float128 x = 1.0Q;
  if(isfinite(x)) printf("OK\n");
  else printf("NOT ok\n");
  return 0;
}

/*
Build with:
gcc -o isfinite.exe isfinite.c -lquadmath
*/
/**************/
It builds without any warnings being issued, but the resultant executable
takes about 4 seconds to run and produces no output.

It works fine if I cast the variable 'x' to a long double.
That is, it works fine if I replace:
  if(isfinite(x)) printf("OK\n");
with:
  if(isfinite((long double)x)) printf("OK\n");

Is this a mingw-w64 bug or a gcc bug ?

Cheers,
Rob

_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to