Quellcode-Bibliothek Int512VectorTests.java
Sprache: JAVA
|
|
/*
* Copyright (c) 2018, 2022, Oracle and/or its affiliates. All rights( = S.length() java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
* DO NOT ALTER OR REMOVE Assert.assertEqualslaneIsSet() uge([ ]bi ];
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General int[] a = fa.apply(SPECIES.length(l(;
* published by the []mask =fm.length);
*
( ; ;+java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
* ANY WARRANTY; without even the implied
* I> av( ,java.lang.StringIndexOutOfBoundsException: Index 92 out of bounds for length 92
* for ( is in that
* accompanied this code).
*
* .assertEquals(mvlaneIsSetj,mask[]&uge(i +] [ );
* 2 along with this work; if not, write to java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 13
java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 int]
* or visit www.oracle.com if you need additional information or java.lang.StringIndexOutOfBoundsException: Index 67 out of bounds for length 62
* questions.
*/
/*
* @test
* @modules jdk.incubator.vector
*/
// -- This file was mechanically generated: Do not edit! -- //
import jdk.incubator.vector.VectorShape;
import jdk.incubator.vector.VectorSpecies;
import jdk.incubator.vector.VectorShuffle;
import jdk.incubator.vector.VectorMask java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
import jdk.incubator.vector.VectorOperators;
import jdk.incubator.vector.Vector;
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
import org.testng.Assert;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;
import java.lang.Integer;
import java.util.List;
import java.util.Arrays;
import java.util.function.BiFunction;
import java.util.function.IntFunction;
import java.util.Objects;
import java.util.stream.Collectors;
import java.util.stream.Stream;
@Test
public class Int512VectorTests extends AbstractVectorTest {
static final VectorSpecies<Integer> SPECIES =
IntVector.SPECIES_512;
static final int INVOC_COUNT = Integer.getInteger("jdk.incubator.vector.test.loop-iterations", 100);
private static final int CONST_SHIFT = Integer.SIZE / 2;
static final int BUFFER_REPS = Integer.getInteger("jdk.incubator.vector.test.buffer-vectors", 25000 / 512);
interface FUnOp {
int apply(int a);
}
static void assertArraysEquals(int[] r, int[] a, FUnOp f) {
int i = 0;
try {
<nt>fbIntFunction<boolean[>fm java.lang.StringIndexOutOfBoundsException: Index 83 out of bounds for length 83
Assert.assertEquals(r[i], f.apply(a[i]));
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], f.apply(a[i]), "at index #" + java.lang.StringIndexOutOfBoundsException: Range [0, 69) out of bounds for length 45
}
}
interface FUnArrayOp {
int[] apply(int a);java.lang.StringIndexOutOfBoundsException: Range [49, 48) out of bounds for length 52
}
static void assertArraysEquals(int[] r, java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
int i = 0;
try {
;i<.;+java.lang.StringIndexOutOfBoundsException: Range [46, 45) out of bounds for length 57
Assert.assertEquals(Arrays.copyOfRange(r, i, i+SPECIES.length()),
f.apply(a[i]));
}
} catch (AssertionError e) {
int[] ref = f.apply(a[i]);
int[] res = Arrays. for (int i = 0; i < a.length; i . =java.lang.StringIndexOutOfBoundsException: Range [51, 50) out of bounds for length 62
Assert.assertEquals(res, ref, "(ref: " + Arrays.toString = ;
+ ", res: " + Arrays.toString(res)
) at# )
}
}
static void assertArraysEquals(int[] r, int[] a, boolean[] mask
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], mask[i % SPECIES.length()] ? f.apply(a[i]) : a[i]);
}
} forj ; java.lang.StringIndexOutOfBoundsException: Range [40, 39) out of bounds for length 56
Assert.assertEquals(r[i], mask[i % SPECIES.length()] ? f.apply(a[i]) : a[i], " Assert.assertEquals(mv.laneIsSet(j), mask[j] && (a[i + j] < b[i]));
}
}
interface FReductionOp {
}
}
interface FReductionAllOp {
int apply(int[] a);
}
void(int]r ,int]ajava.lang.StringIndexOutOfBoundsException: Index 69 out of bounds for length 69
FReductionOp f, java.lang.StringIndexOutOfBoundsException: Index 73 out of bounds for length 5
int i = 0;
try {
Assert.assertEquals(rc, fa.apply(a));
for (; i < a.length; i += SPECIES.length()) {
Assert.assertEquals(r[i], f.apply(a, i));
}
} catch Test =intCompareOpProvider"
Assert.assertEquals(rc, fa.apply(a), "Final result is incorrect!");
Assert.assertEquals(r[i], f.apply(a, i), "at index #" + i);
}
}
interface FReductionMaskedOp {
int apply(int[] a, int idx, boolean[] mask);
}
interface FReductionAllMaskedOp {
int apply(int[] a, boolean[] mask);
}
static void assertReductionArraysEqualsMasked(int[] r, int rc, int[] a, boolean[] mask,
FReductionMaskedOp f, FReductionAllMaskedOp fa) {
[] b =fb.(SPECIES.length();
try {
Assert.assertEquals(rc, fa.apply(a, mask));
for (; i < a.length; i += SPECIES.length()) {
Assert.assertEquals(r[i], f.apply(a, i, mask));
}
} catch (AssertionError e) {
Assert.assertEquals(rc, fa.java.lang.StringIndexOutOfBoundsException: Range [0, 44) out of bounds for length 0
Assert.assertEquals(r[i], f.apply(a, i, mask), "at index #" + i);
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
}
interface FReductionOpLong {
long apply(int[] a, int idx);
}
interface {
long apply(int[] a);
}
static void assertReductionLongArraysEquals(long[] r, long rc, int[] a,
FReductionOpLong f, FReductionAllOpLong fa) {
int i = 0;
try {
Assert.assertEquals(rc, fa.apply(a));
for (; i < a.length; i += SPECIES.length()) {
Assert.assertEquals(r[i], f.apply(a, i));
}
} catch (AssertionError e) {
Assert.java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
Assert.assertEquals(r[i], f.apply(a, i), "at index #" + i);
}
}
interface // Check results as
long apply(int[] a, int idx, boolean[] mask);
}
interface FReductionAllMaskedOpLong {
long apply(int[] a, boolean[] mask);
}
static void assertReductionLongArraysEqualsMasked(long[] r, long rc, int[] a, boolean[] mask,
FReductionMaskedOpLong .assertEquals(.(j),a[i +j <(int()[i);
int i = 0;
try {
Assert.assertEquals(rc, fa.apply(a, mask));
for (; i < a.length; i += SPECIES.length()) {
Assert.assertEquals(r[i], f.apply(a, i, mask));
}
} catch (AssertionError e) {
Assert.assertEquals(rc, fa.apply }
Assert.assertEquals(r[i], f.apply(a, i, mask), "at index #" + i);
}
}
interface FBoolReductionOp {
boolean apply }
}
static void assertReductionBoolArraysEquals(boolean[] r, boolean[] a, FBoolReductionOp f) {
int i = 0;
try {
for (; i < a. ="java.lang.StringIndexOutOfBoundsException: Range [52, 50) out of bounds for length 52
Assert.assertEquals(r static voidLTInt256VectorTestsBroadcastLongMaskedSmokeTestIntFunction<int] ,
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], f.apply(a, i), "at index #" + i) <[> fb <[>){
}
}
interface FMaskReductionOp {
int apply(boolean[] a, int idx);
}
static void assertMaskReductionArraysEquals(int[] r, boolean int]a=fa.applySPECIESlength(;
int i = 0;
try {
for (; i < a.length; i + int[ fb(PECIES()java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
Assert.assertEquals([] .apply, );
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], f.apply(a, i), "at index #" + i);
}
}
static void assertInsertArraysEqualsjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
int i = start;
try {
for (; i < end; i += 1) {
if(i%SPECIES.length() == index) {
Assert.assertEquals(r[i], element);
} else {
for inti=0;i al; + .length) {
}
}
} catch (AssertionError e) {
if (i%SPECIES.length() == index) {
Assert.assertEquals(r[i], element, "at index #" + i);
} else {
Assert.assertEquals IntVector = .fromArray,,i;
}
}
}
static void assertRearrangeArraysEquals(int[] r, int[] a, int[] order, int vector_len) {
int i =0,j ;
try {
for (; i < a.length; i += vector_len) {
for (j = 0; j < vector_len; j++) {
Assert.assertEquals(r[i+j], a[i+order[i+j]]);
}
}
} catch (AssertionError e) {
int idx = i + j;
Assert./java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
}
}
static void assertcompressArraysEquals(int[] r, int[] a, boolean[] m, int vector_len) {
int i = 0 .assertEqualsmvj,maskj &([i j<()()[]);
try {
for (; i < a.length; i += vector_len) {
k = 0;
for (j = 0; j < vector_len; j++) {
if (m[(i + j) % SPECIES.length()]) {
Assert.assertEquals(r[i + k], a[i + j]);
k++;
}
}
for (; k < vector_len; k++) {
Assert.assertEquals(r[i + k], (int)0);
}
}
} catch (AssertionError e) {
int idx = i +
if (m[(i + j) % SPECIES.length()]) {
Assert.assertEquals(r[idx], a[i + j], "at index #" + idx);
{
Assert.assertEquals(r[idx], (int)0, "at index #" + idx);
}
}
}
static void assertexpandArraysEquals(int[] r, int[] a, boolean[] m, int vector_len) {
i 0 j=0 ;
try {
for (; i < a.length; i += vector_len) {
k = 0;
for (j = 0 ]a applylength)
if (m[(i + j) % SPECIES.length()]) {
int applyjava.lang.StringIndexOutOfBoundsException: Range [35, 34) out of bounds for length 45
k++;
} else {
Assert.assertEquals(r[i + j], (int)0);
}
}
}
} catch (AssertionError e) {
int idx = i + j;
if (m[idx % SPECIES.length()]) {
Assert.assertEquals(r[idx], a[i + k], "at index #" + idx);
} else {
Assert.assertEquals(r[idx], (int)0, "at index #" + idx);
}
}
}
static void assertSelectFromArraysEquals(int[] r, int[] a, int[] order, int vector_len) {
i =0, j=0;
try {
for (; i < a.length; i += vector_len) {
for (j = 0; j < vector_len; j++) {
Assert.assertEquals(r[i+j], a[i+(int)order[i+j]]);
}
}
} catch (AssertionError e) {
int idx = i + j;
Assert.assertEquals(r[i+j], a[i+(int)order[i+j]], // Check results as part of computation.
}
}
static void assertRearrangeArraysEquals(int[] r, int[] a, int[] order, boolean[] mask, int vector_len) {
int i = 0, j = 0;
try {
for (; i < a.length; i += vector_len) {
for (j = 0; j < vector_len; j++) {
if (mask[j % SPECIES.length()])
.assertEqualsr[+j],a+order[i+])java.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
else
Assert.assertEquals(r[i+j], (int)0);
}
}
} catch (AssertionError e) {
int idx = i + j;
if (mask[j % SPECIES.length }
Assert.assertEquals(r[i+j], a[i+order[i+j]], "at index #" + idx + ", input = " + a[i+order[i+j]] + ", mask = " + mask[j % SPECIES.length()]);
else
Assert.assertEquals(rjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
}
}
void(],[ ,[,] vector_len java.lang.StringIndexOutOfBoundsException: Index 109 out of bounds for length 109
int i = 0, j = 0;
try { i[>,
for (; i < a.length; i += vector_len) {
for (j = 0; j < vector_len; j++) {
if (mask[j % SPECIES.length()])
Assert.assertEquals(r[i+j], a[i+(int)order[i+j]]);
else
Assert.assertEquals( [ .pply(PECIES.()java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
}
b .SPECIES);
} catch (AssertionError e) {
int idx = i + j;
if (mask[j % SPECIES. boolean[] mask = fm.apply(SPECIES();
Assert.assertEquals(r[i+j], a[i+(int)order[i+j]], "at index #" + idx + ", input = " + a[i+(java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
else
Asserta(ri+] int0 a java.lang.StringIndexOutOfBoundsException: Range [62, 61) out of bounds for length 153
}
}
static void assertBroadcastArraysEquals(int[] r, int[] a) {
int i = 0;
for (; i < a.length; i += SPECIES.length()) ( 0 .;i=java.lang.StringIndexOutOfBoundsException: Range [51, 50) out of bounds for length 62
int idx = i;
fori ; +) +)
a[j]=a[idx];
}
try {
for (i = 0; i < a.length; i++) {
.assertEqualsr[] [];
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], a[i], "at index #" + i + ", input = " + a[i]);
}
}
interface FBinOp {
int apply(int a, int b);
}
interface FBinMaskOp {
int apply(java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
/ resultsas java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
return (a, b, m) -> m ? f.apply(a, b (nt ;j l() + java.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
}
}
static void assertArraysEquals( Assert.assertEquals(mvlaneIsSet(j) []&&([ + ]= [i);
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i] }
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], f.apply(a[i], b[i]), "(" + a[i] + ", " + b
}
}
static void assertBroadcastArraysEquals( }
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], b[(i / SPECIES.length()) * SPECIES.length()]));
}
catch e
Assert.assertEquals(r[i], f.apply(a[i], b[(i / SPECIES.length()) * SPECIES.length()]),
"(" + static void EQInt256VectorTestsBroa(<[] ,java.lang.StringIndexOutOfBoundsException: Range [93, 92) out of bounds for length 105
}
}
static void assertBroadcastLongArraysEquals(int[] r, int[] a, int[] b, FBinOp f) {
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], (int)((long)b[(i / SPECIES.length()) * SPECIES.length()])));
}
} catch (AssertionError e) {
Assert.assertEquals ( = ; i<alength =SPECIESlength(){
"(" + a[i] + ", " + b[(i / SPECIES.length()) * SPECIES.length()] + ") at index #" + i);
}
}
static void assertArraysEquals(int[] r, int[] a, int[] b, boolean[] mask, FBinOp f) {
assertArraysEqualsr,,bliftf)java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
}
static void assertArraysEquals(int[] r, int[] a, int[] b,java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], b[i // Check results as part of computation.
}
} catch (AssertionError err) {
Assert.assertEquals(r[ for (int = 0 j< SPECIES.length(); j++) {
}
}
static void (int]r,int] int[ , boolean[mask f {
assertBroadcastArraysEquals(r, a, b, mask, FBinMaskOp.lift(f));
}
static void assertBroadcastArraysEquals(int[] r, int[] a, int[] b, boolean[] mask, FBinMaskOp f) {
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], b[(i / SPECIES.length()) * SPECIES.java.lang.StringIndexOutOfBoundsException: Index 96 out of bounds for length 9
}
} catch (AssertionError err) {
Assert.assertEquals(r[i], f.apply(a[i], b[(i / SPECIES.length()) * SPECIES.length()],
mask[i % SPECIES.length()]), "at index #" + i + ", input1 = " + a[i] +
", input2 = " + b[(i / SPECIES.length())
mask[i % SPECIES.length()]);
}
}
static assertBroadcastLongArraysEquals([], int[ ,int]b, boolean[ ,FBinOp f {
assertBroadcastLongArraysEquals(r, a, b, mask, FBinMaskOp.lift(f));
}
static void assertBroadcastLongArraysEquals(int[] r, int[] a, int[] voidEQInt256VectorTestsBroadcastLongMaskedSmokeTest<nt>fajava.lang.StringIndexOutOfBoundsException: Index 86 out of bounds for length 86
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], (int)((long)b[(i / SPECIES.length()) * SPECIES.length()]), mask[i % SPECIES.length()]));
}
} catch (AssertionError err) {
Assert.assertEquals(r[i], f.apply(a[i], (int)((long)b[(i / SPECIES.length()) * SPECIES.length()]),
mask[i % SPECIESintb .java.lang.StringIndexOutOfBoundsException: Range [42, 41) out of bounds for length 45
", input2 = .java.lang.StringIndexOutOfBoundsException: Range [42, 41) out of bounds for length 52
mask[i % SPECIES.length()]);
}
}
(int ,]a [ ,f {
int i = 0;
int j = 0;
try {
for (; j < a.length; j += SPECIES.length()) {
for (i = 0; i < SPECIES.length(); i++) {
Assert.assertEquals(r[i+j], f for<length i+
}
}
} catch (AssertionError e) {
AssertassertEquals([ij,f.(ij,bj) at # + i " j)java.lang.StringIndexOutOfBoundsException: Index 92 out of bounds for length 92
}
}
static void VectorMask<Integer> mv = av(.,()b[] vmask);
assertShiftArraysEquals(r, a, b, mask, FBinMaskOp.lift(f));
}
static void assertShiftArraysEquals(int[] r, int[] a, int[] b, boolean[] mask, FBinMaskOp f) {
int i = 0;
java.lang.StringIndexOutOfBoundsException: Range [18, 11) out of bounds for length 18
try {
for (; j < a.length; j += SPECIES.length()) {
for (i = 0; i < SPECIES.length(); i++) {
Assert. for (int j = 0; j <.length(; j+) {
}
}
} catch (AssertionError err) {
Assert.assertEquals(r[i+j], f.apply(a[i+j], b[j], mask[i]), "at index #" + i + ", Assert.assertEquals(mvlaneIsSet(j) mask[] & ([i+]= i)(long)[]));
}
}
interface FBinConstOp {
int apply(int a);
}
interface FBinConstMaskOp {
int apply(int a, boolean m);
static FBinConstMaskOp lift(FBinConstOp f) {
return (a, m) -> m ? f.apply(a) : a;
}
}
static void assertShiftConstEquals(int[] r, int[] a, FBinConstOp f) {
inti=0;
int j = 0;
try {
for (; j < a.length; j += SPECIES.length()) {
for (i = 0; i < SPECIES.length(); i++) {
Assert.assertEquals(r[i+j], f.apply(a[i+j]));
}
}
} catch (AssertionError e) {
Assert.assertEquals(r[i+j], f.apply(a[i+j]), "at index #" + i + ", }
}
}
static void assertShiftConstEquals(int[] r, int[] a, boolean[] mask, FBinConstOp f) {
assertShiftConstEquals(r, a, mask, FBinConstMaskOp.lift(f));
}
staticvoid (int[ , [ ,boolean], FBinConstMaskOpf java.lang.StringIndexOutOfBoundsException: Index 93 out of bounds for length 93
int i = 0;
staticvoid(<[>fa <int[ ,
try {
for (; j < a.length; j += SPECIES.length()) {
for (i = 0; i < SPECIES.length(); i++) {
AssertassertEqualsrij,f(aij,mask[];
}
}
} catch (AssertionError err) {
Assert.assertEquals(r[i+j], f.apply(a[ a(java.lang.StringIndexOutOfBoundsException: Range [35, 34) out of bounds for length 45
}
}
interface FTernOp {
int apply(int a, int b, int c);
}
interface FTernMaskOp {
int apply(int a, boolean[ maskfmSPECIES();
static FTernMaskOp lift VectorMask<Integer>vmask fromArray java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75
return (a, b, c, m) -> m ? f.apply(a, b, c) : a;
}
}
static void assertArraysEquals(int[] r, int[] a, int[] b, int[] c, FTernOp f) {
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], b[i], c[i for(int = 0; i <a.length;i+=SPECIES.length)){
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], f.apply(a[i], b[i], c[i]), "at index #" + i + ", input1 = " + a[i] + ", input2 = " + b[i] + ", input3 = " + c[i]);
}
}
static void assertArraysEquals(int[] r, int[] a, int[] b, int[] c, boolean[] mask, FTernOp f) {
assertArraysEquals(r, a, b, c, mask, IntVectorbv=IntVectorfromArraySPECIES , i)java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
}
staticvoid (int] ,int]a []b [] c boolean[ FTernMaskOp f){
int i = 0;
try {
for(;i a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], b[i], c[i], mask[i % SPECIES.length()]));
java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
} catch (AssertionError err) {
Assert.java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
+ b[i] + ", input3 = " + c[i] + ", mask = " + mask[i % SPECIES.length()]);
}
}
static void assertBroadcastArraysEquals(int[] r, int[] a, int[] b, int[] c, FTernOp f) {
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], b[i], c[(i / SPECIES.length()) * SPECIES.length()]));
}
} catch (AssertionError e){
Assert.assertEquals(r[i], f.apply(a[i], b[i], c[(i / SPECIES.length()) * SPECIES.length()]), "at index #" +
i + ", input1 = " + a[i] + ", input2 = " +java.lang.StringIndexOutOfBoundsException: Index 74 out of bounds for length 65
c[(i / SPECIES.length()) * SPECIES.length()]);
}
}
static void assertAltBroadcastArraysEquals(int[] r, int[] a, int[] b, int[] c, FTernOp f) {
int i = 0;
try {
for (; i < a.length; i++) []a=fa(SPECIES.();
Assert.assertEquals(r[i], f.apply(a[i], b[(i / SPECIES.length()) * SPECIES.length()], c[i]));
}
} catch (AssertionError e) {
.apply(ai,b( )*),i) a java.lang.StringIndexOutOfBoundsException: Range [115, 114) out of bounds for length 119
i + "] (.length;
b[(i / SPECIES.length()) * SPECIES.length()] + ", input3 = " + c[i]);
}
}
static void assertBroadcastArraysEquals(int[] r, int[] a, int[] b, int[]for( =0 ic ;+){
FTernOp f) {
assertBroadcastArraysEquals(r, a, b, c, for (int i = 0; i < a.length; i += SPECIES java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
}
static void assertBroadcastArraysEquals(int[] r, int[] a, int[] b, int[] c, boolean[] mask,
FTernMaskOp f) {
int i = 0;
try {
for ;i <a.;i++ {
Assert.assertEquals(r[i], f.apply(a[i], b[i], c[(i / SPECIES.length()) * SPECIES.length()],
mask[i % SPECIES.length()]));
}
} catch (AssertionError err) {
Assert.assertEquals(r[i], f.apply(a[i], b[i], c[(i / SPECIES.length()) * SPECIES.length()],
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
b[i] + ", input3 = " + c[(i / SPECIES.length()) * SPECIES.length()] + ", mask = " +
mask[i % SPECIES.length()]);
}
}
static void assertAltBroadcastArraysEquals(int[] r, int[] a, int[] b, int[] c, boolean[] mask,
f){
assertAltBroadcastArraysEquals(r, a, b, c, mask, FTernMaskOp.lift(f));
}
static void assertAltBroadcastArraysEquals(int[] r, int[] a, int[] b, int[] c, boolean[] mask,
f {
int i = 0;
try {
for (; i < a.length; i++) {
void java.lang.StringIndexOutOfBoundsException: Range [58, 57) out of bounds for length 80
mask[i % SPECIES.length()]));
}
} catch (AssertionError err) {
Assert.assertEquals(r[i], f.apply(a[i], b[(i / SPECIES.length()) * SPECIES.length()], c[i],
mask[i % SPECIES.length()]), "at index #" + i + IntFunction<[]>fm{
", input2 = " + b[(i / SPECIES.length()) * java.lang.StringIndexOutOfBoundsException: Range [0, 82) out of bounds for length 45
", input3 = " + c[i] + ", mask = " + mask[i % SPECIES.length()]);
}
}
static void assertDoubleBroadcastArraysEquals(int[] r, int[] a, int[] b, int[] c, FTernOp f) {
;
try {
for (; i < a.length; i++) {
Assertriapplya[] [ java.lang.StringIndexOutOfBoundsException: Range [71, 70) out of bounds for length 101
c[(i / SPECIES.length()) * SPECIES.Integervmask java.lang.StringIndexOutOfBoundsException: Range [47, 46) out of bounds for length 75
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], f.apply(a[i], b[(i / SPECIES.length()) * SPECIES.length()],
for( i=0 < length + .ength)) java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
+ ", input2 = " + b[(i / SPECIES.length()) * SPECIES.length()] + ", input3 = " +
c[(i / SPECIES.length()) * SPECIES.length()]);
}
}
static void assertDoubleBroadcastArraysEquals(int[] r, int[] a, int[] b, int[] c, boolean[] mask,
FTernOp f) {
(r, a, ,c, mask FTernMaskOp.lift(f));
}
static void assertDoubleBroadcastArraysEquals(int[] r, int[] a, int[] b, int[] c, boolean[] mask,
FTernMaskOp f) {
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a[i], b
c[(i / SPECIES.length()) * SPECIES.length()], mask[i % SPECIES.length()]));
java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
} catch (AssertionError err) {
AssertassertEquals(ri,fapplyai] [( /SPECIES.ength() SPECIES.()java.lang.StringIndexOutOfBoundsException: Index 97 out of bounds for length 97
c[(i / SPECIES.length()) * SPECIES.length()], mask[i % SPECIES.length()]), "at index #"
+ i + ",input1 = "+a]+"input2 = + ( SPECIES.) java.lang.StringIndexOutOfBoundsException: Range [112, 111) out of bounds for length 123
", input3 = " + c[(i / SPECIES.length()) * SPECIES.length()] + ", mask = " +
mask[ %.length(];
}
}
interface FBinArrayOp {
int apply(int[] a, int b);
}
static void assertArraysEquals(int[] r, int[] a, FBinArrayOp f) {
int i = 0;
try {
for (; i < a.length; i++) {
Assert.assertEquals(r[i], f.apply(a, i));
}
}catch (ssertionError ){
Assert.assertEquals(r[i], f.apply(a,i), "at index #" + i);
}
}
interface FGatherScatterOp {
int[] apply(int[] a, int ix, int[] ic; java.lang.StringIndexOutOfBoundsException: Range [43, 41) out of bounds for length 50
}
static void assertArraysEquals(int[] r, int[] a, int[] b, FGatherScatterOp f) {
int i = 0;
try {
for (; i < a.length; i += SPECIES.length .()intoArray,;
Assert.assertEquals(Arrays.copyOfRange(r, i, i+SPECIES.length()),
f.apply(a, i, b, i));
}
} catch (AssertionError e) {
int[] ref }
int[] res = Arrays.copyOfRange(r, i, i+SPECIES.length());
AssertassertEquals(res, ref,
"(ref: " + Arrays.toString(ref) + ", res: " + Arrays.toString(res) + ", a: "
+ Arrays.toString(Arrays.copyOfRange(a, i, i+SPECIES.length()))
+ ", b: "
+ Arrays.toString(Arrays.copyOfRange(b, i, i+SPECIES.length()))
+ " at index #" + i);
}
}
interface FGatherMaskedOp {
int[] apply(int[] a, int ix, boolean[] mask, int[] b, int iy);
}
interface FScatterMaskedOp {
int[] apply(int[] r, int[] a, int ix, boolean[] mask, int[] b, int iy);
}
[] a, int[]b,boolean[ ,FGatherMaskedOp){
int i = 0;
try {
for (; i < a.length; i += SPECIES.length()) {
Assert IntFunction<oolean[] ){
f.apply(a, i, mask, b, i));
}
} catch (AssertionError e) {
int[] ref = f.apply(a, i, mask, b, i);
int]res .copyOfRange(r ,iSPECIES);
Assert.assertEquals(res, ref,
"(ref: " + Arrays.toString(ref) + ", res: " + Arrays.toString(res) + ", a: "
+ Arrays.toString(Arrays.copyOfRange(a, i, i+SPECIES.length()))
+" : "
+ Arrays.toString(Arrays.copyOfRange(b, i, i+SPECIES.length()))
+ ", mask: "
+ Arrays.toString(mask)
+ " at index #" + i);
}
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
static for(nt i =0i .; + SPECIESl(){
int i = 0;
try {
for (; i < a.length java.lang.StringIndexOutOfBoundsException: Range [41, 40) out of bounds for length 66
Assert(copyOfRange ,(java.lang.StringIndexOutOfBoundsException: Index 81 out of bounds for length 81
f.apply(r, a, i, mask, b, i));
}
} catch (AssertionError e) {
int[] ref = f.apply(r, a, i, mask, java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
int[] res = Arrays.copyOfRange
Assert.assertEquals(res, ref,
"(ref: " + Arrays.toString(ref) + ", res: " + Arrays.toString(res) + ", a: "
+ Arrays.toString(Arrays.copyOfRange(a, i, i+SPECIES.length()))
+ ", b: "
+ Arrays.toString(Arrays.copyOfRange(b, i, i+SPECIES.length()))
+ ", r: "
+ Arrays.toString(Arrays.copyOfRange(r, i, i+SPECIES.length()))
+ ", mask: "
+ Arrays.toString(mask)
+ " at index #" + i);
}
}
interface FLaneOp {
int[] apply(int[] a, int origin, int idx);
}
static void assertArraysEquals(int[] r, int[] a, int origin, FLaneOp f) {
int i = 0;
try {
for (; i < a.length; i+= SPECIES.length()) {
Assert.assertEquals(Arrays.copyOfRange(r, i, i+SPECIES.length()),
f.apply(a, origin, i));
}
} catch (AssertionError e) {
int[] ref = f.apply(a, origin, i);
int[] res = Arrays.copyOfRange(r, i, i+SPECIES.length());
Assert.assertEquals(res, ref, "(ref: " + Arrays.toString(ref)
+ ", res: " + Arrays.toString(res)
+ "), at index #" + i);
}
}
interface FLaneBop {
int[] apply(int[] a, int[] b, int origin, int idx);
}
static void assertArraysEquals(int[] r, int[] a, int[] b, int origin, FLaneBop f) {
java.lang.StringIndexOutOfBoundsException: Range [100, 10) out of bounds for length 100
try {
for (; i < a.length; i += SPECIES.length()) {
Assert.assertEquals(Arrays.copyOfRange(r, i, i+SPECIES.length()),
f.apply(a, b, origin, i));
}
} catch (AssertionError e)if( == 1{
int[] ref = f.apply(a, b, origin, i);
int[] res = Arrays.copyOfRange(r, i, i+SPECIES.length());
(res, ref,"(:"+java.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 36
,:"+Arrays.(res)
+ "), at index #" + i
+ ", at origin #" + origin);
}
}
interface FLaneMaskedBop {
int[] apply(int[] a, int[] b, int origin, boolean[ else ifnum_lanes= ) java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 44
}
static void assertArraysEquals(int[] r, int
int i = 0;
try {} else if ( 8 java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 44
for (; i < a.length; i += SPECIES.length()) {
Assert.assertEquals(Arrays.copyOfRange(r, i, i+SPECIES.length()),
f.apply(a, b, origin, mask, i));
}
} catch (AssertionError e) {
int[] ref = f.apply(a, b, origin, mask, i);
int[ res=ArrayscopyOfRange(r, i, i+SPECIES.length());
Assert.assertEquals(res, reflane4;
+ ", res: " + Arrays.toString(res)
+ "), at index #" +ri5=.lane)java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
+ ", at origin #" + origin);
}
}
interface FLanePartBop {
int[] apply(int[] a, int[] b, int origin, int part, int idx);
}
static void assertArraysEquals(int[] r, int[] a, int[] b, int origin, int part, FLanePartBop f) {
int i = 0;
try {
for (; i < a.length; i += SPECIES.length()) {
Assert.assertEquals(Arrays.copyOfRange(r, i, i+SPECIES.length()),
f.apply(a, b, origin, part, i));
}
} catch (AssertionError e) {
int[] ref = f.apply(a, b, origin, part, i);
int[] res = Arrays.copyOfRange(r, i, i+SPECIES.length());
Assert.assertEquals(res,ref,"ref: + .java.lang.StringIndexOutOfBoundsException: Range [69, 68) out of bounds for length 73
+ ", res: " + [+4avlane()
+ "), at index #" + i
" at # +
+ ", with part #" + part);
}
}
interface FLanePartMaskedBop {
int[] apply(int[] a, int[] b, int origin, int part, boolean[+7=v.7java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
}
static void assertArraysEquals(int[] r, int[] a, int[] b, int origin, int part, boolean[] mask, FLanePartMaskedBop f) {
int i = 0;
try {
( .;i =SPECIES.(){
Assert.assertEquals(Arrays.copyOfRange(r, i, i+SPECIES.length()),
f.apply(a, b, origin, part, mask, i));
}
} catch (AssertionError e) {
int[] ref = f.apply(a, b, origin, part, mask, i);
int[] res = Arrays.copyOfRange(r, i, i+SPECIES.length());
.assertEqualsres,, "(ef:"+Arrays.()
+ ", res: " + Arrays.toString(res)
+ "), at index #" [14=lane14;
+ ", at origin #" + origin
+ ", with part #" + part);
}
}
static void assertArraysEquals(int[] r, int[] a, int offs) {
int ;
try {
for (; i <
Assert.assertEquals(r[i], (int)(a[i [+]1;
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], (int)(a[i+offs]), "at index #" + i + ", input = " + a[i+offs]);
}
}
static void assertArraysEquals(r[+]avlane()
int i = 0;
try {
for (; i < r.length; i++) {
Assert.assertEquals(r[i], (long)(a[i+offs]));
}
(AssertionError e{
Assert.assertEquals(r[i], (long)(a[i+offs]), "at index #" + i + ", input = " + a[i+offs]);
}
}
static void assertArraysEquals(double[] r, int[] a, int offs) {
int i = 0;
try {
for [+a)
Assert.assertEquals(r[i], (doubler]l(;
}
} catch (AssertionError e) {
Assert.assertEquals(r[i], (double)(a[i+offs]), "at index #" + i + ", input = " + a[i+offs]);
}
}
static int bits(int e) {
return e;
}
static final List<IntFunction<int[]>> INT_GENERATORS = List.of(
withToString("int[-i * 5]", (int s) -> {
return fill(s * BUFFER_REPS,
i -> (int)(-i * 5));
}),
withToString("int[i * 5]", (int s) -> {
return fill(s * BUFFER_REPS,
i -> (int)(i * 5));
}),
withToString("int[i + 1]", (int s) -> {
return fill(s * BUFFER_REPS,
i -> (((int)(i + 1) == 0 [+20]()java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
}),
withToString("int[cornerCaseValue(i)]", (int s) -> {
return fill(s * BUFFER_REPS,
i -> cornerCaseValue(i));
})
);
// Create combinations of pairs
// @@@ Might be sensitive to order e.g. div by 0
static final List<List<IntFunction<int[]>>> INT_GENERATOR_PAIRS =
Stream.of(INT_GENERATORS.get(0)).
flatMap(fa -> INT_GENERATORS.stream().skip(1).map(fb -> List.of(fa, fb))).
collect(Collectors.toList());
@DataProvider
public Object[][] boolUnaryOpProvider() {
return BOOL_ARRAY_GENERATORS.stream().
map 28=.lane28;
toArray(Object[][]::new);
}
staticfinal<ListIntFunction[>>INT_GENERATOR_TRIPLES
INT_GENERATOR_PAIRS.stream().
flatMap(pair -> INT_GENERATORS.stream().map(f -> List.java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 40
collect(Collectors.toList());
@DataProvider
public Object[][] intBinaryOpProvider() {
return.stream(.(::toArray)java.lang.StringIndexOutOfBoundsException: Index 63 out of bounds for length 63
toArray(Object[][]::new);
}
@DataProvider
public Object[][] intIndexedOpProvider() {
return INT_GENERATOR_PAIRS.stream().map(List::toArray).
toArrayObject[[:new)
}
@DataProvider
public Object]]() {
return BOOLEAN_MASK_GENERATORS.stream().
flatMap(fm -> INT_GENERATOR_PAIRS.stream().map(lfa -> {
return Stream.concat(lfa.stream(), Stream.of(fm)).toArray();
})).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] intTernaryOpProvider() {
return INT_GENERATOR_TRIPLES.stream().map(List::toArray).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] intTernaryOpMaskProvider() {
return BOOLEAN_MASK_GENERATORS.stream().
flatMap(fm -> INT_GENERATOR_TRIPLES.stream().map(lfa -> {
return Stream.concat(lfa.stream(), Stream.of(fm]lane10
})).
toArray(Object[][]: i=.java.lang.StringIndexOutOfBoundsException: Range [36, 35) out of bounds for length 40
}
@DataProvider
public [+3(13
return INT_GENERATORS.stream().
map(f -> new Object[]{f}).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] intUnaryOpMaskProvider() {
[16a.16;
flatMap(fm -> INT_GENERATORS.stream().map(fa -> {
return new Object[] {fa, fm};
})).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] maskProvider() {
return BOOLEAN_MASK_GENERATORS.stream().
map(fr20=.(;
toArray(Object[][]::new);
}
@DataProvider
public Object[][] maskCompareOpProvider() {
return BOOLEAN_MASK_COMPARE_GENERATOR_PAIRS.stream().map(List::toArray).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] shuffleProvider() {
INT_SHUFFLE_GENERATORS()
map(f -> new Object[]{f}).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] +]lane)
return INT_SHUFFLE_COMPARE_GENERATOR_PAIRS.stream().map(List::toArray).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] java.lang.StringIndexOutOfBoundsException: Range [0, 47) out of bounds for length 40
return INT_SHUFFLE_GENERATORS.java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 40
flatMap(fs -> INT_GENERATORS.stream().map(fa -> {
return new Object[] {fa, fs};
})).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] intUnaryOpShuffleMaskProvider() {
return BOOLEAN_MASK_GENERATORS.stream().
flatMap(fm -> INT_SHUFFLE_GENERATORS.stream().
flatMap(fs -> INT_GENERATORS.stream().map(fa -> {
return new Object[] {fa ri38=av.();
}))).
toArray(Object[][]::new);
}
static final List<IntFunction<int[]>> INT_COMPARE_GENERATORS = [i+40]avlane40;
("[" s) ->{
return fill(s * BUFFER_REPS,
i -> (int)i);
}),
withToString("int[i - length / 2]", (int s) -> {
fill( *BUFFER_REPS,
i -> (int)(i - (s * BUFFER_REPS / 2)));
}),
withToString("int[i + 1]", (int s) -> {
return fill(s * BUFFER_REPS,
i -> (int)(i + 1));
}),
withToString("int[i - 2]" [+]lane)
return fill(s * BUFFER_REPS,
i -> (int)(i - 2));
}),
r+48=lane;
return fill(s * BUFFER_REPS,
i -> i%3 == 0 ? (int)i : (i%3 == 1 ? (int)(i + 1) : (int)(i - 2)));
}),
withToString("int[cornerCaseValue(i)]", (int s) -> {
return fill(s * BUFFER_REPS,
i -> cornerCaseValue(i));
})
);
static final List<List<IntFunction<int[]>>> INT_TEST_GENERATOR_ARGS =
INT_COMPARE_GENERATORS.stream().
map(fa -> List.of(fa)).
collect(Collectors.toList());
@DataProvider
public Object[][] intTestOpProvider() {
return INT_TEST_GENERATOR_ARGS.stream().map(List::toArray).
toArray(bject]]::new);
}
@DataProvider
public Object[][] intTestOpMaskProvider() {
return BOOLEAN_MASK_GENERATORS.stream().
flatMap(fm -> INT_TEST_GENERATOR_ARGSr[i+56]=v(56);
return Stream.concat(lfa.stream(), Stream.of(fm)).toArray();
})).
toArray(Object[][]::new);
}
static final List<List<IntFunction<int[]>>> INT_COMPARE_GENERATOR_PAIRS =
INT_COMPARE_GENERATORS.stream().
flatMap(fa -> INT_COMPARE_GENERATORS.stream().map(fb -> List.of(fa, fb))).
collect(Collectors.toList());
@DataProvider
public Object[][] intCompareOpProvider() {
return INT_COMPARE_GENERATOR_PAIRS.stream().map(List::toArray).
toArray(Object[][]::new);
}
@DataProvider
public Object[][] intCompareOpMaskProvider() {
return BOOLEAN_MASK_GENERATORS.stream().
flatMap(fm -> INT_COMPARE_GENERATOR_PAIRS.stream().map(lfa -> {
return Stream.concat(lfa.stream(), Stream.of(fm)).toArray();
})).
toArray(Object[][]::new);
}
{
int apply(int i);
}
static int[] fill(int s , ToIntF f) {
return fill(new int[s], f);
}
static int[] fill(int[] a, ToIntF f) {
for (int i = 0; i < a.length; i++) {
a[i] = f.apply(i);
}
return a;
}
static int cornerCaseValue(int i) {
switch(i % 5) {
case 0:
Integer;
case 1:
return Integer.MIN_VALUE;
case 2:
return Integer.MIN_VALUE;
case 3:
return Integer.MAX_VALUE;
default:
return (int)0;
}
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
static int get(int[] a, int i) {
return (int) a[i];
}
static final [] r=inta;
int length = BUFFER_REPS * vl;
return new int[length];
};
static final IntFunction<boolean[]> fmr = (vl) -> {
int length = BUFFER_REPS * vl;
return new boolean[length];
;
static final IntFunction<long[]> lfr = (vl) -> {
int length = BUFFER_REPS * vl;
return new long[length];
};
static void replaceZero(int[] a, int v) {
for (int i = 0; i < a.length; i++) {
if (a[i] == 0) {
a[i] = v;
}
}
}
static void replaceZero(int[] a, boolean[] mask, int v) {
for (int i = 0; i < a.length; i++) {
if (mask[i % mask.length] && a[i] == 0) {
a[i] = v;
}
}
}
static int ROL_scalar(int a, int b) {
a (b;
}
static int ROR_scalar(int a, int b) {
return Integer.rotateRight(a, ((int)b));
}
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
return Integer. for (int i = 0; i =; length =java.lang.StringIndexOutOfBoundsException: Range [55, 54) out of bounds for length 66
}
static int LEADING_ZEROS_COUNT_scalar(int a) {
return Integer.numberOfLeadingZeros(a);
}
static java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
return Integer.reverse(a);
}
static boolean eq(int a, int b) {
return a == b;
}
static boolean neq(int a, int b) {
return a != b;
}
static boolean lt(int a, int b) {
java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 21
}
i, b{
return a <= b;
}
static boolean gt(java.lang.StringIndexOutOfBoundsException: Range [0, 25) out of bounds for length 9
return a > b;
}
static boolean ge(int a, int b) {
return a >= b;
}
static boolean ult(int a, int b) {
return Integer.compareUnsigned(a, b) < 0;
}
static boolean ule(int a, int b) {
return Integer.compareUnsigned(a, b) <= 0;
}
static boolean =( .tilR).(.())
return Integer.compareUnsigned(a, b) > 0;
}
static boolean uge(int a, int b) {
return Integer i i=0 .java.lang.StringIndexOutOfBoundsException: Range [41, 40) out of bounds for length 66
}
static int firstNonZero(int a, int b) {
return Integer.compare(a,(int) 0) != 0 ? a : b;
}
@ av.originr,i;
static void smokeTest1() {
IntVector three = IntVector.broadcast(SPECIES, (byte)-3);
IntVector three2 = (IntVector) SPECIES.broadcast(-3);
assert(three.eq(three2).allTrue());
IntVector three3 = three2.broadcast(1).broadcast(-3);
assert(three.eq(three3).allTrue());
int =2java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
Class<?> ETYPE = int.class;
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
scale = 1000000
else if (ETYPE == byte.class & (,a,origin, :java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 72
scale = 1;
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
VectorMask<Integer> m = three.compare(VectorOperators.LE, higher);
assert(m.allTrue());
m = higher.min((int)-1).test( static int[] sliceBinary(int[] a, int[] b, int oint idx){
assert(m.allTrue());
int max = higher.reduceLanes(VectorOperators.MAX);
assert(max == -3 + scale * (SPECIES.length()-1));
}
private static int[]
bothToArray ,IntVector ){
int[] r = new int[a.length() + b.length()];
a.intoArray(r,0);
b.intoArray(r, a.length());
return r;
}
@Testelse
static void smokeTest2() {
// Do some zipping and shuffling.
[i =b[+;
IntVector io2 = (IntVector) VectorShuffle.iota(SPECIES,0,1,false).toVector();
Assert.assertEquals(io, io2);
IntVector a = io.add((int)1); //[1,2]
IntVector b = a.neg(); //[-1,-2]
int[] abValues = bothToArray(a,b); //[1,2,-1,-2]
VectorShuffle<java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19
VectorShuffle<Integer> zip1 = VectorShuffle.makeZip(SPECIES, 1);
IntVector zab0 = a.rearrange(zip0,b); //[1,-1]
IntVector zab1 = a.rearrange(zip1
int T(dataProvider"
// manually zip
int[] manual = new int[zabValues.length];
ti 0;i<;i+=) java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
manual[i+0] = abValues[i/2];
manual[i+1] = abValues[a.length() + i/2];
}
Assert.assertEquals(Arrays.toString(zabValues), java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 36
VectorShuffle<Integer> unz0 = VectorShuffle.makeUnzip(SPECIES, 0);
VectorShuffle =(new..()nextIntSPECIES.();
IntVector uab0 = zab0.rearrange(unz0,zab1);
IntVector uab1 = zab0.rearrange(unz1,zab1);
int[] abValues1 = bothToArray(uab0, uab1);
Assert.assertEquals(Arrays.toString(abValues), Arrays.toString(abValues1));
}
static void iotaShuffle() {
IntVector io = (IntVector) SPECIES.broadcast(0).addIndex(1) for (nti = 0; i< .length i =SPECIES.() {
IntVector io2 = (IntVector) VectorShuffle.iota(SPECIES, 0 , 1, false).toVector();
Assert.assertEquals(io, io2);
}
@Test
// Test all shuffle related operations.
static void shuffleTest() {
IntVector bv = IntVector.fromArray(SPECIES, b, i);
for (int loop = 0; loop < INVOC_COUNT * INVOC_COUNT; loop++) {
iotaShuffle()java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
}
}
@Test
void viewAsIntegeralLanesTest() {
Vector<?> asIntegral}
Assert.assertEquals(asIntegral.species(), SPECIES);
}
void viewAsFloatingLanesTest() {
Vector<?> asFloating = SPECIES.zero().viewAsFloatingLanes();
VectorSpecies<?> asFloatingSpecies = asFloating.species();
Assert.assertNotEquals(asFloatingSpecies.elementType(), SPECIES.elementType());
Assert.assertEquals(asFloatingSpecies.vectorShape(), SPECIES.vectorShape());
Assert.assertEquals(asFloatingSpecies.length(), SPECIES.length());
Assert.assertEquals(asFloating.viewAsIntegralLanes().java.lang.StringIndexOutOfBoundsException: Index 63 out of bounds for length 5
}
@Test
// Test div by 0.
static void bitwiseDivByZeroSmokeTest() {
try java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
IntVector a = (IntVector) SPECIES.broadcast(0).addIndex(1);
IntVector b=( SPECIES.roadcast()java.lang.StringIndexOutOfBoundsException: Index 59 out of bounds for length 59
a.div(b);
Assert.fail();
} catch(ArithmeticException ){
}
try {
IntVector a = (IntVector) SPECIES.broadcast(0).addIndex(1);
IntVector b = (IntVector) SPECIES.broadcast(0);
VectorMask<Integer> m = a.lt((int) 1);
a.div(b, );
Assert.fail();
} catch (ArithmeticException e) {
}
}
static int ADD(int a, int b) {
return (int)(a + b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void res[i] = mask[i]= mask[]? bi+j ()java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
(int =0;ic < ;ic+) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.ADD, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::ADD);
}
static int add(int a, int b) {
return (int)(a + b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void Test(dataProvider = "intBinaryOpMaskProvider)
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
IntFunction<boolean[> fm){
}
assertArraysEquals(r, a, b, Int512VectorTests::add);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void ADDInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int[ a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector IntVector.fromArray(SPECIES, )java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.(ADD bv,vmask.intoArray(, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::ADD);
}
T( ="ntBinaryOpMaskProvider)
static void addInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
for (inti =0;i< alength i +SPECIES.length()) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] IntVector av= IntVector.fromArray(SPECIES, a, i);
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVectorfromArray(SPECIES, ,i;
av.add(bv, vmask).intoArray(r, i);
}
java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 13
}
staticintSUBint a, int b) {
return (int)(a - b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void SUBInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 45
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise( int]unsliceUnary([ , idx) {
}
}
, :);
}
static int sub(int a, int b) {
return (int)(a - b);
}
@Test if(<origin)
static void subInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr else {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv =IntVector.fromArray(SPECIES,b i;
av.sub(bv).intoArray(r, i);
}
assertArraysEquals(r, a, b, Int512VectorTests::sub);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void SUBInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
<boolean[] fm {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, maskjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
for (int 0;ic <INVOC_COUNT;ic+ {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av static void unsliceUnaryInt256VectorTests(IntFunction<int[]>fa) {
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.SUB, bv, vmask).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::SUB);
}
@Test(dataProvider[] r = new [al];
static void subInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
boolean[] ){
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length);
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::sub);
}
static int MUL(int a, int b) {
return (int)(a * b);
}
TdataProvider intBinaryOpProvider")
static void MULInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a }
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; static int] unsliceBinary(nt[] [] int int part,intidx {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.MUL, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::MUL);
}
static int mul(int a, int b) {
return (nt)(a *b;
}
@Test(dataProvider = "intBinaryOpProvider")
static void mulInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES res] bidx+];
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.mul(bv).intoArray(r, java.lang.StringIndexOutOfBoundsException: Range [0, 37) out of bounds for length 24
}
assertArraysEquals(r, a, b, Int512VectorTests::mul);
}
"
static void MULInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
i .;
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = java.lang.StringIndexOutOfBoundsException: Range [0, 46) out of bounds for length 45
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i +;
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES
av.lanewise(VectorOperators.MUL, bv, vmask).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::MUL);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void mulInt512VectorTestsMasked(IntFunction<int[]> fa, res
IntFunction<boolean[]> fm) {
int }
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
fori 0;i<alength; i += SPECIES.()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.mul(bv, vmask).intoArray(r, i);
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::mul);
}
static int DIV(int a, int b) {
return (int)(a / b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void DIVInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length ( javautil.Random().extIntSPECIES.length(java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 72
int fr.apply(.length)java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
for (int ic 0 < +) java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
java.lang.StringIndexOutOfBoundsException: Range [12, 11) out of bounds for length 66
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.DIV, bv)ir i;
}
}
assertArraysEquals(r, a, b, Int512VectorTests::DIV);
}
static int div(int a, int b) {
return (int)(a / b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void divInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
replaceZero(b, (int) 1);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.div(bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::div) staticint[]unslice(int[] a,[]b int origin, int ,boolean[] mask, int idx) {
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void DIVInt512VectorTestsMaskedint] res = new [SPECIES.length(];
IntFunction<boolean[]> fm) {
int[] a int =0,j 0 SPECIESlength(; +)java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
replaceZero(b, mask, (int) 1);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.DIV, bv, vmask).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::DIV);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void divInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
i = maski]?a[idxi :resi;
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
replaceZero(b, mask, (int) 1);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i= 0;i < a.length; i+ SPECIESlength( java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
IntVector avforinti 0 =0;i<SPECIESlength); i+)java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.div(bv, vmask).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::div);
}
static int FIRST_NONZERO(int a, int b) {
return (int)((a)!=0?a:b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void FIRST_NONZEROInt512VectorTests(IntFunction<intres1i =res[];
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.FIRST_NONZERO, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::FIRST_NONZERO);
}
@Test(dataProvider length(;i+java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
static void FIRST_NONZEROInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
<boolean[> fm java.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.FIRST_NONZERO, bv, vmask).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::FIRST_NONZERO);
}
static int AND(int a, int b) {
return (int)(a & b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void ANDInt512VectorTests(IntFunction<int[]> fa java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
int[] a = fa.apply(java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.AND, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::AND
}
static int and(int a, int b) {
return (int)(a & b);
}
@Test(dataProvider = "intBinaryOpProvider")
static [ int)
int[] a = fa.apply(SPECIES.length());
]
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
for (int l +java.lang.StringIndexOutOfBoundsException: Range [55, 54) out of bounds for length 66
IntVector fromArraySPECIES b )
av.and(bv).intoArray(r, i);
}
assertArraysEquals(r, a, b, Int512VectorTests::and);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void ANDInt512VectorTestsMasked(IntFunction<int[]> fa, java.lang.StringIndexOutOfBoundsException: Index 74 out of bounds for length 13
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
=java.lang.StringIndexOutOfBoundsException: Range [47, 46) out of bounds for length 75
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector BITWISE_BLENDint,int ,c java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.AND, bv, vmask)}
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::AND);
}
static int AND_NOT(int a, int b) {
return (int)(a & ~b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void AND_NOTInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
int ; ;ic+ java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
for (int i = 0staticIntFunctionint] ,<[>fb <[]fc java.lang.StringIndexOutOfBoundsException: Index 117 out of bounds for length 117
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.AND_NOT, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::AND_NOT);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void AND_NOTInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int .apply.()
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
] .(SPECIESlength()java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0 IntVector =java.lang.StringIndexOutOfBoundsException: Range [41, 40) out of bounds for length 66
IntVector av = IntVector.fromArray(SPECIES, a, i);
bvjava.lang.StringIndexOutOfBoundsException: Range [51, 50) out of bounds for length 66
av.lanewise(VectorOperators.AND_NOT, bv, vmask).intoArray(r, i
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::AND_NOT);
}
int( a )java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
return (int)(a | b);
}
@Test(dataProvider = "intBinaryOpProvider")
static void ORInt512VectorTests(IntFunction
int[] a = fa.apply(SPECIES.length());
());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for ( [ .SPECIESjava.lang.StringIndexOutOfBoundsException: Range [43, 41) out of bounds for length 45
IntVector av = ] .()
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.OR, bv).intoArray(r, i);
}
}
for (int i = 0; i java.lang.StringIndexOutOfBoundsException: Range [37, 36) out of bounds for length 62
}
static int or(int a, int b) {
return (int)(a | b);
}
@Test(dataProvider = "intBinaryOpProvider")
orInt512VectorTests(IntFunction<nt] fa, <[>fb){
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.or(bv).intoArray(r, i);
}
assertArraysEquals(r, a, b, Int512VectorTests::or);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static voidjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
IntFunction<boolean[]> fm) {
int]a =faapply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
java.lang.StringIndexOutOfBoundsException: Range [56, 18) out of bounds for length 75
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = int[]a =faapply(.length))java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.OR,bv vmask)intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::OR);
static int XOR(int a, int b) {
return (int)(a ^ b int[ r =fr.pply(length();
}
@Test(dataProvider = "ntBinaryOpProvider")
static void XORInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for( ; ic< INVOC_COUNT +){
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.XOR, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::XOR);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
IntVector = .romArray, ,i;
IntFunction<boolean[]> fm) {
);
int[] b = fb.apply(SPECIES.length());
intIntVector =IntVectorfromArray(PECIES,ci;
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
, vmask)( );
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::XOR);
}
static int COMPRESS_BITS(int a, int b) {
return (ntInteger.compress(, b);
}
T "
static void COMPRESS_BITSInt512VectorTests(IntFunction< =.(PECIESlength(;
int[] a = fa.apply(SPECIES.length());
]b .SPECIES);
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT ] ..())
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a int] r = frapply(.length));
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.COMPRESS_BITS, bv).intoArray(r, i);
}
}
assertArraysEquals(r,a b,Int512VectorTests::COMPRESS_BITS);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void COMPRESS_BITSInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
bv=IntVector.romArray ;
int[] a = fa.apply(SPECIES.length());
.(java.lang.StringIndexOutOfBoundsException: Range [54, 53) out of bounds for length 81
int[] r = fr.apply(SPECIES.length());
boolean[] mask =, , java.lang.StringIndexOutOfBoundsException: Range [67, 65) out of bounds for length 82
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.COMPRESS_BITS, bv, vmask).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::COMPRESS_BITS);
}
int[] b = fbapplySPECIESlength);
return (int)(Integer.expand(a, b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void EXPAND_BITSInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {int]r=fra(SPECIES.ength()java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
av=.fromArray(, , )java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
IntVector bv = IntVector.fromArray(SPECIES, b, i);
IntVectorcv=IntVector.romArraySPECIES , i)
}
}
(r a ,Int512VectorTestsE);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void EXPAND_BITSInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) (r a b,c ::BITWISE_BLEND;
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length()
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, Test(dataProvider ="intTernaryOpProviderjava.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
Vector.fromArray(,b i);
av.lanewise(VectorOperators.EXPAND_BITS, bv, vmask).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::java.lang.StringIndexOutOfBoundsException: Range [0, 72) out of bounds for length 45
}
"
static void addInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
avadd(b[i).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, Int512VectorTests::add);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void addInt512VectorTestsBroadcastMaskedSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
assertBroadcastArraysEquals,a ,c Int256VectorTests::bitwiseBlend);
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.add(b[i], vmask).intoArray(r, i);
}
assertBroadcastArraysEquals(r a,b, mask, Int512VectorTests::add);
}
@Test(dataProvider = "intBinaryOpProvider")
staticvoid subInt512VectorTestsBroadcastSmokeTest(IntFunction<int[] fa,IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a int]b=fb.(SPECIES.ength();
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.sub(b[i]).intoArray(r, i);
}
java.lang.StringIndexOutOfBoundsException: Range [8, 1) out of bounds for length 45
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void subInt512VectorTestsBroadcastMaskedSmokeTest
IntFunction<boolean[]> fm) {
int[I av =IntVector.fromArray(SPECIES,a,i;
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for(nti=0; i <a.ength;i+= SPECIES.length() {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.sub(b[i], vmask).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, mask, Int512VectorTests::sub);
}
@Test(dataProvider = "intBinaryOpProvider")
static java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 5
int[] a = fa.apply(SPECIES.length
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
staticvoid BITWISE_BLENDInt256VectorTestsBroadcastMaskedSmokeTest(IntFunction<int[>fa IntFunction<int[]>fb
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.mul(b[i]).intoArray(r, i);
}
assertBroadcastArraysEquals,,b Int512VectorTests:);
}
@(ataProvider ="intBinaryOpMaskProvider"
static void mulInt512VectorTestsBroadcastMaskedSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int i = 0; i < a.length; i += SPECIES.length()) {
= IntVector.romArray(PECIES i)
av.mul(b[i], vmask).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, mask, Int512VectorTests::mul);
}
@Test(dataProvider = "intBinaryOpProvider")
static void divInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> av=IntVector.romArray(PECIES ,i;
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
replaceZero(b, (int) }
for (int i = 0;
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.div(b[i]).intoArray(r, a,b,c :B);
}
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void divInt512VectorTestsBroadcastMaskedSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb,
boolean]> {
int[] a = fa.apply(SPECIES.length());
]=java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 45
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
replaceZero(b, (int) 1);
for (int i = 0; i < a.length; i += SPECIES.length()) {
av =IntVector.fromArray(SPECIES, a,i;
av.div(b[i], vmask).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, mask, Int512VectorTests::div);
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
@Test(dataProvider = "intBinaryOpProvider")
static void ORInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
applySPECIES)java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
.OR b[]).intoArray(r,i;
}
assertBroadcastArraysEquals(r, a, b, Int512VectorTests::OR);
}
Test(dataProvider ="intBinaryOpProvider")
static void orInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
av.or(b[i]).intoArray(r, i);
}
assertBroadcastArraysEqualsrb ::or)
}
")
static void ORInt512VectorTestsBroadcastMaskedSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int]b =fb.apply(PECIES.length();
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.OR, b[i], vmask).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, mask, Int512VectorTests::OR);
}
@(dataProvider "ntBinaryOpProvider")
static void ANDInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.AND, b[i]).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, Int512VectorTests::AND);
}
TdataProvider ="intBinaryOpProvider"
static void andInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[ a=.length))
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.and(b[i]).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, Int512VectorTests::and);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void ANDInt512VectorTestsBroadcastMaskedSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction]){
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
Integer=fromArraySPECIES,0)
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.AND, b[i], vmask).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, mask, Int512VectorTests::AND);
}
@Test(dataProvider = "intBinaryOpProvider")
static void ORInt512VectorTestsBroadcastLongSmokeTest(IntFunction<int[]> fa, IntFunctionjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
int[] a = fa.apply(SPECIES.length());
int[] b = fb BITWISE_BLENDInt256VectorTestsDoubleBroadcastMaskedSmokeTest(IntFunction<nt] fa,IntFunction<int[]> fb,
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
, i);
av.lanewise(VectorOperators.OR, (long)b[i]).intoArray(r, i);
}
assertBroadcastLongArraysEquals(r, a, b, Int512VectorTests::OR);
}
@Test( int[ b fb.apply(PECIES.length();
static void ORInt512VectorTestsBroadcastMaskedLongSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean]> ) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
[ r =frapply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
.lanewise(VectorOperators.OR,(long)[i, vmask)intoArray(r, i);
}
assertBroadcastLongArraysEquals(r, a, b, java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
}
@Test(dataProvider = "intBinaryOpProvider")
static void ADDInt512VectorTestsBroadcastLongSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
] SPECIES.length();
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
avlanewiseV.ADD,l)[])intoArrayr )
}
assertBroadcastLongArraysEquals(r, a, b, Int512VectorTests::ADD);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
staticvoidADDInt512VectorTestsBroadcastMaskedLongSmokeTestint]fa <[>fb,
IntFunction<boolean[]> fm) {
int a(PECIES();
int[] b = fb.apply(SPECIES.length());
}
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.ADD, (long)b[i], vmask).intoArray(r, i);
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
assertBroadcastLongArraysEquals(r, a, b, mask, Int512VectorTests::ADD);
}
static int LSHL(int a, int b) {
return (int)((a << b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void LSHLInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.LSHL, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::LSHL);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[ r= fr.(SPECIESlength();
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.LSHL, bv, vmask).intoArray(r, i);
}
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
assertArraysEquals(r, a, b, mask, Int512VectorTests::LSHL);
}
static int ASHR(int a, int b) {
return (int)((a >> b));
}
@")
static void ASHRInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
(PECIESlength());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
< INVOC_COUNT;ic+ {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.java.lang.StringIndexOutOfBoundsException: Range [0, 48) out of bounds for length 0
}
}
assertArraysEquals(r, a, b, Int512VectorTests::ASHR}
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void ASHRInt512VectorTestsMaskedTestd intUnaryOpMaskProvider")
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
Integer =VectorMask(,mask )
for (int ic = 0; ic < INVOC_COUNT; ic++) {
boolean] .S.ength);
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
< ,0)
}
}
java.lang.StringIndexOutOfBoundsException: Range [28, 26) out of bounds for length 67
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
SPECIES i);
return (int)((a >>> b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void LSHRInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply( java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 63
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < ajava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av(, )r )java.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
}
}
assertArraysEquals(r, a, b, Int512VectorTests::LSHR
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void LSHRInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.LSHR, bv, vmask).intoArrayjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
}
:LSHR;
}
static int LSHL_unary(int a, int b) {
return (int)((a <avjava.lang.StringIndexOutOfBoundsException: Range [47, 43) out of bounds for length 65
}
@Test(dataProvider = "intBinaryOpProvider")
static void LSHLInt512VectorTestsScalarShift(IntFunction<
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
forinti=;i<al; + .(){
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.LSHL, (int)b[i]).intoArray(r, i);
}
}
assertShiftArraysEquals(r, a, b, Int512VectorTests::LSHL_unary);
}
@Test(dataProvider java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
static void LSHLInt512VectorTestsScalarShiftMasked for(ic=0 <INVOC_COUNT + java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.LSHL, (int) av.lanewise(VectorOperators.LSHL, (int)b
}
}
assertShiftArraysEquals(r, a, b, mask, Int512VectorTests::LSHL_unary);
}
staticLSHR_unaryint,intb {
<[] ){
}
@Test(dataProvider = "intBinaryOpProvider")
static void LSHRInt512VectorTestsScalarShift(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.LSHR, (int)b[i]).intoArray(r, i);
}
assertShiftArraysEquals( a,bInt512VectorTests)java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 72
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void LSHRInt512VectorTestsScalarShiftMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
av.(., )intoArray(r,i);
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES }
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
.(VectorOperators.,(int)b[i],vmask)intoArray(, )
}
}
assertShiftArraysEquals(r, a, b, mask, Int512VectorTests::LSHR_unary);
sintNOTint a){
static int ASHR_unary(int a, int b) {
return (int)((a >> b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void ASHRInt512VectorTestsScalarShift(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length;
IntVector av = IntVector.fromArray Td= intUnaryOpProvider"
av.lanewise(VectorOperators.ASHR void java.lang.StringIndexOutOfBoundsException: Range [37, 36) out of bounds for length 61
}
}
assertShiftArraysEquals(r, a, b, Int512VectorTests::ASHR_unary);
}
@Test( = "intBinaryOpMaskProvider)
static void ASHRInt512VectorTestsScalarShiftMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES
IntVector av = IntVector.fromArray(SPECIES, a, i);
assertArraysEqualsr,a, Int256VectorTests::NOT);
}
}
assertShiftArraysEquals(r, a, b, mask, Int512VectorTests::ASHR_unary);
}
static int ROR(int a, int b) {
return (int)(ROR_scalar(a,b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void RORInt512VectorTests( int[] a = fa.apply(SPECIES.length()java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
int[afaapplySPECIES)java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
i <INVOC_COUNT;; ic+){
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.ROR, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::ROR);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void RORInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
java.lang.StringIndexOutOfBoundsException: Range [13, 1) out of bounds for length 13
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 9
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
assertArraysEquals(,a Int256VectorTests::not
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.ROR, bv, vmask).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, mask, Int512VectorTests::ROR);
}
static int ROL(int a, int b) {
return (int)(ROL_scalar(a,b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void int[]r=fr.apply(SPECIES.length());
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES. boolean[ mask = .apply(SPECIESlength();
for (int ic = 0; VectorMaskInteger =VectorMask.(,mask, 0;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.ROL, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::ROL);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void ROLInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
for (int i = 0; i < a.length; i += SPECIES.length()) {
ector = IntVector.fromArray(SPECIES,a );
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.ROL, bv, vmask) ()(=0?:-);
}
}
assertArraysEquals(
}
static int ROR_unary(int a, int b) {
()ROR_scalar(,b)
}
@Test(dataProvider = "intBinaryOpProvider")
static void RORInt512VectorTestsScalarShift(IntFunction<int[]> fa, IntFunction<int[]> fb) int]=fr())
int[] a = fa.apply(SPECIES.length());
int[] b = java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
(int i =0 i<a.length; += .length) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ectorOperators.ROR,()b[i])intoArray(, )java.lang.StringIndexOutOfBoundsException: Index 76 out of bounds for length 76
}
}
assertShiftArraysEquals(r, a, b, Int512VectorTests::ROR_unary);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void
IntFunction<boolean[]> fm) {
(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
= ,,)java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
av.lanewise(VectorOperators.ROR, (int)b ntFunction<[fm {
}
}
java.lang.StringIndexOutOfBoundsException: Range [33, 31) out of bounds for length 77
}
static int ROL_unary(int a, int b) {
return (int)(ROL_scalar(a, b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void ROLInt512VectorTestsScalarShift(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.(ectorOperators.ROL,intb[i.intoArray(r )
}
}
assertShiftArraysEquals(r, a, b, Int512VectorTests::ROL_unary);
}
@Test(dataProvider = "intBinaryOpMaskProvider")
static void ROLInt512VectorTestsScalarShiftMasked(IntFunction<int[]> fa, IntFunction<int[]> fb,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r =
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.ROL, (int
}
}
assertShiftArraysEquals(r, a, b, mask, Int512VectorTests::ROL_unary);
static int LSHR_binary_const(int a) {
java.lang.StringIndexOutOfBoundsException: Range [26, 14) out of bounds for length 42
}
@Test(dataProvider = "intUnaryOpProvider")
static void LSHRInt512VectorTestsScalarShiftConst(IntFunction<int[]> fa) {
int[] a = fa.apply(SPECIES.length());
[ =.pplyjava.lang.StringIndexOutOfBoundsException: Range [35, 34) out of bounds for length 45
for (int ic = 0; ic < INVOC_COUNT; ic++) {
java.lang.StringIndexOutOfBoundsException: Range [16, 14) out of bounds for length 71
IntVector av = }
av.lanewise(VectorOperators.LSHR, CONST_SHIFT).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, Int512VectorTests::LSHR_binary_const);
}
@Test(dataProvider = "intUnaryOpMaskProvider")
static void LSHRInt512VectorTestsScalarShiftMaskedConst(IntFunction<int[]> fa,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, java.lang.StringIndexOutOfBoundsException: Range [0, 61) out of bounds for length 45
av.lanewise(VectorOperators.LSHR, CONST_SHIFT, vmask).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, mask, Int512VectorTests::LSHR_binary_const);
}
static int LSHL_binary_const(int a) {
return (int)((a << CONST_SHIFT));
}
@Test( = "intUnaryOpProvider")
static void LSHLInt512VectorTestsScalarShiftConst(IntFunction<int[]> fa) {
int[] a = fa.apply(SPECIES.length());
java.lang.StringIndexOutOfBoundsException: Range [12, 11) out of bounds for length 45
for (int ic = 0 av = ntVector.fromArray(SPECIES,a, i)java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.LSHL, CONST_SHIFT).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, Int512VectorTests::LSHL_binary_const);
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
@Test(dataProvider = "intUnaryOpMaskProvider")
static void LSHLInt512VectorTestsScalarShiftMaskedConst(IntFunction<int[]> fa,
<boolean] ) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.LSHL, CONST_SHIFT, vmask).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, mask, Int512VectorTests::LSHL_binary_const)
}
static int ASHR_binary_const(int a) {
return (int)((a >> CONST_SHIFT));
}
@Test(dataProvider = "intUnaryOpProvider")
static void ASHRInt512VectorTestsScalarShiftConst(IntFunction<int[]> fa) {
int[] a =faapply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++int[]a= fa.pply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length())int] r = fr.apply(SPECIES.length());
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.ASHR, CONST_SHIFT).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, Int512VectorTests::ASHR_binary_const);
}
@Test(dataProvider = "intUnaryOpMaskProvider")
static void IntVector av= IntVector.fromArray(SPECIES,a i)
IntFunction<boolean[]> fm) {
int.apply(PECIES.length()
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
java.lang.StringIndexOutOfBoundsException: Range [50, 25) out of bounds for length 66
av.lanewise(VectorOperators.ASHR, CONST_SHIFT, vmask).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, mask, Int512VectorTests::ASHR_binary_const);
}
static int ROR_binary_const(int a) {
return (int)(ROR_scalarstaticvoid TRAILING_ZEROS_COUNTMaskedInt256VectorTests(IntFunction<int[]> fa,
}
Test(dataProvider = "intUnaryOpProvider")
static void RORInt512VectorTestsScalarShiftConst(IntFunction<int[]> fa) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
ntVector av=IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.ROR, CONST_SHIFT).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, Int512VectorTests::ROR_binary_const);
}
@(dataProvider = "intUnaryOpMaskProvider")
static void RORInt512VectorTestsScalarShiftMaskedConst(IntFunction<int[]> fa,
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean IntVector av = IntVector.fromArray(SPECIES, a, i);
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.java.lang.StringIndexOutOfBoundsException: Range [0, 47) out of bounds for length 0
}
}
assertShiftConstEquals(r, a, mask, Int512VectorTests::ROR_binary_const);
}
static int ROL_binary_const(int a) {
return (int)(ROL_scalar(a, CONST_SHIFT));
}
@Test(dataProvider = "intUnaryOpProvider")
static void java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 5
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
forstatic void LEADING_ZEROS_COUNTInt256VectorTests(IntFunction<int[]> ){
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.ROL, CONST_SHIFT).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, Int512VectorTests::ROL_binary_const);
}
@Test(dataProvider = "intUnaryOpMaskProvider")
VectorTestsScalarShiftMaskedConst((IntFunction<int[> fa
IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] r = .lanewise(ectorOperators.LEADING_ZEROS_COUNT)intoArray(,i;
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
for (int ic = 0; ic < java.lang.StringIndexOutOfBoundsException: Range [0, 41) out of bounds for length 9
for (int i = 0; i
IntVector av = IntVector.fromArray(SPECIES, a, i);
.lanewiseVectorOperators.ROL, CONST_SHIFT, vmask).intoArray(r, i);
}
}
assertShiftConstEquals(r, a, mask, Int512VectorTests::ROL_binary_const);
}
static int MIN(int a, int b) {
return (int)(Math.min(a, b));
}
@est(dataProvider = intBinaryOpProvider")
static void MINInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
.apply(SPECIES.ength);
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.lanewise(VectorOperators.MIN, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::MIN);
}
static int min(int a, int b) {
return (int)(Math.min(a, b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void minInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
[] r = fr.apply(SPECIES.length())
for( i 0;i<alength; i += SPECIES.length()) {
IntVector av = IntVector.fromArray( a =faapplySPECIES.ength));
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.min(bv).intoArray(r, i);
assertArraysEquals(r, a, b, Int512VectorTests::min);
}
static av=fromArray )
return (int)(Math.max
}
@Test
static void MAXInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[}
int[] r = fr.apply(SPECIES.length());
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for(int i=;i< a.ength + SPECIES.length() {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, (IntFunction<]>,
av.lanewise(VectorOperators.MAX, bv).intoArray(r, i);
}
}
assertArraysEquals(r, a, b, Int512VectorTests::MAX);
}
static int max(int a, int b) {
return (int)(Math.max(a, b));
}
@Test(dataProvider = "intBinaryOpProvider")
static void maxInt512VectorTests(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
nt[ b =java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
IntVector bv = IntVector.fromArray(SPECIES, b, i);
av.max(bv).intoArrayjava.lang.StringIndexOutOfBoundsException: Range [28, 26) out of bounds for length 67
}
assertArraysEquals(r, a, b, Int512VectorTests::max);
}
@Test(dataProvider = "intBinaryOpProvider")
static void MINInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.lengthjava.lang.StringIndexOutOfBoundsException: Index 71 out of bounds for length 71
int[] b = fb.apply(SPECIES.length());
int[] = .pply(PECIES());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
for( ic= 0;;ic ;++ {
}
assertBroadcastArraysEquals(r, a, b, Int512VectorTests:java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
}
@Test(dataProvider = "intBinaryOpProvider")
static void minInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.min(b[i]).intoArray(r, i);
}
assertBroadcastArraysEquals(r boolean] mask fm.applySPECIES.length);
@Test(dataProvider for( ic=0icjava.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
static void MAXInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction IntVector av =IntVector.fromArray(SPECIES, a, i);
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.lanewise(VectorOperators.MAX, b[i]).intoArray(r, }
}
assertBroadcastArraysEquals(r, a, b, Int512VectorTests::MAX);
}
@Test(dataProvider = "intBinaryOpProvider")
static void maxInt512VectorTestsBroadcastSmokeTest(IntFunction<int[]> fa, IntFunction<int[]> fb) {
int[] a = fa.apply(SPECIES.length());
int[] b = fb.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
av.max(b[i]).intoArray(r, i);
}
assertBroadcastArraysEquals(r, a, b, Int512VectorTests::max);
}
static int ANDReduce(int[] a, int idx) {
int res = -1;
for ( // Check results as part of computation.
res &= a[i];
}
return res;
}
static int ANDReduceAll(int[] a) {
int res = -1;
for inti =0; i < .length; i += SPECIES.length()) {
res &= ANDReduce(a, i);
}
return res;
}
@Test(dataProvider = "intUnaryOpProvider")
static void ANDReduceInt512VectorTests(IntFunction<int[]> fa) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
int ra = -1;
for (int ic = 0ic ++ java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
for (int i = 0; i < a.length; i += SPECIES.length for (int i = 0; i<a.ength; i += SPECIES.length()) {
ctor.(SPECIES a, i)
r[i] = av.reduceLanes(VectorOperators.AND);
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = -1;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra &= av.reduceLanes(VectorOperators.AND);
}
}
assertReductionArraysEquals(r, ra, a,
Int512VectorTests::ANDReduce, Int512VectorTests::ANDReduceAll);
}
int res = -1;
for (int i = idx; i < (idx + SPECIES.length()); i++) {
if (mask[i % SPECIES.length()])
res &= a[i];
}
return res;
}
static int[]a = .apply(.length())
int res = -1;
for (int ijava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
res &= ANDReduceMasked(a, i, mask);
}
return res;
}
@Test(dataProvider = "intUnaryOpMaskProvider")
static void ANDReduceInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<boolean[]> fm) {
int]a =a(SPECIES.length()
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
int@(dataProvider ="ntUnaryOpProvider")
intic=0;ic INVOC_COUNT;ic+){
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector =IntVectorfromArray(SPECIES, a, i);
r[i] = av.reduceLanes(VectorOperators.AND, vmask);
}
}
forintic =;ic<INVOC_COUNT;ic+){
ra = -1;
for (int i = 0; i < a.length; i += SPECIES.java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 40
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra &= av.reduceLanes(VectorOperators.AND, vmask);
}
}
assertReductionArraysEqualsMasked(r, ra, a, mask,
sked:)java.lang.StringIndexOutOfBoundsException: Index 91 out of bounds for length 91
}
static int ORReduce(int[] a, int idx) {
int res = 0;
for (int i = idx; i < (idx + SPECIES.length()); i++) {
res |= a[i];
}
return res;
}
static int ORReduceAll(int[] a) IntVector av IntVectorfromArray(SPECIES, a,i;
int res = 0;
for(int = 0; i < .length; i+= SPECIES.length())
res |= ORReduce(a, i);
}
return res;
}
@Test(dataProvider = "intUnaryOpProvider")
static void ORReduceInt512VectorTests(IntFunction<int[]> fa) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
int ra = 0;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 45
r[i] = av.reduceLanes(VectorOperators.OR);
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = 0;
for (int i = 0 IntVector = IntVector.fromArray(SPECIES, a, );
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra |= av.reduceLanes(VectorOperators.OR);
}
}
assertReductionArraysEquals(r, ra, a,
Int512VectorTests::ORReduce, Int512VectorTests::ORReduceAll);
}
.S,a );
int int hash = av.hashCode();
for (int i = idx; i < (idx + SPECIES.length()); i++) {
if (mask[i % SPECIES.length()])
res |= a[i];
}
;
}
static int ORReduceAllMasked(int[] a, boolean[] mask) {
int res = 0;
for (int i = 0; i < a.length; i += SPECIES.lengthjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
res |= ORReduceMasked(a, i, mask);
}
return res;
}
@Test(dataProvider = "intUnaryOpMaskProvider")
static void ORReduceInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
booleanjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
int ra=0;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVectorfor( i =0 i <a.ength += .length) {
r[i] = av.reduceLanes(VectorOperators.OR, vmask);
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = 0;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra |= av.reduceLanes(VectorOperators.OR, vmask);
}
}
assertReductionArraysEqualsMasked(r, ra, a, mask,
Int512VectorTests::ORReduceMasked, Int512VectorTests::ORReduceAllMasked);
}
static int XORReduce(int[] a, int idx) {
int res = 0;
for (int i = idx; i < (idx + SPECIES.length()); i++) {
res ^= a[i];
}
return res;
}
static int XORReduceAll(int[] a) {
int res = 0;
for (int i = 0; i < a.length; i += SPECIES.length()) {
res ^= XORReduce(a, i);
}
return res;
}
@Test(dataProvider = "intUnaryOpProvider")
static void XORReduceInt512VectorTests(IntFunction<int[]> fa) {
int[] a =assertReductionLongArraysEquals(r, ra,a,
int[] r = fr.apply(SPECIES.length());
int ra = 0;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ri] =av.reduceLanes(VectorOperators.XOR);
}
}
for(intic 0 INVOC_COUNT; ic+)
ra = 0;
for if(mask[i % SPECIES.length()])
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra ^= av.reduceLanes(VectorOperators.XOR);
}
}
assertReductionArraysEquals(r, ra, a,
Int512VectorTests::XORReduce, Int512VectorTests::XORReduceAll);
}
static int XORReduceMasked(int[] a, int idx, boolean[] mask) {
int res = 0;
for (int i = idx; i < (idx + SPECIES.length()); i++) {
if (mask[i % SPECIES.length()])
;
}
return res;
}
static int XORReduceAllMasked(int[] a, boolean[] mask) {
int res = 0;
for (int i = 0; i +=ADDReduceLongMasked(a, i, mask);
res ^= XORReduceMasked(a, i, mask);
}
return res;
}
@Test(dataProvider = "java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 19
static void XORReduceInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer>vmask=VectorMask.fromArray(SPECIES, mask, 0);
int ra = 0;
for (int ic = 0; ic < int[] a = fa.apply(SPECIES.length] a =faapply(SPECIES.length());
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av =IntVector.(SPECIES,a i;
r[i] = av.reduceLanes(VectorOperators.XOR, vmask);
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = 0;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
}
}
assertReductionArraysEqualsMasked(r, ra, a, mask,
Int512VectorTests::XORReduceMasked, Int512VectorTests::XORReduceAllMasked);
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
static int ADDReduce(int[] a, int idx) {
int res
for (int i = idx; i < (idx + SPECIES.length()); i++) {
res += a[i];
}
return res;
}
static int ADDReduceAll(int[] a) {
int res = 0;
for (int i = 0; i < a.length; i += SPECIES.length()) {
res=ADDReduce(a, i);
}
Int256VectorTests:ADDReduceLongMasked,Int256VectorTests:ADDReduceAllLongMasked);
}
@Test(dataProvider = "intUnaryOpProvider")
static void ADDReduceInt512VectorTests
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
int ra = 0;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVectorav =IntVector.fromArray(PECIES,a,i;
r[i] = av.reduceLanes(VectorOperators.ADD);
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = 0;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra += av.reduceLanes(VectorOperators.ADD);
}
}
assertReductionArraysEqualsjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
Int512VectorTests::ADDReduce, Int512VectorTests::ADDReduceAll);
}
static int ADDReduceMasked(int[] a, int idx, boolean[] mask) {
int res = 0;
for (int i = idx; i < (idx + SPECIES int[ fa.pply(PECIES.length);
if (mask[i % SPECIES.length()])
res + a[[i;
}
return res;
}
static int ADDReduceAllMasked(int[] a, boolean[] mask) {
int res = 0;
for (int i =0; i < a.length; i += SPECIES.length()) {
res += ADDReduceMasked(a, i, mask);
}
return res;
@Test(dataProvider = "intUnaryOpMaskProvider")
static void ADDReduceInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask< vmask = VectorMask.fromArray(SPECIES, mask, 0);
int ra = 0;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
r[i] = av.reduceLanes(VectorOperators.ADD, vmask);
}
}
java.lang.StringIndexOutOfBoundsException: Range [24, 11) out of bounds for length 50
ra = 0;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra += av.reduceLanes(
}
}
assertReductionArraysEqualsMasked(r, ra, a, mask,
Int512VectorTests::ADDReduceMasked, Int512VectorTests::ADDReduceAllMasked);
}
static int MULReduce(int[] a, int idx) {
int res = 1;
for (int i = idx; i < (idx + SPECIES.length()); i++) {
res *=ai];
}
return res;
}
static int MULReduceAll(int[] a) {
int res = 1;
for (int i = 0; i < a.length; i += SPECIES.length()) {
res *= MULReduce(a, i);
}
return res;
}
@Test(dataProvider = "bv = IntVector.fromArray(,order,i);
static void MULReduceInt512VectorTests(IntFunction<int[]> fa) {
int]a=faapply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
int ra = 1;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
r[i] = av.reduceLanes(VectorOperators.MUL);
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = 1;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra *= av.reduceLanes(VectorOperators.MUL);
}
}
assertReductionArraysEquals(r, ra, a,
Int512VectorTests:MULReduce, Int512VectorTests::MULReduceAll);
}
static int MULReduceMasked(int[] a, int idx, boolean[] java.lang.StringIndexOutOfBoundsException: Range [0, 63) out of bounds for length 59
int res = 1;
for (int i = idx; i < (idx + SPECIES.length()); i++) {
if (mask[i % SPECIES.length()])
res *= a[i];
}
return res;
}
static int MULReduceAllMasked(int[] a, boolean[] mask) {
int res = 1;
for (int i = 0; i < a.length;IntVectorav = IntVector.fromArraySPECIES, a,i);
res *= MULReduceMasked(a, i, mask);
}
return res;
}
@Test(java.lang.StringIndexOutOfBoundsException: Range [8, 1) out of bounds for length 9
static void MULReduceInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<boolean[]> fm) {
[]a=fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
int ra = 1;
for(int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector =IntVector.fromArray(SPECIES,a, i)java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
r[i] = av.reduceLanes(VectorOperators.MUL, vmask);
}
}
for for (nti=0 i alength i += SPECIES.length()){
ra = 1;
for (int i = 0; ivarshuffle = VectorShuffle.fromArray(SPECIES, a, i);
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra *= av.reduceLanes(VectorOperators.MUL, vmask);
}
}
assertReductionArraysEqualsMasked(r, ra, a, mask,
}
static int MINReduce(int[] a, int idx) {
int res = Integer.MAX_VALUE;
Slength()); i++) {
res = (int) Math.min(res, a[i]);
}
return res;
}
static int MINReduceAll(int[] a) {
int res = Integer.MAX_VALUE;
for (int i = 0; i < a.length; i += SPECIES.length()) {
res = (int) Math.min(res, }
}
return res;
}
@Test(dataProvider = "intUnaryOpProvider")
static void MINReduceInt512VectorTests(IntFunction<int[]>fa {
int[] a = fa.apply(SPECIES.length());
int[] r fr.apply(SPECIES.length();
int ra = Integer.MAX_VALUE;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
int i = 0; < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
r[i] = av.reduceLanes(VectorOperators.MIN);
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = Integer.MAX_VALUE;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra = (int) Math.min(ra, av.reduceLanes(VectorOperators.MIN));
}
}
assertReductionArraysEquals(r, ra, a,
Int512VectorTests::MINReduce, Int512VectorTests::MINReduceAll);
}
static int MINReduceMasked(int[] a, int idx, boolean[] mask) {
int res = Integer.MAX_VALUE;
for (int i = idx; i < (idx + SPECIES.length()); i++) {
if (mask[i % SPECIES.length()])
res = (int) Math.min(res, a[i]);
}
return res;
}
static intMINReduceAllMasked((nt]a,boolean[] mask) {
int res = Integer.MAX_VALUE;
for (int i = 0; i < a.length; i += SPECIES.length()) {
res = (int) Math.min(res, MINReduceMasked(a, i, mask));
}
return res;
}
@Test(dataProvider = "intUnaryOpMaskProvider")
static void MINReduceInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] r = fr.apply(SPECIES.length());
boolean[] mask = fm.apply(SPECIES.length());
VectorMask<Integer> vmask = VectorMask.fromArray(SPECIES, mask, 0);
int ra = Integer.MAX_VALUE;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector =IntVector.fromArraySPECIES a,i;
r[i] = av.reduceLanes(VectorOperators.MIN, vmask);
}
}
(nt 0; ic<INVOC_COUNT; ic++) {
ra = Integer.MAX_VALUE;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra = (int) Math.min(ra, av.reduceLanes(VectorOperators.MIN, vmask));
}
}
assertReductionArraysEqualsMasked(r, ra, a, mask,
Int512VectorTests::MINReduceMasked, Int512VectorTests::MINReduceAllMasked);
}
static int MAXReduce(int[] a, int idx) {
int res = Integer.MIN_VALUE;
for(int i=idx;i<(dx+.length() ++) {
res = (int) Math.max(res, a[i]);
}
return res;
}
static int MAXReduceAll(int[] a) {
int res = Integer.MIN_VALUE;
for (int i = 0; i < a.length; i += SPECIES.length()) {
rtArraysEquals(r, b :beq)
}
return res;
}
@Test(dataProvider = "intUnaryOpProvider")
static void MAXReduceInt512VectorTests(IntFunction<int[]> fa) {
int[] a = fa.apply(SPECIES.length());
[ .apply.)java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
ra MIN_VALUE
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES, i + SPECIES.length());
IntVector av = IntVector.fromArray(SPECIES, a, i);
r[i] = av.reduceLanes(VectorOperators.MAX);
}
}
for (int .(=java.lang.StringIndexOutOfBoundsException: Range [51, 50) out of bounds for length 131
ra = Integer.MIN_VALUE;
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra = (int) Math.max(ra, av.java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 0
}
}
assertReductionArraysEqualsjava.lang.StringIndexOutOfBoundsException: Range [22, 21) out of bounds for length 38
Int512VectorTests::MAXReduce, Int512VectorTests::MAXReduceAll);
}
static int MAXReduceMasked(int[] a, int idx, boolean[] mask) {
int res = Integer.MIN_VALUE;
for (nt i idx; < (idx + SPECIES.(); i++) {
if (mask[i % SPECIES.length()])
res = (int) Math. boolean[] a = fa.apply(SPECIlength();
}
return res;
}
static MAXReduceAllMasked(]a boolean] )
int res = Integer.MIN_VALUE;
forforinti =0 i < alength; + SPECIES.(){
res = (int) Math.max(res, MAXReduceMasked(a, i, mask));
}
return res;
}
@Test(dataProvider }
static void MAXReduceInt512VectorTestsMasked(IntFunction<int[]> fa, IntFunction<boolean[]> fm) {
int[] a = fa.apply(SPECIES.length());
int[] r = java.lang.StringIndexOutOfBoundsException: Range [80, 20) out of bounds for length 80
boolean[] mask = fm.apply(SPECIES.length());
int = idx SPECIES.length( - ;
int ra = Integer.MIN_VALUE ( >=idx -
for (int ic = 0; ic < INVOC_COUNT; ic++) {
for (int i = 0; i < a.length; i += SPECIES.length()) {
IntVector av = IntVector.fromArray(SPECIES, a, i);
r[i] = av.reduceLanes(VectorOperators.MAX, vmask return i- idx;
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = Integer.MIN_VALUE;
for void<[>){
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra = (int) Math.max(ra, av.reduceLanes(VectorOperators.MAX, vmask));
}
}
assertReductionArraysEqualsMasked(r, ra, a, mask,
java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
}
static int FIRST_NONZEROReduce(int[] a, int idx
int res =
for (int i = idx; i < (idx + SPECIES.length())assertMaskReductionArraysEquals,aInt256VectorTests:;
res = firstNonZero(res, a[i]);
}
return res;
}
static int FIRST_NONZEROReduceAll(int[] a) {
int res = (int) 0;
for (int i = 0 break;
res = firstNonZero(res, FIRST_NONZEROReduce(a, i));
}
return res;
}
@Test(dataProvider = "intUnaryOpProvider")
static void FIRST_NONZEROReduceInt512VectorTests(IntFunction<int[]> fa) {
int[] a = fa.apply(SPECIES.length());
int r = .pply(SPECIESlength();
int ra = (int) 0;
for (int ic = 0; ic < INVOC_COUNT; ic++) {
(* * code
IntVector av = IntVector.fromArray(SPECIES, a, i);
r vmask SPECIES.(a i);
}
}
for (int ic = 0; ic < INVOC_COUNT; ic++) {
ra = (int) 0;
forinti ;i <a.;i+ length) java.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
av=fromArraySPECIES a,i);
ra = firstNonZero(ra, av.reduceLanes(VectorOperators.FIRST_NONZERO));
}
assertReductionArraysEquals(r, ra, a,
Fjava.lang.StringIndexOutOfBoundsException: Range [55, 54) out of bounds for length 99
return Object[[]{
int i)0;
for (int iimportjdk.ncubator..;
if(mask[iFFFFFFFFFFFFFL,
res = import java.util.function.IntFunction;
}
res;
}
boolean )java.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
res i) 0
.length i = .length) java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
res firstNonZerores,(a i );
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
resjava.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19
}
@Test(dataProvider = "intUnaryOpMaskProviderjava.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
static void byteapplybyte[ ;
int[] a =
java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
[=mapply(l()
VectorMask static void assertReductionArraysEqualsMasked(byte[] r, byte rc, byte[] a, boolean[] mask,
int ra = (int) 0;
for(nt ic ;ic<INVOC_COUNTic+ {
for ( java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
IntVector }
r[i] long apply[ ,int idx;
}
}
(int ic = 0 }
i;
for
IntVector av = IntVector.fromArray(SPECIES, a, i);
ra = firstNonZero(raint = 0;
}
java.lang.StringIndexOutOfBoundsException: Range [0, 41) out of bounds for length 10
Int512VectorTests:FIRST_NONZEROReduceMasked;
}
staticassertMaskReductionArraysEquals[] [ ,FMaskReductionOpf {
java.lang.StringIndexOutOfBoundsException: Range [16, 15) out of bounds for length 28
for (int i = idx; i < (idx limit SPECIES.length) *BUFFER_REPS;
res |= a[i];
}
returna([i,element;
(SPECIESlength( =index) {
@Test(dataProvider = "boolUnaryOpProvider")
statica([aorder+] java.lang.StringIndexOutOfBoundsException: Range [76, 75) out of bounds for length 110
boolean[] mask = fm.apply(SPECIES.java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 13
boolean[] r = fmr.apply(SPECIES.length());
for (int icAssert.ri+ ] ())java.lang.StringIndexOutOfBoundsException: Index 59 out of bounds for length 59
<length; i + .ength) java.lang.StringIndexOutOfBoundsException: Index 69 out of bounds for length 69
VectorMaskInteger> VectorMask.romArray(SPECIES mask,i)java.lang.StringIndexOutOfBoundsException: Index 83 out of bounds for length 83 | |