From 72bd130e66f28490198385ff62481a719a0103c0 Mon Sep 17 00:00:00 2001 From: Tobias Burnus Date: Sun, 21 Feb 2010 14:06:07 +0100 Subject: re PR fortran/35259 (-fassociative-math not enabled by default; No option to associate with PAREN_EXPRs) 2010-02-21 Tobias Burnus PR fortran/35259 * doc/invoke.texi (-fassociative-math): Document that this option is automatically enabled for Fortran. 2010-02-21 Tobias Burnus PR fortran/35259 * gfortran.h (gfc_option_t): New flag -fprotect-parens. * lang.opt: Ditto. * option.c (gfc_init_options,gfc_handle_option): Ditto. * trans-expr.c (gfc_conv_expr_op): Use the flag. * invoke.texi: Document new -fno-protect-parens flag. 2010-02-21 Tobias Burnus PR fortran/35259 * gfortran.dg/reassoc_5.f90: New test. From-SVN: r156937 --- gcc/fortran/invoke.texi | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'gcc/fortran/invoke.texi') diff --git a/gcc/fortran/invoke.texi b/gcc/fortran/invoke.texi index 9fe75d1..efcf5ef 100644 --- a/gcc/fortran/invoke.texi +++ b/gcc/fortran/invoke.texi @@ -171,7 +171,8 @@ and warnings}. -fpack-derived -frepack-arrays -fshort-enums -fexternal-blas @gol -fblas-matmul-limit=@var{n} -frecursive -finit-local-zero @gol -finit-integer=@var{n} -finit-real=@var{} @gol --finit-logical=@var{} -finit-character=@var{n} -fno-align-commons} +-finit-logical=@var{} -finit-character=@var{n} @gol +-fno-align-commons -fno-protect-parens} @end table @menu @@ -1410,6 +1411,16 @@ consistent data types everywhere, this padding can cause trouble, and same form of this option should be used for all files that share a COMMON block. To avoid potential alignment issues in COMMON blocks, it is recommended to order objects from largests to smallest. + +@item -fno-protect-parens +@opindex @code{fno-protect-parens} +@cindex re-association of parenthesed expressions +By default the parentheses in expression are honored for all optimization +levels such that the compiler does not do any re-association. Using +@option{-fno-protect-parens} allows the compiler to reorder REAL and +COMPLEX expressions to produce faster code. Note that for the re-association +optimization @option{-fno-signed-zeros} and @option{-fno-trapping-math} +need to be in effect. @end table @xref{Code Gen Options,,Options for Code Generation Conventions, -- cgit v1.1