< prev index next >

src/jdk.incubator.vector/share/classes/jdk/incubator/vector/Vector.java

Print this page




 542      * @return the mask result of testing if this vector is greater than or
 543      * equal to the given vector
 544      */
 545     public abstract VectorMask<E> greaterThanEq(Vector<E> v);
 546 
 547     // Elemental shifting
 548 
 549     /**
 550      * Rotates left the lane elements of this vector by the given number of
 551      * lanes, {@code i}, modulus the vector length.
 552      * <p>
 553      * This is a cross-lane operation that permutes the lane elements of this
 554      * vector.
 555      * For each lane of the input vector, at lane index {@code N}, the lane
 556      * element is placed into the result vector at lane index
 557      * {@code (N + i) % length()}.
 558      *
 559      * @param i the number of lanes to rotate left
 560      * @return the result of rotating left lane elements of this vector by the
 561      * given number of lanes

 562      */
 563     public abstract Vector<E> rotateLanesLeft(int i);
 564 
 565     /**
 566      * Rotates right the lane elements of this vector by the given number of
 567      * lanes, {@code i}, modulus the vector length.
 568      * <p>
 569      * This is a cross-lane operation that permutes the lane elements of this
 570      * vector.
 571      * For each lane of the input vector, at lane index {@code N}, the lane
 572      * element is placed into the result vector at lane index
 573      * {@code (N + length() - (i % length())) % length()}
 574      *
 575      * @param i the number of lanes to rotate right
 576      * @return the result of rotating right lane elements of this vector by the
 577      * given number of lanes

 578      */
 579     public abstract Vector<E> rotateLanesRight(int i);
 580 
 581     /**
 582      * Shift left the lane elements of this vector by the given number of
 583      * lanes, {@code i}, modulus the vector length.
 584      * <p>
 585      * This is a cross-lane operation that permutes the lane elements of this
 586      * vector and behaves as if rotating left the lane elements by {@code i},
 587      * and then the zero value is placed into the result vector at lane indexes
 588      * less than {@code i % length()}.
 589      *
 590      * @param i the number of lanes to shift left
 591      * @return the result of shifting left lane elements of this vector by the
 592      * given number of lanes
 593      * @throws IllegalArgumentException if {@code i} is {@code < 0}.
 594      */
 595     public abstract Vector<E> shiftLanesLeft(int i);
 596 
 597     /**


1069     /**
1070      * Returns a shuffle of same species as {@code this} vector and where each lane element is the value of its
1071      * corresponding lane index.
1072      * <p>
1073      * This method behaves as if it returns the result of calling the static {@link VectorShuffle#shuffleIota(VectorSpecies) shuffleIota()}
1074      * method in VectorShuffle as follows:
1075      * <pre> {@code
1076      *     return VectorShuffle.shuffleIota(this.species());
1077      * } </pre>
1078      *
1079      * @return a shuffle of lane indexes
1080      * @see AbstractShuffle#shuffleIota(VectorSpecies)
1081      */
1082     @ForceInline
1083     public final VectorShuffle<E> shuffleIota() {
1084         return VectorShuffle.shuffleIota(this.species());
1085     }
1086 
1087     /**
1088      * Returns a shuffle of same species as {@code this} vector and with lane elements set to sequential {@code int}
1089      * values starting from {@code start}.
1090      * <p>
1091      * This method behaves as if it returns the result of calling the static {@link VectorShuffle#shuffleIota(VectorSpecies, int) shuffleIota()}
1092      * method in VectorShuffle as follows:
1093      * <pre> {@code
1094      *     return VectorShuffle.shuffleIota(this.species(), start);
1095      * } </pre>
1096      *
1097      * @param start starting value of sequence
1098      * @return a shuffle of lane indexes
1099      * @see AbstractShuffle#shuffleIota(VectorSpecies, int)
1100      */
1101     @ForceInline
1102     public final VectorShuffle<E> shuffleIota(int start) {
1103         return VectorShuffle.shuffleIota(this.species(), start);
1104     }
1105 
1106     /**
1107      * Returns a shuffle of same species as {@code this} vector and with lane elements set to sequential {@code int}
1108      * values starting from {@code start} and looping around species length.
1109      * <p>


 542      * @return the mask result of testing if this vector is greater than or
 543      * equal to the given vector
 544      */
 545     public abstract VectorMask<E> greaterThanEq(Vector<E> v);
 546 
 547     // Elemental shifting
 548 
 549     /**
 550      * Rotates left the lane elements of this vector by the given number of
 551      * lanes, {@code i}, modulus the vector length.
 552      * <p>
 553      * This is a cross-lane operation that permutes the lane elements of this
 554      * vector.
 555      * For each lane of the input vector, at lane index {@code N}, the lane
 556      * element is placed into the result vector at lane index
 557      * {@code (N + i) % length()}.
 558      *
 559      * @param i the number of lanes to rotate left
 560      * @return the result of rotating left lane elements of this vector by the
 561      * given number of lanes
 562      * @throws IllegalArgumentException if {@code i} is {@code < 0}.
 563      */
 564     public abstract Vector<E> rotateLanesLeft(int i);
 565 
 566     /**
 567      * Rotates right the lane elements of this vector by the given number of
 568      * lanes, {@code i}, modulus the vector length.
 569      * <p>
 570      * This is a cross-lane operation that permutes the lane elements of this
 571      * vector.
 572      * For each lane of the input vector, at lane index {@code N}, the lane
 573      * element is placed into the result vector at lane index
 574      * {@code (N + length() - (i % length())) % length()}
 575      *
 576      * @param i the number of lanes to rotate right
 577      * @return the result of rotating right lane elements of this vector by the
 578      * given number of lanes
 579      * @throws IllegalArgumentException if {@code i} is {@code < 0}.
 580      */
 581     public abstract Vector<E> rotateLanesRight(int i);
 582 
 583     /**
 584      * Shift left the lane elements of this vector by the given number of
 585      * lanes, {@code i}, modulus the vector length.
 586      * <p>
 587      * This is a cross-lane operation that permutes the lane elements of this
 588      * vector and behaves as if rotating left the lane elements by {@code i},
 589      * and then the zero value is placed into the result vector at lane indexes
 590      * less than {@code i % length()}.
 591      *
 592      * @param i the number of lanes to shift left
 593      * @return the result of shifting left lane elements of this vector by the
 594      * given number of lanes
 595      * @throws IllegalArgumentException if {@code i} is {@code < 0}.
 596      */
 597     public abstract Vector<E> shiftLanesLeft(int i);
 598 
 599     /**


1071     /**
1072      * Returns a shuffle of same species as {@code this} vector and where each lane element is the value of its
1073      * corresponding lane index.
1074      * <p>
1075      * This method behaves as if it returns the result of calling the static {@link VectorShuffle#shuffleIota(VectorSpecies) shuffleIota()}
1076      * method in VectorShuffle as follows:
1077      * <pre> {@code
1078      *     return VectorShuffle.shuffleIota(this.species());
1079      * } </pre>
1080      *
1081      * @return a shuffle of lane indexes
1082      * @see AbstractShuffle#shuffleIota(VectorSpecies)
1083      */
1084     @ForceInline
1085     public final VectorShuffle<E> shuffleIota() {
1086         return VectorShuffle.shuffleIota(this.species());
1087     }
1088 
1089     /**
1090      * Returns a shuffle of same species as {@code this} vector and with lane elements set to sequential {@code int}
1091      * values starting from {@code start} and looping around species length.
1092      * <p>
1093      * This method behaves as if it returns the result of calling the static {@link VectorShuffle#shuffleIota(VectorSpecies, int) shuffleIota()}
1094      * method in VectorShuffle as follows:
1095      * <pre> {@code
1096      *     return VectorShuffle.shuffleIota(this.species(), start);
1097      * } </pre>
1098      *
1099      * @param start starting value of sequence
1100      * @return a shuffle of lane indexes
1101      * @see AbstractShuffle#shuffleIota(VectorSpecies, int)
1102      */
1103     @ForceInline
1104     public final VectorShuffle<E> shuffleIota(int start) {
1105         return VectorShuffle.shuffleIota(this.species(), start);
1106     }
1107 
1108     /**
1109      * Returns a shuffle of same species as {@code this} vector and with lane elements set to sequential {@code int}
1110      * values starting from {@code start} and looping around species length.
1111      * <p>
< prev index next >