* This is a lane-wise binary operation which applies the primitive logical left shift * operation ({@code <<}) to each lane to left shift the - * element by shift value as specified by the input scalar. Only the 4 - * lowest-order bits of shift value are used. It is as if the shift value + * element by shift value as specified by the input scalar. + * Only the 4 lowest-order bits of shift value are used. It is as if the shift value * were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF. * The shift distance actually used is therefore always in the range 0 to 15, inclusive. * @@ -986,7 +986,7 @@ * @return the result of logically left shifting left this vector by the * broadcast of an input scalar */ - public abstract ShortVector shiftL(int s); + public abstract ShortVector shiftLeft(int s); /** * Logically left shifts this vector by the broadcast of an input scalar, @@ -994,8 +994,8 @@ *

* This is a lane-wise binary operation which applies the primitive logical left shift
* operation ({@code <<}) to each lane to left shift the
- * element by shift value as specified by the input scalar. Only the 4
- * lowest-order bits of shift value are used. It is as if the shift value
+ * element by shift value as specified by the input scalar.
+ * Only the 4 lowest-order bits of shift value are used. It is as if the shift value
* were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF.
* The shift distance actually used is therefore always in the range 0 to 15, inclusive.
*
@@ -1004,8 +1004,43 @@
* @return the result of logically left shifting left this vector by the
* broadcast of an input scalar
*/
- public abstract ShortVector shiftL(int s, VectorMask

+ * This is a lane-wise binary operation which applies the primitive logical left shift
+ * operation ({@code <<}) to each lane. For each lane of this vector, the
+ * shift value is the corresponding lane of input vector.
+ * Only the 4 lowest-order bits of shift value are used. It is as if the shift value
+ * were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF.
+ * The shift distance actually used is therefore always in the range 0 to 15, inclusive.
+ *
+ * @param v the input vector
+ * @return the result of logically left shifting this vector by the input
+ * vector
+ */
+ public abstract ShortVector shiftLeft(Vector

+ * This is a lane-wise binary operation which applies the primitive logical left shift
+ * operation ({@code <<}) to each lane. For each lane of this vector, the
+ * shift value is the corresponding lane of input vector.
+ * Only the 4 lowest-order bits of shift value are used. It is as if the shift value
+ * were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF.
+ * The shift distance actually used is therefore always in the range 0 to 15, inclusive.
+ *
+ * @param v the input vector
+ * @param m the mask controlling lane selection
+ * @return the result of logically left shifting this vector by the input
+ * vector
+ */
+ public ShortVector shiftLeft(Vector

* This is a lane-wise binary operation which applies the primitive logical right shift * operation ({@code >>>}) to each lane to logically right shift the - * element by shift value as specified by the input scalar. Only the 4 - * lowest-order bits of shift value are used. It is as if the shift value + * element by shift value as specified by the input scalar. + * Only the 4 lowest-order bits of shift value are used. It is as if the shift value * were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF. * The shift distance actually used is therefore always in the range 0 to 15, inclusive. * @@ -1024,7 +1059,7 @@ * @return the result of logically right shifting this vector by the * broadcast of an input scalar */ - public abstract ShortVector shiftR(int s); + public abstract ShortVector shiftRight(int s); /** * Logically right shifts (or unsigned right shifts) this vector by the @@ -1032,9 +1067,9 @@ * mask. *

* This is a lane-wise binary operation which applies the primitive logical right shift
- * operation ({@code >>>}) to each lane to logically right shift the
- * element by shift value as specified by the input scalar. Only the 4
- * lowest-order bits of shift value are used. It is as if the shift value
+ * operation ({@code >>}) to each lane to logically right shift the
+ * element by shift value as specified by the input scalar.
+ * Only the 4 lowest-order bits of shift value are used. It is as if the shift value
* were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF.
* The shift distance actually used is therefore always in the range 0 to 15, inclusive.
*
@@ -1043,8 +1078,44 @@
* @return the result of logically right shifting this vector by the
* broadcast of an input scalar
*/
- public abstract ShortVector shiftR(int s, VectorMask

+ * This is a lane-wise binary operation which applies the primitive logical right shift
+ * operation ({@code >>>}) to each lane. For each lane of this vector, the
+ * shift value is the corresponding lane of input vector.
+ * Only the 4 lowest-order bits of shift value are used. It is as if the shift value
+ * were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF.
+ * The shift distance actually used is therefore always in the range 0 to 15, inclusive.
+ *
+ * @param v the input vector
+ * @return the result of logically right shifting this vector by the
+ * input vector
+ */
+ public abstract ShortVector shiftRight(Vector

+ * This is a lane-wise binary operation which applies the primitive logical right shift
+ * operation ({@code >>>}) to each lane. For each lane of this vector, the
+ * shift value is the corresponding lane of input vector.
+ * Only the 4 lowest-order bits of shift value are used. It is as if the shift value
+ * were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF.
+ * The shift distance actually used is therefore always in the range 0 to 15, inclusive.
+ *
+ * @param v the input vector
+ * @param m the mask controlling lane selection
+ * @return the result of logically right shifting this vector by the
+ * input vector
+ */
+ public ShortVector shiftRight(Vector

+ * This is a lane-wise binary operation which applies the primitive arithmetic right
+ * shift operation ({@code >>}) to each lane. For each lane of this vector, the
+ * shift value is the corresponding lane of input vector.
+ * Only the 4 lowest-order bits of shift value are used. It is as if the shift
+ * value were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF.
+ * The shift distance actually used is therefore always in the range 0 to 15, inclusive.
+ *
+ * @param v the input vector
+ * @return the result of arithmetically right shifting this vector by the
+ * input vector
+ */
+ public abstract ShortVector shiftArithmeticRight(Vector

+ * This is a lane-wise binary operation which applies the primitive arithmetic right
+ * shift operation ({@code >>}) to each lane. For each lane of this vector, the
+ * shift value is the corresponding lane of input vector.
+ * Only the 4 lowest-order bits of shift value are used. It is as if the shift
+ * value were subjected to a bitwise logical AND operator ({@code &}) with the mask value 0xF.
+ * The shift distance actually used is therefore always in the range 0 to 15, inclusive.
+ *
+ * @param v the input vector
+ * @param m the mask controlling lane selection
+ * @return the result of arithmetically right shifting this vector by the
+ * input vector
+ */
+ public ShortVector shiftArithmeticRight(Vector

+ * This is a lane-wise binary operation which produces the result of rotating left the two's + * complement binary representation of each lane of first operand (this vector) by input scalar. + * Rotation by any multiple of 16 is a no-op, so only the 4 lowest-order bits of input value are used. + * It is as if the input value were subjected to a bitwise logical + * AND operator ({@code &}) with the mask value 0x15. + * + * @param s the input scalar; the number of the bits to rotate left + * @return the result of rotating left this vector by the broadcast of an + * input scalar + */ + @ForceInline + public final ShortVector rotateLeft(int s) { + return shiftLeft(s).or(shiftRight(-s)); + } + + /** + * Rotates left this vector by the broadcast of an input scalar, selecting + * lane elements controlled by a mask. + *

+ * This is a lane-wise binary operation which produces the result of rotating left the two's
+ * complement binary representation of each lane of first operand (this vector) by input scalar.
+ * Rotation by any multiple of 16 is a no-op, so only the 4 lowest-order bits of input value are used.
+ * It is as if the input value were subjected to a bitwise logical
+ * AND operator ({@code &}) with the mask value 0x15.
+ *
+ * @param s the input scalar; the number of the bits to rotate left
+ * @param m the mask controlling lane selection
+ * @return the result of rotating left this vector by the broadcast of an
+ * input scalar
+ */
+ @ForceInline
+ public final ShortVector rotateLeft(int s, VectorMask

+ * This is a lane-wise binary operation which produces the result of rotating right the two's + * complement binary representation of each lane of first operand (this vector) by input scalar. + * Rotation by any multiple of 16 is a no-op, so only the 4 lowest-order bits of input value are used. + * It is as if the input value were subjected to a bitwise logical + * AND operator ({@code &}) with the mask value 0x15. + * + * @param s the input scalar; the number of the bits to rotate right + * @return the result of rotating right this vector by the broadcast of an + * input scalar + */ + @ForceInline + public final ShortVector rotateRight(int s) { + return shiftRight(s).or(shiftLeft(-s)); + } + + /** + * Rotates right this vector by the broadcast of an input scalar, selecting + * lane elements controlled by a mask. + *

+ * This is a lane-wise binary operation which produces the result of rotating right the two's
+ * complement binary representation of each lane of first operand (this vector) by input scalar.
+ * Rotation by any multiple of 16 is a no-op, so only the 4 lowest-order bits of input value are used.
+ * It is as if the input value were subjected to a bitwise logical
+ * AND operator ({@code &}) with the mask value 0x15.
+ *
+ * @param s the input scalar; the number of the bits to rotate right
+ * @param m the mask controlling lane selection
+ * @return the result of rotating right this vector by the broadcast of an
+ * input scalar
+ */
+ @ForceInline
+ public final ShortVector rotateRight(int s, VectorMask