diff options
author | Mikael Morin <mikael@gcc.gnu.org> | 2010-09-21 19:04:09 +0000 |
---|---|---|
committer | Mikael Morin <mikael@gcc.gnu.org> | 2010-09-21 19:04:09 +0000 |
commit | 0b4f2770ff14ee139b9f5d0aa16c1507eb60cb55 (patch) | |
tree | aa4f4a282ac80b91b29b28096d4af2a6ad0d5e3f /gcc/fortran/trans.h | |
parent | 5e68c77aff8d9c984668f8932e54b28d02456bba (diff) | |
download | gcc-0b4f2770ff14ee139b9f5d0aa16c1507eb60cb55.zip gcc-0b4f2770ff14ee139b9f5d0aa16c1507eb60cb55.tar.gz gcc-0b4f2770ff14ee139b9f5d0aa16c1507eb60cb55.tar.bz2 |
re PR fortran/45648 (Unnecessary temporary for transpose calls as actual argument.)
2010-09-21 Mikael Morin <mikael@gcc.gnu.org>
PR fortran/45648
* trans-array.c (gfc_conv_expr_descriptor): Calculate dim out of n and
info->dim.
PR fortran/45648
* trans-array.c (gfc_conv_expr_descriptor): Unset full if we are
accessing dimensions in reversed order.
PR fortran/45648
* trans-array.c (gfc_conv_expr_descriptor): Special case noncopying
intrinsic function call.
* trans-array.c (gfc_conv_expr_descriptor): Remove ss lookup.
Update asserts accordingly.
PR fortran/45648
* trans.h (gfc_se): New field force_tmp.
* trans-expr.c (gfc_conv_procedure_call): Check for argument alias
and set parmse.force_tmp if some alias is found.
* trans-array.c (gfc_conv_expr_descriptor): Force a temporary creation
if se->force_tmp is set.
2010-09-21 Mikael Morin <mikael@gcc.gnu.org>
PR fortran/45648
* gfortran.dg/inline_transpose_1.f90: Update temporary's locations
and counts. Add non-elemental function call check.
PR fortran/45648
* gfortran.dg/inline_transpose_1.f90: Add function calls with aliasing
arguments checks. Update temporary counts.
* gfortran.dg/transpose_optimization_1.f90: New.
From-SVN: r164494
Diffstat (limited to 'gcc/fortran/trans.h')
-rw-r--r-- | gcc/fortran/trans.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/fortran/trans.h b/gcc/fortran/trans.h index acdd3e3..a883cf5 100644 --- a/gcc/fortran/trans.h +++ b/gcc/fortran/trans.h @@ -81,6 +81,11 @@ typedef struct gfc_se /* If set, gfc_conv_procedure_call does not put byref calls into se->pre. */ unsigned no_function_call:1; + /* If set, we will force the creation of a temporary. Useful to disable + non-copying procedure argument passing optimizations, when some function + args alias. */ + unsigned force_tmp:1; + /* Scalarization parameters. */ struct gfc_se *parent; struct gfc_ss *ss; |