mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 14:24:46 +02:00
8338023: Support two vector selectFrom API
Reviewed-by: psandoz, epeter, sviswanathan
This commit is contained in:
parent
c34fb2c989
commit
709914fc92
89 changed files with 2788 additions and 20 deletions
|
@ -395,6 +395,24 @@ public class VectorSupport {
|
|||
assert isNonCapturingLambda(defaultImpl) : defaultImpl;
|
||||
return defaultImpl.apply(v1, v2, m);
|
||||
}
|
||||
/* ============================================================================ */
|
||||
|
||||
public interface SelectFromTwoVector<V extends Vector<?>> {
|
||||
V apply(V v1, V v2, V v3);
|
||||
}
|
||||
|
||||
@IntrinsicCandidate
|
||||
public static
|
||||
<V extends Vector<E>,
|
||||
E>
|
||||
V selectFromTwoVectorOp(Class<? extends V> vClass, Class<E> eClass, int length,
|
||||
V v1, V v2, V v3,
|
||||
SelectFromTwoVector<V> defaultImpl) {
|
||||
assert isNonCapturingLambda(defaultImpl) : defaultImpl;
|
||||
return defaultImpl.apply(v1, v2, v3);
|
||||
}
|
||||
|
||||
/* ============================================================================ */
|
||||
|
||||
/* ============================================================================ */
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue