This is the mail archive of the gcc-bugs@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]

[Bug fortran/44442] Useless temporary with RESHAPE



------- 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


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