Hi Julian, On 12 November 2010 17:49, Julian Brown <jul...@codesourcery.com> wrote:
> > For the first of these, I think we can get away with changing the > vectorizer to use explicit "array" loads and stores (i.e. vldN/vstN), so > that vector registers will hold elements in memory order -- so, all the > contortions in the attached patch will be unnecessary. ABI issues are > irrelevant, since vectors are "invisible" at the source code layer > generally, including at ABI boundaries. > > ... > The important observation is that vectors from case 1 and from cases 2/3 > never interact: it's quite safe for them to use different element > orderings, without extensive changes to GCC infrastructure (i.e., > multiple internal representations). I don't think I quite realised this > previously. > Do you think now that the changes in GIMPLE and RTL (a function attached to each vector) are unnecessary? >From the vectorizer point of view, target hooks look like the easiest solution (yet ugly). I am trying to think about something else, but nothing really makes sense. > > So, anyway, back to the patch in question. The choices are, I think: > > 1. Apply as-is (after I've ironed out the wrinkles), and then remove > the "ugly" bits at a later point when vectorizer "array load/store" > support is implemented. > > 2. Apply a version which simply disables all the troublesome > patterns until the same support appears. > I slightly prefer the first one, it's kind of an incremental solution. Ira > > Apologies if I'm retreading old ground ;-). > > (The CANNOT_CHANGE_MODE_CLASS fragment is necessary to generate good > code for the quad-word vec_pack_trunc_<mode> pattern. It would > eventually be applied as a separate patch.) > > Thoughts? > > Julian > > ChangeLog > > gcc/ > * config/arm/arm.h (CANNOT_CHANGE_MODE_CLASS): Allow changing mode > of vector registers. > * config/arm/neon.md (vec_shr_<mode>, vec_shl_<mode>): Disable in > big-endian mode. > (reduc_splus_<mode>, reduc_smin_<mode>, reduc_smax_<mode>) > (reduc_umin_<mode>, reduc_umax_<mode>) > (neon_vec_unpack<US>_lo_<mode>, neon_vec_unpack<US>_hi_<mode>) > (neon_vec_<US>mult_lo_<mode>, neon_vec_<US>mult_hi_<mode>) > (vec_pack_trunc_<mode>, neon_vec_pack_trunc_<mode>): Handle > big-endian mode for quad-word vectors. >
_______________________________________________ linaro-toolchain mailing list linaro-toolchain@lists.linaro.org http://lists.linaro.org/mailman/listinfo/linaro-toolchain