[Bug fortran/43040] [lto] gfortran.dg/gamma_5.f90: Wrong code for call to gamma w/ -flto
rguenth at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Fri Feb 12 11:07:00 GMT 2010
------- Comment #2 from rguenth at gcc dot gnu dot org 2010-02-12 11:07 -------
This is because the Fortran frontend has different DECL_FUNCTION_CODE for the
same builtins as the middle-end, so they get mixed up (in this case LGAMMA
and GAMMA).
This needs to be fixed.
I also see
/* We define these separately as the fortran versions have different
semantics (they return an integer type) */
gfc_define_builtin ("__builtin_roundl", mfunc_longdouble[0],
BUILT_IN_ROUNDL, "roundl", true);
...
ugh. You can't overload existing builtin names with different semantics.
The middle-end expects that of gcc/builtins.def. For the above case
there exists BUILT_IN_LROUNDL.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Component|middle-end |fortran
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2010-02-12 11:07:37
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43040
More information about the Gcc-bugs
mailing list