Home
last modified time | relevance | path

Searched refs:compareAndExchangeRelease (Results 1 – 25 of 46) sorted by relevance

12

/libcore/luni/src/test/java/libcore/java/util/concurrent/
DAtomicBooleanTest.java75 assertEquals(true, val.compareAndExchangeRelease(expected, newValue)); in testCompareAndExchangeRelease()
77 assertEquals(true, val.compareAndExchangeRelease(expected, newValue)); in testCompareAndExchangeRelease()
80 assertEquals(true, val.compareAndExchangeRelease(expected, newValue)); in testCompareAndExchangeRelease()
82 assertEquals(false, val.compareAndExchangeRelease(expected, newValue)); in testCompareAndExchangeRelease()
86 assertEquals(false, val.compareAndExchangeRelease(expected, newValue)); in testCompareAndExchangeRelease()
DAtomicLongTest.java59 assertEquals(42, val.compareAndExchangeRelease(0, 1)); in testCompareAndExchangeRelease()
61 assertEquals(42, val.compareAndExchangeRelease(42, 1)); in testCompareAndExchangeRelease()
63 assertEquals(1, val.compareAndExchangeRelease(1, -1)); in testCompareAndExchangeRelease()
65 assertEquals(-1, val.compareAndExchangeRelease(42, 0)); in testCompareAndExchangeRelease()
DAtomicIntegerTest.java59 assertEquals(42, val.compareAndExchangeRelease(0, 1)); in testCompareAndExchangeRelease()
61 assertEquals(42, val.compareAndExchangeRelease(42, 1)); in testCompareAndExchangeRelease()
63 assertEquals(1, val.compareAndExchangeRelease(1, -1)); in testCompareAndExchangeRelease()
65 assertEquals(-1, val.compareAndExchangeRelease(42, 0)); in testCompareAndExchangeRelease()
DAtomicLongArrayTest.java92 assertEquals(expectedArray[i], arr.compareAndExchangeRelease(i, 0, i+1)); in testCompareAndExchangeRelease()
95 assertEquals(expectedArray[i], arr.compareAndExchangeRelease(i, expectedArray[i], i+1)); in testCompareAndExchangeRelease()
100 assertEquals(i+1, arr.compareAndExchangeRelease(i, i+1, -1)); in testCompareAndExchangeRelease()
105 assertEquals(-1, arr.compareAndExchangeRelease(i, -1, i*2)); in testCompareAndExchangeRelease()
DAtomicIntegerArrayTest.java92 assertEquals(expectedArray[i], arr.compareAndExchangeRelease(i, 0, i+1)); in testCompareAndExchangeRelease()
95 assertEquals(expectedArray[i], arr.compareAndExchangeRelease(i, expectedArray[i], i+1)); in testCompareAndExchangeRelease()
100 assertEquals(i+1, arr.compareAndExchangeRelease(i, i+1, -1)); in testCompareAndExchangeRelease()
105 assertEquals(-1, arr.compareAndExchangeRelease(i, -1, i*2)); in testCompareAndExchangeRelease()
DAtomicReferenceTest.java128 Integer result = val.compareAndExchangeRelease(notCurrent, newValue); in testCompareAndExchangeRelease()
135 result = val.compareAndExchangeRelease(notCurrent, newValue); in testCompareAndExchangeRelease()
141 result = val.compareAndExchangeRelease(currentValue, newValue); in testCompareAndExchangeRelease()
151 result = val.compareAndExchangeRelease(notCurrent, newValue); in testCompareAndExchangeRelease()
158 result = val.compareAndExchangeRelease(currentValue, newValue); in testCompareAndExchangeRelease()
/libcore/ojluni/src/test/java/lang/invoke/VarHandles/
DVarHandleTestMethodTypeFloat.java529 float x = (float) vh.compareAndExchangeRelease(null, 1.0f, 1.0f); in testInstanceFieldWrongMethodType()
532 float x = (float) vh.compareAndExchangeRelease(Void.class, 1.0f, 1.0f); in testInstanceFieldWrongMethodType()
535 float x = (float) vh.compareAndExchangeRelease(recv, Void.class, 1.0f); in testInstanceFieldWrongMethodType()
538 float x = (float) vh.compareAndExchangeRelease(recv, 1.0f, Void.class); in testInstanceFieldWrongMethodType()
541 float x = (float) vh.compareAndExchangeRelease(0, 1.0f, 1.0f); in testInstanceFieldWrongMethodType()
545 Void r = (Void) vh.compareAndExchangeRelease(recv, 1.0f, 1.0f); in testInstanceFieldWrongMethodType()
548 boolean x = (boolean) vh.compareAndExchangeRelease(recv, 1.0f, 1.0f); in testInstanceFieldWrongMethodType()
552 float x = (float) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 float x = (float) vh.compareAndExchangeRelease(recv, 1.0f, 1.0f, Void.class); in testInstanceFieldWrongMethodType()
1196 float x = (float) vh.compareAndExchangeRelease(Void.class, 1.0f); in testStaticFieldWrongMethodType()
[all …]
DVarHandleTestMethodTypeDouble.java529 double x = (double) vh.compareAndExchangeRelease(null, 1.0d, 1.0d); in testInstanceFieldWrongMethodType()
532 double x = (double) vh.compareAndExchangeRelease(Void.class, 1.0d, 1.0d); in testInstanceFieldWrongMethodType()
535 double x = (double) vh.compareAndExchangeRelease(recv, Void.class, 1.0d); in testInstanceFieldWrongMethodType()
538 double x = (double) vh.compareAndExchangeRelease(recv, 1.0d, Void.class); in testInstanceFieldWrongMethodType()
541 double x = (double) vh.compareAndExchangeRelease(0, 1.0d, 1.0d); in testInstanceFieldWrongMethodType()
545 Void r = (Void) vh.compareAndExchangeRelease(recv, 1.0d, 1.0d); in testInstanceFieldWrongMethodType()
548 boolean x = (boolean) vh.compareAndExchangeRelease(recv, 1.0d, 1.0d); in testInstanceFieldWrongMethodType()
552 double x = (double) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 double x = (double) vh.compareAndExchangeRelease(recv, 1.0d, 1.0d, Void.class); in testInstanceFieldWrongMethodType()
1196 double x = (double) vh.compareAndExchangeRelease(Void.class, 1.0d); in testStaticFieldWrongMethodType()
[all …]
DVarHandleTestMethodTypeString.java529 String x = (String) vh.compareAndExchangeRelease(null, "foo", "foo"); in testInstanceFieldWrongMethodType()
532 String x = (String) vh.compareAndExchangeRelease(Void.class, "foo", "foo"); in testInstanceFieldWrongMethodType()
535 String x = (String) vh.compareAndExchangeRelease(recv, Void.class, "foo"); in testInstanceFieldWrongMethodType()
538 String x = (String) vh.compareAndExchangeRelease(recv, "foo", Void.class); in testInstanceFieldWrongMethodType()
541 String x = (String) vh.compareAndExchangeRelease(0, "foo", "foo"); in testInstanceFieldWrongMethodType()
545 Void r = (Void) vh.compareAndExchangeRelease(recv, "foo", "foo"); in testInstanceFieldWrongMethodType()
548 boolean x = (boolean) vh.compareAndExchangeRelease(recv, "foo", "foo"); in testInstanceFieldWrongMethodType()
552 String x = (String) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 String x = (String) vh.compareAndExchangeRelease(recv, "foo", "foo", Void.class); in testInstanceFieldWrongMethodType()
1074 String x = (String) vh.compareAndExchangeRelease(Void.class, "foo"); in testStaticFieldWrongMethodType()
[all …]
DVarHandleTestMethodTypeBoolean.java529 boolean x = (boolean) vh.compareAndExchangeRelease(null, true, true); in testInstanceFieldWrongMethodType()
532 boolean x = (boolean) vh.compareAndExchangeRelease(Void.class, true, true); in testInstanceFieldWrongMethodType()
535 boolean x = (boolean) vh.compareAndExchangeRelease(recv, Void.class, true); in testInstanceFieldWrongMethodType()
538 boolean x = (boolean) vh.compareAndExchangeRelease(recv, true, Void.class); in testInstanceFieldWrongMethodType()
541 boolean x = (boolean) vh.compareAndExchangeRelease(0, true, true); in testInstanceFieldWrongMethodType()
545 Void r = (Void) vh.compareAndExchangeRelease(recv, true, true); in testInstanceFieldWrongMethodType()
548 int x = (int) vh.compareAndExchangeRelease(recv, true, true); in testInstanceFieldWrongMethodType()
552 boolean x = (boolean) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 boolean x = (boolean) vh.compareAndExchangeRelease(recv, true, true, Void.class); in testInstanceFieldWrongMethodType()
1378 boolean x = (boolean) vh.compareAndExchangeRelease(Void.class, true); in testStaticFieldWrongMethodType()
[all …]
DVarHandleTestMethodTypeByte.java529 byte x = (byte) vh.compareAndExchangeRelease(null, (byte)0x01, (byte)0x01); in testInstanceFieldWrongMethodType()
532 byte x = (byte) vh.compareAndExchangeRelease(Void.class, (byte)0x01, (byte)0x01); in testInstanceFieldWrongMethodType()
535 byte x = (byte) vh.compareAndExchangeRelease(recv, Void.class, (byte)0x01); in testInstanceFieldWrongMethodType()
538 byte x = (byte) vh.compareAndExchangeRelease(recv, (byte)0x01, Void.class); in testInstanceFieldWrongMethodType()
541 byte x = (byte) vh.compareAndExchangeRelease(0, (byte)0x01, (byte)0x01); in testInstanceFieldWrongMethodType()
545 Void r = (Void) vh.compareAndExchangeRelease(recv, (byte)0x01, (byte)0x01); in testInstanceFieldWrongMethodType()
548 boolean x = (boolean) vh.compareAndExchangeRelease(recv, (byte)0x01, (byte)0x01); in testInstanceFieldWrongMethodType()
552 byte x = (byte) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 byte x = (byte) vh.compareAndExchangeRelease(recv, (byte)0x01, (byte)0x01, Void.class); in testInstanceFieldWrongMethodType()
1500 byte x = (byte) vh.compareAndExchangeRelease(Void.class, (byte)0x01); in testStaticFieldWrongMethodType()
[all …]
DVarHandleTestMethodTypeChar.java529 char x = (char) vh.compareAndExchangeRelease(null, '\u0123', '\u0123'); in testInstanceFieldWrongMethodType()
532 char x = (char) vh.compareAndExchangeRelease(Void.class, '\u0123', '\u0123'); in testInstanceFieldWrongMethodType()
535 char x = (char) vh.compareAndExchangeRelease(recv, Void.class, '\u0123'); in testInstanceFieldWrongMethodType()
538 char x = (char) vh.compareAndExchangeRelease(recv, '\u0123', Void.class); in testInstanceFieldWrongMethodType()
541 char x = (char) vh.compareAndExchangeRelease(0, '\u0123', '\u0123'); in testInstanceFieldWrongMethodType()
545 Void r = (Void) vh.compareAndExchangeRelease(recv, '\u0123', '\u0123'); in testInstanceFieldWrongMethodType()
548 boolean x = (boolean) vh.compareAndExchangeRelease(recv, '\u0123', '\u0123'); in testInstanceFieldWrongMethodType()
552 char x = (char) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 char x = (char) vh.compareAndExchangeRelease(recv, '\u0123', '\u0123', Void.class); in testInstanceFieldWrongMethodType()
1500 char x = (char) vh.compareAndExchangeRelease(Void.class, '\u0123'); in testStaticFieldWrongMethodType()
[all …]
DVarHandleTestMethodTypeShort.java529 short x = (short) vh.compareAndExchangeRelease(null, (short)0x0123, (short)0x0123); in testInstanceFieldWrongMethodType()
532 … short x = (short) vh.compareAndExchangeRelease(Void.class, (short)0x0123, (short)0x0123); in testInstanceFieldWrongMethodType()
535 short x = (short) vh.compareAndExchangeRelease(recv, Void.class, (short)0x0123); in testInstanceFieldWrongMethodType()
538 short x = (short) vh.compareAndExchangeRelease(recv, (short)0x0123, Void.class); in testInstanceFieldWrongMethodType()
541 short x = (short) vh.compareAndExchangeRelease(0, (short)0x0123, (short)0x0123); in testInstanceFieldWrongMethodType()
545 Void r = (Void) vh.compareAndExchangeRelease(recv, (short)0x0123, (short)0x0123); in testInstanceFieldWrongMethodType()
548 boolean x = (boolean) vh.compareAndExchangeRelease(recv, (short)0x0123, (short)0x0123); in testInstanceFieldWrongMethodType()
552 short x = (short) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 … short x = (short) vh.compareAndExchangeRelease(recv, (short)0x0123, (short)0x0123, Void.class); in testInstanceFieldWrongMethodType()
1500 short x = (short) vh.compareAndExchangeRelease(Void.class, (short)0x0123); in testStaticFieldWrongMethodType()
[all …]
DVarHandleTestMethodTypeInt.java529 int x = (int) vh.compareAndExchangeRelease(null, 0x01234567, 0x01234567); in testInstanceFieldWrongMethodType()
532 int x = (int) vh.compareAndExchangeRelease(Void.class, 0x01234567, 0x01234567); in testInstanceFieldWrongMethodType()
535 int x = (int) vh.compareAndExchangeRelease(recv, Void.class, 0x01234567); in testInstanceFieldWrongMethodType()
538 int x = (int) vh.compareAndExchangeRelease(recv, 0x01234567, Void.class); in testInstanceFieldWrongMethodType()
541 int x = (int) vh.compareAndExchangeRelease(0, 0x01234567, 0x01234567); in testInstanceFieldWrongMethodType()
545 Void r = (Void) vh.compareAndExchangeRelease(recv, 0x01234567, 0x01234567); in testInstanceFieldWrongMethodType()
548 boolean x = (boolean) vh.compareAndExchangeRelease(recv, 0x01234567, 0x01234567); in testInstanceFieldWrongMethodType()
552 int x = (int) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 int x = (int) vh.compareAndExchangeRelease(recv, 0x01234567, 0x01234567, Void.class); in testInstanceFieldWrongMethodType()
1500 int x = (int) vh.compareAndExchangeRelease(Void.class, 0x01234567); in testStaticFieldWrongMethodType()
[all …]
DVarHandleTestMethodTypeLong.java529 … long x = (long) vh.compareAndExchangeRelease(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); in testInstanceFieldWrongMethodType()
532 …long x = (long) vh.compareAndExchangeRelease(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); in testInstanceFieldWrongMethodType()
535 long x = (long) vh.compareAndExchangeRelease(recv, Void.class, 0x0123456789ABCDEFL); in testInstanceFieldWrongMethodType()
538 long x = (long) vh.compareAndExchangeRelease(recv, 0x0123456789ABCDEFL, Void.class); in testInstanceFieldWrongMethodType()
541 … long x = (long) vh.compareAndExchangeRelease(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); in testInstanceFieldWrongMethodType()
545 … Void r = (Void) vh.compareAndExchangeRelease(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); in testInstanceFieldWrongMethodType()
548 …boolean x = (boolean) vh.compareAndExchangeRelease(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); in testInstanceFieldWrongMethodType()
552 long x = (long) vh.compareAndExchangeRelease(); in testInstanceFieldWrongMethodType()
555 …long x = (long) vh.compareAndExchangeRelease(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.… in testInstanceFieldWrongMethodType()
1500 long x = (long) vh.compareAndExchangeRelease(Void.class, 0x0123456789ABCDEFL); in testStaticFieldWrongMethodType()
[all …]
DX-VarHandleTestAccess.java.template340 $type$ r = ($type$) vh.compareAndExchangeRelease(recv, $value1$, $value2$);
484 $type$ r = ($type$) vh.compareAndExchangeRelease($value1$, $value2$);
647 $type$ r = ($type$) vh.compareAndExchangeRelease(recv, $value2$, $value1$);
648 assertEquals(r, $value2$, "success compareAndExchangeRelease $type$");
650 assertEquals(x, $value1$, "success compareAndExchangeRelease $type$ value");
654 $type$ r = ($type$) vh.compareAndExchangeRelease(recv, $value2$, $value3$);
655 assertEquals(r, $value1$, "failing compareAndExchangeRelease $type$");
657 assertEquals(x, $value1$, "failing compareAndExchangeRelease $type$ value");
861 $type$ r = ($type$) vh.compareAndExchangeRelease(recv, $value1$, $value2$);
1024 $type$ r = ($type$) vh.compareAndExchangeRelease($value2$, $value1$);
[all …]
DVarHandleTestByteArrayAsDouble.java254 double r = (double) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayNPE()
338 double r = (double) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayNPE()
465 double r = (double) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayUnsupported()
649 double r = (double) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayIndexOutOfBounds()
743 double r = (double) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayIndexOutOfBounds()
828 double r = (double) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayMisalignedAccess()
915 … double r = (double) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayMisalignedAccess()
1039 double r = (double) vh.compareAndExchangeRelease(array, i, VALUE_2, VALUE_1); in testArrayReadWrite()
1046 double r = (double) vh.compareAndExchangeRelease(array, i, VALUE_2, VALUE_3); in testArrayReadWrite()
1212 double r = (double) vh.compareAndExchangeRelease(array, i, VALUE_2, VALUE_1); in testArrayReadWrite()
[all …]
DVarHandleTestByteArrayAsFloat.java254 float r = (float) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayNPE()
338 float r = (float) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayNPE()
465 float r = (float) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayUnsupported()
649 float r = (float) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayIndexOutOfBounds()
743 float r = (float) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayIndexOutOfBounds()
828 float r = (float) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayMisalignedAccess()
915 float r = (float) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1); in testArrayMisalignedAccess()
1039 float r = (float) vh.compareAndExchangeRelease(array, i, VALUE_2, VALUE_1); in testArrayReadWrite()
1046 float r = (float) vh.compareAndExchangeRelease(array, i, VALUE_2, VALUE_3); in testArrayReadWrite()
1212 float r = (float) vh.compareAndExchangeRelease(array, i, VALUE_2, VALUE_1); in testArrayReadWrite()
[all …]
DX-VarHandleTestByteArrayView.java.template287 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
423 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
527 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
651 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
696 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
843 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
982 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
1128 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
1265 $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
1404 … $type$ r = ($type$) vh.compareAndExchangeRelease(array, ci, VALUE_2, VALUE_1);
[all …]
/libcore/ojluni/src/main/java/java/util/concurrent/atomic/
DAtomicBoolean.java303 public final boolean compareAndExchangeRelease(boolean expectedValue, boolean newValue) { in compareAndExchangeRelease() method in AtomicBoolean
304 return (int)VALUE.compareAndExchangeRelease(this, in compareAndExchangeRelease()
DAtomicLong.java568 public final long compareAndExchangeRelease(long expectedValue, long newValue) { in compareAndExchangeRelease() method in AtomicLong
571 return (long)VALUE.compareAndExchangeRelease(this, expectedValue, newValue); in compareAndExchangeRelease()
DAtomicInteger.java553 public final int compareAndExchangeRelease(int expectedValue, int newValue) { in compareAndExchangeRelease() method in AtomicInteger
556 return (int)VALUE.compareAndExchangeRelease(this, expectedValue, newValue); in compareAndExchangeRelease()
DAtomicReference.java392 public final V compareAndExchangeRelease(V expectedValue, V newValue) { in compareAndExchangeRelease() method in AtomicReference
393 return (V)VALUE.compareAndExchangeRelease(this, expectedValue, newValue); in compareAndExchangeRelease()
DAtomicLongArray.java513 public final long compareAndExchangeRelease(int i, long expectedValue, long newValue) { in compareAndExchangeRelease() method in AtomicLongArray
514 return (long)AA.compareAndExchangeRelease(array, i, expectedValue, newValue); in compareAndExchangeRelease()
DAtomicIntegerArray.java513 public final int compareAndExchangeRelease(int i, int expectedValue, int newValue) { in compareAndExchangeRelease() method in AtomicIntegerArray
514 return (int)AA.compareAndExchangeRelease(array, i, expectedValue, newValue); in compareAndExchangeRelease()

12