Home
last modified time | relevance | path

Searched refs:t2 (Results 1 – 25 of 39) sorted by relevance

12

/libcore/jsr166-tests/src/test/java/jsr166/
DCyclicBarrierTest.java137 Thread t2 = new ThreadShouldThrow(BrokenBarrierException.class) { in testAwait1_Interrupted_BrokenBarrier() local
144 t2.start(); in testAwait1_Interrupted_BrokenBarrier()
148 awaitTermination(t2); in testAwait1_Interrupted_BrokenBarrier()
163 Thread t2 = new ThreadShouldThrow(BrokenBarrierException.class) { in testAwait2_Interrupted_BrokenBarrier() local
170 t2.start(); in testAwait2_Interrupted_BrokenBarrier()
174 awaitTermination(t2); in testAwait2_Interrupted_BrokenBarrier()
208 Thread t2 = newStartedThread(new CheckedRunnable() { in testAwait4_Timeout_BrokenBarrier() local
220 awaitTermination(t2); in testAwait4_Timeout_BrokenBarrier()
236 Thread t2 = newStartedThread(new CheckedRunnable() { in testAwait5_Timeout_BrokenBarrier() local
248 awaitTermination(t2); in testAwait5_Timeout_BrokenBarrier()
[all …]
DAbstractQueuedLongSynchronizerTest.java313 Thread t2 = newStartedThread(new InterruptibleSyncRunnable(sync)); in testHasQueuedThreads() local
314 waitForQueuedThread(sync, t2); in testHasQueuedThreads()
320 awaitTermination(t2); in testHasQueuedThreads()
341 Thread t2 = new Thread(new InterruptibleSyncRunnable(sync)); in testIsQueued() local
343 assertFalse(sync.isQueued(t2)); in testIsQueued()
348 assertFalse(sync.isQueued(t2)); in testIsQueued()
349 t2.start(); in testIsQueued()
350 waitForQueuedThread(sync, t2); in testIsQueued()
352 assertTrue(sync.isQueued(t2)); in testIsQueued()
356 assertTrue(sync.isQueued(t2)); in testIsQueued()
[all …]
DAbstractQueuedSynchronizerTest.java316 Thread t2 = newStartedThread(new InterruptibleSyncRunnable(sync)); in testHasQueuedThreads() local
317 waitForQueuedThread(sync, t2); in testHasQueuedThreads()
323 awaitTermination(t2); in testHasQueuedThreads()
344 Thread t2 = new Thread(new InterruptibleSyncRunnable(sync)); in testIsQueued() local
346 assertFalse(sync.isQueued(t2)); in testIsQueued()
351 assertFalse(sync.isQueued(t2)); in testIsQueued()
352 t2.start(); in testIsQueued()
353 waitForQueuedThread(sync, t2); in testIsQueued()
355 assertTrue(sync.isQueued(t2)); in testIsQueued()
359 assertTrue(sync.isQueued(t2)); in testIsQueued()
[all …]
DReentrantLockTest.java247 Thread t2 = new Thread(new InterruptibleLockRunnable(lock)); in testHasQueuedThreads() local
254 t2.start(); in testHasQueuedThreads()
255 waitForQueuedThread(lock, t2); in testHasQueuedThreads()
261 awaitTermination(t2); in testHasQueuedThreads()
273 Thread t2 = new Thread(new InterruptibleLockRunnable(lock)); in testGetQueueLength() local
279 t2.start(); in testGetQueueLength()
280 waitForQueuedThread(lock, t2); in testGetQueueLength()
286 awaitTermination(t2); in testGetQueueLength()
311 Thread t2 = new Thread(new InterruptibleLockRunnable(lock)); in testHasQueuedThread() local
313 assertFalse(lock.hasQueuedThread(t2)); in testHasQueuedThread()
[all …]
DReentrantReadWriteLockTest.java507 Thread t2 = newStartedThread(new CheckedRunnable() { in testWriteAfterMultipleReadLocks() local
514 waitForQueuedThread(lock, t2); in testWriteAfterMultipleReadLocks()
520 awaitTermination(t2); in testWriteAfterMultipleReadLocks()
544 Thread t2 = newStartedThread(new CheckedRunnable() { in testReaderWriterReaderFairFifo() local
552 waitForQueuedThread(lock, t2); in testReaderWriterReaderFairFifo()
558 awaitTermination(t2); in testReaderWriterReaderFairFifo()
576 Thread t2 = newStartedThread(new CheckedRunnable() { in testReadAfterWriteLock() local
583 waitForQueuedThread(lock, t2); in testReadAfterWriteLock()
586 awaitTermination(t2); in testReadAfterWriteLock()
621 Thread t2 = newStartedThread(new CheckedRunnable() { in testReadTryLockBarging() local
[all …]
DExchangerTest.java42 Thread t2 = newStartedThread(new CheckedRunnable() { in testExchange() local
49 awaitTermination(t2); in testExchange()
62 Thread t2 = newStartedThread(new CheckedRunnable() { in testTimedExchange() local
69 awaitTermination(t2); in testTimedExchange()
137 Thread t2 = newStartedThread(new CheckedRunnable() { in testReplacementAfterExchange() local
154 awaitTermination(t2); in testReplacementAfterExchange()
DSemaphoreTest.java296 Thread t2 = newStartedThread(new CheckedRunnable() { in testUninterruptible() local
306 waitForQueuedThread(s, t2); in testUninterruptible()
307 t2.interrupt(); in testUninterruptible()
310 assertTrue(t2.isAlive()); in testUninterruptible()
315 awaitTermination(t2); in testUninterruptible()
330 Thread t2 = newStartedThread(new InterruptibleLockRunnable(lock)); in testHasQueuedThreads() local
331 waitForQueuedThread(lock, t2); in testHasQueuedThreads()
337 awaitTermination(t2); in testHasQueuedThreads()
353 Thread t2 = newStartedThread(new InterruptibleLockRunnable(lock)); in testGetQueueLength() local
354 waitForQueuedThread(lock, t2); in testGetQueueLength()
[all …]
DFutureTaskTest.java561 Thread t2 = newStartedThread(new CheckedRunnable() { in testGetRun() local
570 assertTrue(t2.isAlive()); in testGetRun()
577 awaitTermination(t2); in testGetRun()
600 Thread t2 = newStartedThread(new CheckedRunnable() { in testGetSet() local
609 assertTrue(t2.isAlive()); in testGetSet()
617 awaitTermination(t2); in testGetSet()
653 Thread t2 = new ThreadShouldThrow(CancellationException.class) { in testTimedGet_Cancellation() local
659 t2.start(); in testTimedGet_Cancellation()
666 awaitTermination(t2); in testTimedGet_Cancellation()
DAtomicIntegerArrayTest.java316 Thread t2 = new Thread(c2); in testCountingInMultipleThreads() local
318 t2.start(); in testCountingInMultipleThreads()
320 t2.join(); in testCountingInMultipleThreads()
DAtomicLongArrayTest.java315 Thread t2 = new Thread(c2); in testCountingInMultipleThreads() local
317 t2.start(); in testCountingInMultipleThreads()
319 t2.join(); in testCountingInMultipleThreads()
/libcore/ojluni/src/test/java/util/concurrent/tck/
DCyclicBarrierTest.java158 Thread t2 = new ThreadShouldThrow(BrokenBarrierException.class) { in testAwait1_Interrupted_BrokenBarrier() local
165 t2.start(); in testAwait1_Interrupted_BrokenBarrier()
169 awaitTermination(t2); in testAwait1_Interrupted_BrokenBarrier()
184 Thread t2 = new ThreadShouldThrow(BrokenBarrierException.class) { in testAwait2_Interrupted_BrokenBarrier() local
191 t2.start(); in testAwait2_Interrupted_BrokenBarrier()
195 awaitTermination(t2); in testAwait2_Interrupted_BrokenBarrier()
229 Thread t2 = newStartedThread(new CheckedRunnable() { in testAwait4_Timeout_BrokenBarrier() local
241 awaitTermination(t2); in testAwait4_Timeout_BrokenBarrier()
257 Thread t2 = newStartedThread(new CheckedRunnable() { in testAwait5_Timeout_BrokenBarrier() local
269 awaitTermination(t2); in testAwait5_Timeout_BrokenBarrier()
[all …]
DAbstractQueuedLongSynchronizerTest.java341 Thread t2 = newStartedThread(new InterruptibleSyncRunnable(sync)); in testHasQueuedThreads() local
342 waitForQueuedThread(sync, t2); in testHasQueuedThreads()
348 awaitTermination(t2); in testHasQueuedThreads()
369 Thread t2 = new Thread(new InterruptibleSyncRunnable(sync)); in testIsQueued() local
371 assertFalse(sync.isQueued(t2)); in testIsQueued()
376 assertFalse(sync.isQueued(t2)); in testIsQueued()
377 t2.start(); in testIsQueued()
378 waitForQueuedThread(sync, t2); in testIsQueued()
380 assertTrue(sync.isQueued(t2)); in testIsQueued()
384 assertTrue(sync.isQueued(t2)); in testIsQueued()
[all …]
DAbstractQueuedSynchronizerTest.java344 Thread t2 = newStartedThread(new InterruptibleSyncRunnable(sync)); in testHasQueuedThreads() local
345 waitForQueuedThread(sync, t2); in testHasQueuedThreads()
351 awaitTermination(t2); in testHasQueuedThreads()
372 Thread t2 = new Thread(new InterruptibleSyncRunnable(sync)); in testIsQueued() local
374 assertFalse(sync.isQueued(t2)); in testIsQueued()
379 assertFalse(sync.isQueued(t2)); in testIsQueued()
380 t2.start(); in testIsQueued()
381 waitForQueuedThread(sync, t2); in testIsQueued()
383 assertTrue(sync.isQueued(t2)); in testIsQueued()
387 assertTrue(sync.isQueued(t2)); in testIsQueued()
[all …]
DReentrantLockTest.java270 Thread t2 = new Thread(new InterruptibleLockRunnable(lock)); in testHasQueuedThreads() local
277 t2.start(); in testHasQueuedThreads()
278 waitForQueuedThread(lock, t2); in testHasQueuedThreads()
284 awaitTermination(t2); in testHasQueuedThreads()
296 Thread t2 = new Thread(new InterruptibleLockRunnable(lock)); in testGetQueueLength() local
302 t2.start(); in testGetQueueLength()
303 waitForQueuedThread(lock, t2); in testGetQueueLength()
309 awaitTermination(t2); in testGetQueueLength()
334 Thread t2 = new Thread(new InterruptibleLockRunnable(lock)); in testHasQueuedThread() local
336 assertFalse(lock.hasQueuedThread(t2)); in testHasQueuedThread()
[all …]
DReentrantReadWriteLockTest.java530 Thread t2 = newStartedThread(new CheckedRunnable() { in testWriteAfterMultipleReadLocks() local
537 waitForQueuedThread(lock, t2); in testWriteAfterMultipleReadLocks()
543 awaitTermination(t2); in testWriteAfterMultipleReadLocks()
567 Thread t2 = newStartedThread(new CheckedRunnable() { in testReaderWriterReaderFairFifo() local
575 waitForQueuedThread(lock, t2); in testReaderWriterReaderFairFifo()
581 awaitTermination(t2); in testReaderWriterReaderFairFifo()
599 Thread t2 = newStartedThread(new CheckedRunnable() { in testReadAfterWriteLock() local
606 waitForQueuedThread(lock, t2); in testReadAfterWriteLock()
609 awaitTermination(t2); in testReadAfterWriteLock()
644 Thread t2 = newStartedThread(new CheckedRunnable() { in testReadTryLockBarging() local
[all …]
DSemaphoreTest.java319 Thread t2 = newStartedThread(new CheckedRunnable() { in testUninterruptible() local
329 waitForQueuedThread(s, t2); in testUninterruptible()
330 t2.interrupt(); in testUninterruptible()
333 assertTrue(t2.isAlive()); in testUninterruptible()
338 awaitTermination(t2); in testUninterruptible()
353 Thread t2 = newStartedThread(new InterruptibleLockRunnable(lock)); in testHasQueuedThreads() local
354 waitForQueuedThread(lock, t2); in testHasQueuedThreads()
360 awaitTermination(t2); in testHasQueuedThreads()
376 Thread t2 = newStartedThread(new InterruptibleLockRunnable(lock)); in testGetQueueLength() local
377 waitForQueuedThread(lock, t2); in testGetQueueLength()
[all …]
DExchangerTest.java65 Thread t2 = newStartedThread(new CheckedRunnable() { in testExchange() local
72 awaitTermination(t2); in testExchange()
85 Thread t2 = newStartedThread(new CheckedRunnable() { in testTimedExchange() local
92 awaitTermination(t2); in testTimedExchange()
160 Thread t2 = newStartedThread(new CheckedRunnable() { in testReplacementAfterExchange() local
177 awaitTermination(t2); in testReplacementAfterExchange()
DFutureTaskTest.java584 Thread t2 = newStartedThread(new CheckedRunnable() { in testGetRun() local
593 assertTrue(t2.isAlive()); in testGetRun()
600 awaitTermination(t2); in testGetRun()
623 Thread t2 = newStartedThread(new CheckedRunnable() { in testGetSet() local
632 assertTrue(t2.isAlive()); in testGetSet()
640 awaitTermination(t2); in testGetSet()
676 Thread t2 = new ThreadShouldThrow(CancellationException.class) { in testTimedGet_Cancellation() local
682 t2.start(); in testTimedGet_Cancellation()
689 awaitTermination(t2); in testTimedGet_Cancellation()
/libcore/luni/src/test/java/libcore/java/sql/
DTimestampTest.java35 Timestamp t2 = new Timestamp(Long.MIN_VALUE + 1); in testToString() local
36 assertEquals("292278994-08-17 07:12:55.193", t2.toString()); in testToString()
58 Timestamp t2 = Timestamp.valueOf("2001-01-02 01:05:07.123"); in testValueOf() local
59 assertEquals(978397507000L + 123000000 / 1000000, t2.getTime()); in testValueOf()
60 assertEquals(123000000, t2.getNanos()); in testValueOf()
DOldResultSetGetterTests.java948 Time t2 = new java.sql.Time(millis2); in testGetTimeInt() local
962 assertEquals(t2.toString(), resTime.toString()); in testGetTimeInt()
963 assertEquals(t2.getTime(), resTime.getTime()); in testGetTimeInt()
964 assertEquals(t2, resTime); in testGetTimeInt()
1005 Time t2 = new java.sql.Time(millis2); in testGetTimeIntCalendar() local
1022 assertEquals(t2.toString(), timeRes.toString()); in testGetTimeIntCalendar()
1023 assertEquals(t2.getTime(), timeRes.getTime()); in testGetTimeIntCalendar()
1024 assertEquals(t2, timeRes); in testGetTimeIntCalendar()
1078 Time t2 = new java.sql.Time(millis2); in testGetTimeString() local
1084 assertEquals(t2.toString(), timeRes.toString()); in testGetTimeString()
[all …]
/libcore/luni/src/test/java/libcore/java/lang/
DEnumTest.java97 Thread t2 = new Thread() { in testDeadlock() local
105 t2.start(); in testDeadlock()
119 t2.join(); in testDeadlock()
DThreadTest.java143 WakeupTestThread t2 = new WakeupTestThread(); in threadWakeup() local
146 t2.start(); in threadWakeup()
147 assertTrue("Threads already finished", !t1.done && !t2.done); in threadWakeup()
150 t2.interrupt(); in threadWakeup()
153 assertTrue("Threads did not finish", t1.done && t2.done); in threadWakeup()
403 Thread t2 = new Thread(group, "t2") { in getAllStackTracesIncludesAllGroups() local
408 t2.start(); in getAllStackTracesIncludesAllGroups()
409 t2.join(); in getAllStackTracesIncludesAllGroups()
/libcore/ojluni/src/test/java/nio/file/attribute/
DFileTimeTest.java279 FileTime t2 = FileTime.from(v2, u2); in eq() local
280 if (!t1.equals(t2)) in eq()
282 if (t1.hashCode() != t2.hashCode()) in eq()
288 FileTime t2 = FileTime.from(v2, u2); in eq() local
289 if (!t1.equals(t2)) in eq()
291 if (t1.hashCode() != t2.hashCode()) in eq()
310 FileTime t2 = FileTime.from(v2, u2); in neq() local
311 if (t1.equals(t2)) in neq()
317 FileTime t2 = FileTime.from(v2, u2); in neq() local
318 if (t1.equals(t2)) in neq()
/libcore/luni/src/test/java/tests/com/android/org/bouncycastle/crypto/digests/
DDigestTest.java81 long t2 = System.nanoTime(); in doTestMessageDigest() local
89 newTime.add(t3 - t2); in doTestMessageDigest()
/libcore/ojluni/src/main/java/java/math/
DBigInteger.java1811 BigInteger v0, v1, v2, vm1, vinf, t1, t2, tm1, da1, db1; in multiplyToomCook3() local
1830 t2 = v2.subtract(vm1).exactDivideBy3(); in multiplyToomCook3()
1833 t2 = t2.subtract(t1).shiftRight(1); in multiplyToomCook3()
1835 t2 = t2.subtract(vinf.shiftLeft(1)); in multiplyToomCook3()
1836 tm1 = tm1.subtract(t2); in multiplyToomCook3()
1841 …BigInteger result = vinf.shiftLeft(ss).add(t2).shiftLeft(ss).add(t1).shiftLeft(ss).add(tm1).shiftL… in multiplyToomCook3()
2168 BigInteger v0, v1, v2, vm1, vinf, t1, t2, tm1, da1; in squareToomCook3() local
2184 t2 = v2.subtract(vm1).exactDivideBy3(); in squareToomCook3()
2187 t2 = t2.subtract(t1).shiftRight(1); in squareToomCook3()
2189 t2 = t2.subtract(vinf.shiftLeft(1)); in squareToomCook3()
[all …]

12