[PATCH] D26546: [PPC] Add vec_insert4b/vec_extract4b to altivec.h

Nemanja Ivanovic via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 7 02:37:01 PST 2016


nemanjai requested changes to this revision.
nemanjai added a comment.
This revision now requires changes to proceed.

The finalized wording for vec_insert4b:
Let W be the first doubleword element of ARG1, truncated to 32 bits.  The result vector is formed by inserting W into ARG2 at the byte position (0-12) specified by ARG3.

Given that wording, this implementation has almost the correct semantics. The only change required is that the source and target vectors need to be switched. Namely, a word is taken out of the first argument and inserted into the second argument. And it appears that the current implementation has that backwards.


Repository:
  rL LLVM

https://reviews.llvm.org/D26546





More information about the cfe-commits mailing list