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

[Patch, fortran] Use initial array dimensions in the scalarizer


Hello,

The scalarizer in its current state uses the dimen first fields of gfc_ss_info's start, stride, etc arrays, where dimen is the dimension of the scalarized expression.
In order to handle reduced expressions (sum, product, etc), the scalarizer will have to work at two levels: the full level, where all the dimensions of the initial array are present, and the reduced level
with only the dimensions left after reduction.
To achieve this without inserting/removing/carrying around bounds and the associated bookkeeping, we need sparse bounds arrays accessed through the final (full) array dimension.


As gfc_ss_info already holds a dim array holding the final array dimension, there is little work to do. We just need to make sure that we index the bound arrays by that dimension.

That's what the attached patch does.
The parts it changes are to be changed again as the data structure have
to be reorganized, but it makes those changes more systematic.

Regression tested on x86_64-unknown-freebsd8.0. OK for trunk ?

Mikael

Attachment: scalarizer_dimension.log
Description: Text document

Attachment: scalarizer_dimension.diff
Description: Text document


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