This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran 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: Translation of multidimensional arrays


Zdenek,

gfortran currently flattens accesses to multidimensional arrays, i.e., a(i,j,k)
becomes a[offset + i * stride[0] + j * stride[1] + k * stride[2]]. This
leads to efficient low-level code, however, it also makes some
optimizations more difficult (for example, we lose some information for
dependency analysis). I would like to change this (to get the above
translated to a[i][j][k]).


gfortran already does a lot of dependency analysis in the frontend. What extra analysis will we get?

So I think doing this transition should be fairly straightforward,
although of course time consuming. I would like to know whether someone
is not already working on something similar, so that I do not waste my
time in such a case. Also, I would like to hear if there are some
objections to this idea.


I do not have an objection but have heard nothing yet to convince me that this will gain us anything. Could you elaborate, please?

Best regards

Paul Thomas



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