< prev index next > src/jdk.incubator.vector/share/classes/jdk/incubator/vector/FloatMaxVector.java
Print this page
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package jdk.incubator.vector;
- import java.nio.ByteBuffer;
import java.util.Arrays;
import java.util.Objects;
import java.util.function.IntUnaryOperator;
+ import jdk.incubator.foreign.MemorySegment;
import jdk.internal.vm.annotation.ForceInline;
import jdk.internal.vm.vector.VectorSupport;
import static jdk.internal.vm.vector.VectorSupport.*;
super.rearrangeTemplate(FloatMaxShuffle.class,
(FloatMaxShuffle) s,
(FloatMaxVector) v); // specialize
}
+ @Override
+ @ForceInline
+ public FloatMaxVector compress(VectorMask<Float> m) {
+ return (FloatMaxVector)
+ super.compressTemplate(FloatMaxMask.class,
+ (FloatMaxMask) m); // specialize
+ }
+
+ @Override
+ @ForceInline
+ public FloatMaxVector expand(VectorMask<Float> m) {
+ return (FloatMaxVector)
+ super.expandTemplate(FloatMaxMask.class,
+ (FloatMaxMask) m); // specialize
+ }
+
@Override
@ForceInline
public FloatMaxVector selectFrom(Vector<Float> v) {
return (FloatMaxVector)
super.selectFromTemplate((FloatMaxVector) v); // specialize
@ForceInline
public FloatMaxMask not() {
return xor(maskAll(true));
}
+ @Override
+ @ForceInline
+ public FloatMaxMask compress() {
+ return (FloatMaxMask)VectorSupport.comExpOp(VectorSupport.VECTOR_OP_MASK_COMPRESS,
+ FloatMaxVector.class, FloatMaxMask.class, ETYPE, VLENGTH, null, this,
+ (v1, m1) -> VSPECIES.iota().compare(VectorOperators.LT, m1.trueCount()));
+ }
+
+
// Binary operations
@Override
@ForceInline
public FloatMaxMask and(VectorMask<Float> mask) {
@ForceInline
@Override
final
- FloatVector fromByteArray0(byte[] a, int offset) {
- return super.fromByteArray0Template(a, offset); // specialize
+ FloatVector fromMemorySegment0(MemorySegment ms, long offset) {
+ return super.fromMemorySegment0Template(ms, offset); // specialize
}
@ForceInline
@Override
final
- FloatVector fromByteArray0(byte[] a, int offset, VectorMask<Float> m) {
- return super.fromByteArray0Template(FloatMaxMask.class, a, offset, (FloatMaxMask) m); // specialize
- }
-
- @ForceInline
- @Override
- final
- FloatVector fromByteBuffer0(ByteBuffer bb, int offset) {
- return super.fromByteBuffer0Template(bb, offset); // specialize
- }
-
- @ForceInline
- @Override
- final
- FloatVector fromByteBuffer0(ByteBuffer bb, int offset, VectorMask<Float> m) {
- return super.fromByteBuffer0Template(FloatMaxMask.class, bb, offset, (FloatMaxMask) m); // specialize
+ FloatVector fromMemorySegment0(MemorySegment ms, long offset, VectorMask<Float> m) {
+ return super.fromMemorySegment0Template(FloatMaxMask.class, ms, offset, (FloatMaxMask) m); // specialize
}
@ForceInline
@Override
final
@ForceInline
@Override
final
- void intoByteArray0(byte[] a, int offset) {
- super.intoByteArray0Template(a, offset); // specialize
- }
-
- @ForceInline
- @Override
- final
- void intoByteArray0(byte[] a, int offset, VectorMask<Float> m) {
- super.intoByteArray0Template(FloatMaxMask.class, a, offset, (FloatMaxMask) m); // specialize
- }
-
- @ForceInline
- @Override
- final
- void intoByteBuffer0(ByteBuffer bb, int offset, VectorMask<Float> m) {
- super.intoByteBuffer0Template(FloatMaxMask.class, bb, offset, (FloatMaxMask) m);
+ void intoMemorySegment0(MemorySegment ms, long offset, VectorMask<Float> m) {
+ super.intoMemorySegment0Template(FloatMaxMask.class, ms, offset, (FloatMaxMask) m);
}
// End of specialized low-level memory operations.
< prev index next >