This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/44442] Useless temporary with RESHAPE
- From: "dominiq at lps dot ens dot fr" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Jun 2010 20:57:52 -0000
- Subject: [Bug fortran/44442] Useless temporary with RESHAPE
- References: <bug-44442-12313@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #4 from dominiq at lps dot ens dot fr 2010-06-09 20:57 -------
(In reply to comment #2)
> This is a known limitation of array constructors handling by gfortran.
I was about to ask if this pr is a duplicate. From comment #3, it is; so I am
closing it as such.
For the record the optimized dump (with 4.6) reads:
...
atmp.6.dtype = 521;
atmp.6.dim[0].stride = 1;
atmp.6.dim[0].lbound = 0;
atmp.6.dim[0].ubound = 1;
atmp.6.data = &A.7;
atmp.6.offset = 0;
A.7[0] = 5;
A.7[1] = 4;
_gfortran_reshape_r4 (&parm.1, &parm.2, &atmp.6, 0B, 0B);
...
So one temporary is removed with optimization.
*** This bug has been marked as a duplicate of 33341 ***
--
dominiq at lps dot ens dot fr changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |DUPLICATE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44442