>  gcc keeps advancing autovectorization.  Is manual vectorization worth the
>  trouble?

Well, the way that the ufuncs are written at the moment,
-ftree-vectorize will never kick in due to the non-constant strides.
To get this to work, one has to special case out unary strides. Even
with constant strides -ftree-vectorize often produces sub-optimal code
as it has to make very conservative assumptions about the content of
variables (it can do better if -fstrict-aliasing is used, but I think
numpy is not compiled with this flag). So in other words, yes, I think
it is worth hand vectorizing (and unrolling) the most common cases.

James
_______________________________________________
Numpy-discussion mailing list
Numpy-discussion@scipy.org
http://projects.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to