[Bug target/25477] New: __builtin_sqrtl/__builtin_printf does not work unless including math.h/stdio.h

pinskia at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Sun Dec 18 05:42:00 GMT 2005


The following program does not work if we don't include math.h and stdio.h.

long double f(long double a)
{
  return __builtin_sqrtl (a);
}

int main(void)
{
  __builtin_printf("%Lf %f\n", f(2.0) + 2, 200.0);
}

The fortran failure gfortran.dg/large_real_kind_2.F90 is the same issue.

Note __builtin_printf is wrong even when including stdio.h


-- 
           Summary: __builtin_sqrtl/__builtin_printf does not work unless
                    including math.h/stdio.h
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Keywords: wrong-code
          Severity: normal
          Priority: P3
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: pinskia at gcc dot gnu dot org
GCC target triplet: powerpc-darwin[789].


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25477



More information about the Gcc-bugs mailing list