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]

Re: [tree-ssa-lno] vectorizer patch.


On Fri, Jan 02, 2004 at 05:00:30PM -0500, David Edelsohn wrote:
> 	How should the vectorizer determine what types used in loops are
> profitable to vectorize?  How should it determine which target-dependent
> vector instructions and stride to use?

That's not what the hook does.  All the hook does is take a scalar type
and return a vector type of width UNITS_PER_SIMD_WORD.  This can be done
with no target hook at all.

As for the determination, I believe that iterating over all vector modes
and testing each against VECTOR_MODE_SUPPORTED_P would be a good start.
You'd want to start at the widest mode and iterate down, so that you find
V4SI before V2SI if both are supported.


r~


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