RFC: PR14880 vec_duplicate or vec_select?

David Edelsohn dje@watson.ibm.com
Sat Nov 6 08:42:00 GMT 2004


	The change is not for the auto-vectorizer, it is for GCC's common
vector operation support.  GCC cannot assume much about UNSPEC, but can
know about vec_merge, vec_select, vec_concat, vec_duplicate.  It is best
to use the standard patterns when available.

	The Altivec vspltM (vec_splat) instruction sets each element of
the result to the specified element of the input vector.  One could
describe it as selecting the same source vector sub part into each element
of the result (vec_select) or duplicating the 1-element sub-vector into
all elements (vec_duplicate).  I am not sure how this should be
canonicalized in GCC or if there already is a preferred form.

David



More information about the Gcc mailing list