< prev index next >

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

Print this page

        

*** 161,171 **** throw new IllegalArgumentException("Vector length this species length differ"); return VectorIntrinsics.cast( Long128Vector.class, long.class, LENGTH, ! s.boxType(), s.elementType(), LENGTH, this, s, (species, vector) -> vector.castDefault(species) ); } --- 161,171 ---- throw new IllegalArgumentException("Vector length this species length differ"); return VectorIntrinsics.cast( Long128Vector.class, long.class, LENGTH, ! s.vectorType(), s.elementType(), LENGTH, this, s, (species, vector) -> vector.castDefault(species) ); }
*** 299,346 **** @Override @ForceInline public LongVector reshape(VectorSpecies<Long> s) { Objects.requireNonNull(s); ! if (s.bitSize() == 64 && (s.boxType() == Long64Vector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, Long64Vector.class, long.class, Long64Vector.LENGTH, this, s, (species, vector) -> (LongVector) vector.defaultReinterpret(species) ); ! } else if (s.bitSize() == 128 && (s.boxType() == Long128Vector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, Long128Vector.class, long.class, Long128Vector.LENGTH, this, s, (species, vector) -> (LongVector) vector.defaultReinterpret(species) ); ! } else if (s.bitSize() == 256 && (s.boxType() == Long256Vector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, Long256Vector.class, long.class, Long256Vector.LENGTH, this, s, (species, vector) -> (LongVector) vector.defaultReinterpret(species) ); ! } else if (s.bitSize() == 512 && (s.boxType() == Long512Vector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, Long512Vector.class, long.class, Long512Vector.LENGTH, this, s, (species, vector) -> (LongVector) vector.defaultReinterpret(species) ); } else if ((s.bitSize() > 0) && (s.bitSize() <= 2048) ! && (s.bitSize() % 128 == 0) && (s.boxType() == LongMaxVector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, LongMaxVector.class, long.class, LongMaxVector.LENGTH, --- 299,346 ---- @Override @ForceInline public LongVector reshape(VectorSpecies<Long> s) { Objects.requireNonNull(s); ! if (s.bitSize() == 64 && (s.vectorType() == Long64Vector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, Long64Vector.class, long.class, Long64Vector.LENGTH, this, s, (species, vector) -> (LongVector) vector.defaultReinterpret(species) ); ! } else if (s.bitSize() == 128 && (s.vectorType() == Long128Vector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, Long128Vector.class, long.class, Long128Vector.LENGTH, this, s, (species, vector) -> (LongVector) vector.defaultReinterpret(species) ); ! } else if (s.bitSize() == 256 && (s.vectorType() == Long256Vector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, Long256Vector.class, long.class, Long256Vector.LENGTH, this, s, (species, vector) -> (LongVector) vector.defaultReinterpret(species) ); ! } else if (s.bitSize() == 512 && (s.vectorType() == Long512Vector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, Long512Vector.class, long.class, Long512Vector.LENGTH, this, s, (species, vector) -> (LongVector) vector.defaultReinterpret(species) ); } else if ((s.bitSize() > 0) && (s.bitSize() <= 2048) ! && (s.bitSize() % 128 == 0) && (s.vectorType() == LongMaxVector.class)) { return VectorIntrinsics.reinterpret( Long128Vector.class, long.class, LENGTH, LongMaxVector.class, long.class, LongMaxVector.LENGTH,
*** 663,718 **** return blend(xor(v), m); } @Override @ForceInline ! public Long128Vector shiftL(int s) { return VectorIntrinsics.broadcastInt( VECTOR_OP_LSHIFT, Long128Vector.class, long.class, LENGTH, this, s, (v, i) -> v.uOp((__, a) -> (long) (a << i))); } @Override @ForceInline ! public Long128Vector shiftL(int s, VectorMask<Long> m) { ! return blend(shiftL(s), m); } @Override @ForceInline ! public Long128Vector shiftR(int s) { return VectorIntrinsics.broadcastInt( VECTOR_OP_URSHIFT, Long128Vector.class, long.class, LENGTH, this, s, (v, i) -> v.uOp((__, a) -> (long) (a >>> i))); } @Override @ForceInline ! public Long128Vector shiftR(int s, VectorMask<Long> m) { ! return blend(shiftR(s), m); } @Override @ForceInline ! public Long128Vector aShiftR(int s) { return VectorIntrinsics.broadcastInt( VECTOR_OP_RSHIFT, Long128Vector.class, long.class, LENGTH, this, s, (v, i) -> v.uOp((__, a) -> (long) (a >> i))); } @Override @ForceInline ! public Long128Vector aShiftR(int s, VectorMask<Long> m) { ! return blend(aShiftR(s), m); } @Override @ForceInline ! public Long128Vector shiftL(Vector<Long> s) { Long128Vector shiftv = (Long128Vector)s; // As per shift specification for Java, mask the shift count. shiftv = shiftv.and(LongVector.broadcast(SPECIES, 0x3f)); return VectorIntrinsics.binaryOp( VECTOR_OP_LSHIFT, Long128Vector.class, long.class, LENGTH, --- 663,718 ---- return blend(xor(v), m); } @Override @ForceInline ! public Long128Vector shiftLeft(int s) { return VectorIntrinsics.broadcastInt( VECTOR_OP_LSHIFT, Long128Vector.class, long.class, LENGTH, this, s, (v, i) -> v.uOp((__, a) -> (long) (a << i))); } @Override @ForceInline ! public Long128Vector shiftLeft(int s, VectorMask<Long> m) { ! return blend(shiftLeft(s), m); } @Override @ForceInline ! public Long128Vector shiftRight(int s) { return VectorIntrinsics.broadcastInt( VECTOR_OP_URSHIFT, Long128Vector.class, long.class, LENGTH, this, s, (v, i) -> v.uOp((__, a) -> (long) (a >>> i))); } @Override @ForceInline ! public Long128Vector shiftRight(int s, VectorMask<Long> m) { ! return blend(shiftRight(s), m); } @Override @ForceInline ! public Long128Vector shiftArithmeticRight(int s) { return VectorIntrinsics.broadcastInt( VECTOR_OP_RSHIFT, Long128Vector.class, long.class, LENGTH, this, s, (v, i) -> v.uOp((__, a) -> (long) (a >> i))); } @Override @ForceInline ! public Long128Vector shiftArithmeticRight(int s, VectorMask<Long> m) { ! return blend(shiftArithmeticRight(s), m); } @Override @ForceInline ! public Long128Vector shiftLeft(Vector<Long> s) { Long128Vector shiftv = (Long128Vector)s; // As per shift specification for Java, mask the shift count. shiftv = shiftv.and(LongVector.broadcast(SPECIES, 0x3f)); return VectorIntrinsics.binaryOp( VECTOR_OP_LSHIFT, Long128Vector.class, long.class, LENGTH,
*** 720,730 **** (v1, v2) -> v1.bOp(v2,(i,a, b) -> (long) (a << b))); } @Override @ForceInline ! public Long128Vector shiftR(Vector<Long> s) { Long128Vector shiftv = (Long128Vector)s; // As per shift specification for Java, mask the shift count. shiftv = shiftv.and(LongVector.broadcast(SPECIES, 0x3f)); return VectorIntrinsics.binaryOp( VECTOR_OP_URSHIFT, Long128Vector.class, long.class, LENGTH, --- 720,730 ---- (v1, v2) -> v1.bOp(v2,(i,a, b) -> (long) (a << b))); } @Override @ForceInline ! public Long128Vector shiftRight(Vector<Long> s) { Long128Vector shiftv = (Long128Vector)s; // As per shift specification for Java, mask the shift count. shiftv = shiftv.and(LongVector.broadcast(SPECIES, 0x3f)); return VectorIntrinsics.binaryOp( VECTOR_OP_URSHIFT, Long128Vector.class, long.class, LENGTH,
*** 732,742 **** (v1, v2) -> v1.bOp(v2,(i,a, b) -> (long) (a >>> b))); } @Override @ForceInline ! public Long128Vector aShiftR(Vector<Long> s) { Long128Vector shiftv = (Long128Vector)s; // As per shift specification for Java, mask the shift count. shiftv = shiftv.and(LongVector.broadcast(SPECIES, 0x3f)); return VectorIntrinsics.binaryOp( VECTOR_OP_RSHIFT, Long128Vector.class, long.class, LENGTH, --- 732,742 ---- (v1, v2) -> v1.bOp(v2,(i,a, b) -> (long) (a >>> b))); } @Override @ForceInline ! public Long128Vector shiftArithmeticRight(Vector<Long> s) { Long128Vector shiftv = (Long128Vector)s; // As per shift specification for Java, mask the shift count. shiftv = shiftv.and(LongVector.broadcast(SPECIES, 0x3f)); return VectorIntrinsics.binaryOp( VECTOR_OP_RSHIFT, Long128Vector.class, long.class, LENGTH,
*** 1105,1125 **** } return new Double128Vector(res); } @Override ! public Long128Vector rotateEL(int j) { long[] vec = getElements(); long[] res = new long[length()]; for (int i = 0; i < length(); i++){ res[(j + i) % length()] = vec[i]; } return new Long128Vector(res); } @Override ! public Long128Vector rotateER(int j) { long[] vec = getElements(); long[] res = new long[length()]; for (int i = 0; i < length(); i++){ int z = i - j; if(j < 0) { --- 1105,1125 ---- } return new Double128Vector(res); } @Override ! public Long128Vector rotateLanesLeft(int j) { long[] vec = getElements(); long[] res = new long[length()]; for (int i = 0; i < length(); i++){ res[(j + i) % length()] = vec[i]; } return new Long128Vector(res); } @Override ! public Long128Vector rotateLanesRight(int j) { long[] vec = getElements(); long[] res = new long[length()]; for (int i = 0; i < length(); i++){ int z = i - j; if(j < 0) {
*** 1130,1150 **** } return new Long128Vector(res); } @Override ! public Long128Vector shiftEL(int j) { long[] vec = getElements(); long[] res = new long[length()]; for (int i = 0; i < length() - j; i++) { res[i] = vec[i + j]; } return new Long128Vector(res); } @Override ! public Long128Vector shiftER(int j) { long[] vec = getElements(); long[] res = new long[length()]; for (int i = 0; i < length() - j; i++){ res[i + j] = vec[i]; } --- 1130,1150 ---- } return new Long128Vector(res); } @Override ! public Long128Vector shiftLanesLeft(int j) { long[] vec = getElements(); long[] res = new long[length()]; for (int i = 0; i < length() - j; i++) { res[i] = vec[i + j]; } return new Long128Vector(res); } @Override ! public Long128Vector shiftLanesRight(int j) { long[] vec = getElements(); long[] res = new long[length()]; for (int i = 0; i < length() - j; i++){ res[i + j] = vec[i]; }
< prev index next >