This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, Fortan] fix initialization of flag_errno_math and flag_associative_math


Hi Joost,

Why do you want -fno-math-errno to be the default for gfortran?
AFAICT such default is not documented and the flag works
(checked on your test gfortran.dg/errnocheck_1.f90).

For -fassociative-math, the manual says

For Fortran the option is automatically enabled when both -fno-signed-zeros and -fno-trapping-math are in effect.

and again AFAICT this is not working (checked on your test
gfortran.dg/associative_1.f90) while I see

  /* Fortran allows associative math - but we cannot reassociate if
     we want traps or signed zeros. Cf. also flag_protect_parens.  */
  if (flag_associative_math == -1)
    flag_associative_math = (!flag_trapping_math && !flag_signed_zeros);

in gcc/fortran/options.c. Why this is not working is beyond my understanding,
but I am not sure that your fix is the right one.

Cheers,

Dominique


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]