https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114126
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jakub at gcc dot gnu.org Resolution|--- |INVALID Status|UNCONFIRMED |RESOLVED --- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Why do you think this is a bug? #include <math.h> #include <stdlib.h> #include <stdio.h> int main () { _Float128 f = tanf128 (M_PI_2f128); volatile _Float128 g = M_PI_2f128; g = tanf128 (g); char buf[128]; strfromf128 (buf, 128, "%.34a", f); printf ("%s\n", buf); strfromf128 (buf, 128, "%.34a", g); printf ("%s\n", buf); } also prints 0x1.1c46bd57277993a2ee60193c957b000000p+114 0x1.1c46bd57277993a2ee60193c957b000000p+114 M_PI_2q or M_PI_2f128 is 1.5707963267948966192313216916397513987... while pi/2 with larger precision is I think 1.5707963267948966192313216916397514420... so M_PI_2{q,f128} is rounded down, not up, so no wonder tanq/tanf128 is not inf.