Searched defs:thread (Results 1 - 21 of 21) sorted by relevance

/libcore/dalvik/src/main/java/dalvik/system/profiler/
H A DDalvikThreadSampler.java39 @Override public StackTraceElement[] getStackTrace(Thread thread) { argument
40 int count = VMStack.fillStackTraceElements(thread, mutableStackTraceElements[depth]);
H A DPortableThreadSampler.java33 @Override public StackTraceElement[] getStackTrace(Thread thread) { argument
34 StackTraceElement[] stackFrames = thread.getStackTrace();
H A DThreadSampler.java23 * between portable and VM specific implementations of thread
34 * Return a stack trace for the current thread limited by the
36 * return null if no sample is availble for the thread, which may
37 * happen in cases such as thread termination. The resulting array
43 public StackTraceElement[] getStackTrace(Thread thread); argument
H A DSamplingProfiler.java38 * SamplingProfiler}. It samples the current thread's stack to a depth
94 * Real hprof output examples don't start the thread and trace
105 * thread start and end events.
120 * be thread safe, have a single mutable instance would need to be
127 * StackTraceElement} array for a given thread. The array is
135 * thread collector.
147 * @param threadSet The thread set specifies which threads to
323 * restarted, there is no thread safe way to access the data.
335 * At every sample time, it asks the thread set for the set
336 * of threads to sample. It maintains a history of thread creatio
394 recordStackTrace(Thread thread, StackTraceElement[] stackFrames) argument
452 addStartThread(Thread thread) argument
478 addEndThread(Thread thread) argument
[all...]
/libcore/luni/src/main/java/java/util/concurrent/locks/
H A DLockSupport.java12 * Basic thread blocking primitives for creating locks and other
15 * <p>This class associates, with each thread that uses it, a permit
27 * between one thread invoking {@code park} and another thread trying
30 * thread was interrupted, and timeout versions are supported. The
40 * the thread is blocked to permit monitoring and diagnostic tools to
57 * permit is associated with each thread, any intermediary uses of
113 * Makes available the permit for the given thread, if it
114 * was not already available. If the thread was blocked on
118 * thread ha
123 unpark(Thread thread) argument
[all...]
H A DReentrantLock.java17 * <p>A {@code ReentrantLock} is <em>owned</em> by the thread last
18 * successfully locking, but not yet unlocking it. A thread invoking
20 * the lock is not owned by another thread. The method will return
21 * immediately if the current thread already owns the lock. This can
28 * thread. Otherwise this lock does not guarantee any particular
34 * fairness of thread scheduling. Thus, one of many threads using a
72 * the same thread. Attempts to exceed this limit result in
136 // we don't need to do so to check if current thread is owner
247 * <p>Acquires the lock if it is not held by another thread and returns
250 * <p>If the current thread alread
620 hasQueuedThread(Thread thread) argument
[all...]
H A DReentrantReadWriteLock.java35 * is released, either the longest-waiting single writer thread will
40 * <p>A thread that tries to acquire a fair read lock (non-reentrantly)
42 * writer thread. The thread will not acquire the read lock until
43 * after the oldest currently waiting writer thread has acquired and
49 * <p>A thread that tries to acquire a fair write lock (non-reentrantly)
63 * thread have been released.
120 * // Recheck state because another thread might have
246 * A counter for per-thread read hold counts.
267 * The number of reentrant read locks held by current thread
1342 hasQueuedThread(Thread thread) argument
[all...]
H A DAbstractQueuedLongSynchronizer.java55 * information about a thread in the predecessor of its node. A
56 * "status" field in each node keeps track of whether a thread
60 * thread. The status field does NOT control whether threads are
61 * granted locks etc though. A thread may try to acquire if it is
64 * contender thread may need to rewait.
90 * The thread id for each node is kept in its own node, so a
92 * next link to determine which thread it is. Determination of
133 /** waitStatus value to indicate thread has cancelled */
135 /** waitStatus value to indicate successor's thread needs unparking */
137 /** waitStatus value to indicate thread i
213 volatile Thread thread; field in class:AbstractQueuedLongSynchronizer.Node
252 Node(Thread thread, Node mode) argument
257 Node(Thread thread, int waitStatus) argument
1189 isQueued(Thread thread) argument
[all...]
H A DAbstractQueuedSynchronizer.java46 * waiting thread (if one exists) must also determine whether it can
57 * held with respect to the current thread, method {@link #release}
74 * thread queues. Typical subclasses requiring serializability will
95 * must be internally thread-safe, and should in general be short and
101 * AbstractOwnableSynchronizer} useful to keep track of the thread
113 * <em>enqueue thread if it is not already queued</em>;
114 * <em>possibly block current thread</em>;
119 * <em>unblock the first queued thread</em>;
125 * enqueuing, a newly acquiring thread may <em>barge</em> ahead of
131 * #getFirstQueuedThread} does not return the current thread
442 volatile Thread thread; field in class:AbstractQueuedSynchronizer.Node
481 Node(Thread thread, Node mode) argument
486 Node(Thread thread, int waitStatus) argument
1418 isQueued(Thread thread) argument
[all...]
/libcore/luni/src/test/java/tests/api/java/lang/
H A DProcessManagerTest.java33 Thread thread = null; field in class:ProcessManagerTest
62 thread = new Thread() {
87 thread.interrupt();
90 thread.start();
103 thread.interrupt();
140 Thread thread = new Thread() {
155 thread.setDaemon(true);
156 thread.start();
/libcore/luni/src/main/java/java/lang/
H A DVMThread.java20 Thread thread; field in class:VMThread
24 thread = t;
43 VMThread.create(thread, stackSize);
73 * Tell the VM that the thread's name has changed. This is useful for
H A DDaemons.java56 private Thread thread; field in class:Daemons.Daemon
59 if (thread != null) {
62 thread = new Thread(ThreadGroup.mSystem, this,
64 thread.setDaemon(true);
65 thread.start();
71 * Returns true while the current thread should continue to run; false
75 return thread != null;
79 if (thread == null) {
82 thread.interrupt();
86 * Waits for the runtime thread t
[all...]
H A DSecurityManager.java42 public void checkAccess(Thread thread) { } argument
141 * Returns the current thread's thread group.
H A DThreadGroup.java28 * This class is obsolete. See <i>Effective Java</i> Item 73, "Avoid thread groups" for details.
73 * will be child of the {@code ThreadGroup} to which the calling thread belongs.
117 * Returns the number of running {@code Thread}s which are children of this thread group,
125 for (Thread thread : threads) {
126 if (thread.isAlive()) {
157 * Adds a {@code ThreadGroup} to this thread group.
194 * Destroys this thread group and recursively all its subgroups. It is only legal
197 * or thread groups in it).
199 * @throws IllegalThreadStateException if this thread group or any of its
235 * Auxiliary method that destroys this thread grou
703 addThread(Thread thread) argument
715 removeThread(Thread thread) argument
[all...]
H A DThread.java88 * A representation of a thread's state. A given thread may only be in one
93 * The thread has been created, but has never been started.
97 * The thread may be run.
101 * The thread is blocked and waiting for a lock.
105 * The thread is waiting.
109 * The thread is waiting for a specified amount of time.
113 * The thread has been terminated.
119 * The maximum priority value allowed for a thread.
124 * The minimum priority value allowed for a thread
1136 uncaughtException(Thread thread, Throwable ex) argument
[all...]
/libcore/luni/src/test/java/libcore/java/io/
H A DInterruptedStreamTest.java40 * Test that interrupting a thread blocked on I/O causes that thread to throw
120 Thread thread = interruptMeLater();
126 waitForInterrupt(thread);
131 Thread thread = interruptMeLater();
137 waitForInterrupt(thread);
142 Thread thread = interruptMeLater();
148 waitForInterrupt(thread);
153 Thread thread = interruptMeLater();
161 waitForInterrupt(thread);
207 waitForInterrupt(Thread thread) argument
[all...]
/libcore/luni/src/test/java/tests/api/org/apache/harmony/kernel/dalvik/
H A DThreadsTest.java80 /** Test the case where the thread is preemptively unparked. */
122 /** Test the case where the thread is preemptively unparked. */
257 * specified amount of time and then unparks an indicated thread.
262 private final Thread thread; field in class:ThreadsTest.WaitAndUnpark
264 public WaitAndUnpark(CyclicBarrier barrier, long waitMillis, Thread thread) { argument
267 this.thread = thread;
282 UNSAFE.unpark(thread);
/libcore/luni/src/main/java/java/util/concurrent/
H A DFutureTask.java76 /** The thread running the callable; CASed during run() */
323 volatile Thread thread; field in class:FutureTask.WaitNode
325 WaitNode() { thread = Thread.currentThread(); }
337 Thread t = q.thread;
339 q.thread = null;
378 q.thread = null;
412 node.thread = null;
417 if (q.thread != null)
421 if (pred.thread == null) // check for race
H A DTimeUnit.java303 * @param thread the thread to wait for
308 public void timedJoin(Thread thread, long timeout) argument
313 thread.join(ms, ns);
H A DPhaser.java65 * waiting thread is interrupted. Interruptible and timeout
482 * parent, and initial phase number 0. Any thread using this
719 * @throws InterruptedException if thread interrupted while waiting
754 * @throws InterruptedException if thread interrupted while waiting
947 Thread t; // its thread
952 (t = q.thread) != null) {
953 q.thread = null;
974 if (q == null || ((t = q.thread) != null && q.phase == p))
977 q.thread = null;
991 * avoid it when threads regularly arrive: When a thread i
1069 volatile Thread thread; // nulled to cancel wait field in class:Phaser.QNode
[all...]
H A DThreadPoolExecutor.java33 * Executors#newCachedThreadPool} (unbounded thread pool, with
34 * automatic thread reclamation), {@link Executors#newFixedThreadPool}
35 * (fixed size thread pool) and {@link
36 * Executors#newSingleThreadExecutor} (single background thread), that
52 * than corePoolSize threads are running, a new thread is created to
55 * threads running, a new thread will be created only if the queue is
57 * create a fixed-size thread pool. By setting maximumPoolSize to an
79 * alter the thread's name, thread group, priority, daemon status,
80 * etc. If a {@code ThreadFactory} fails to create a thread whe
556 final Thread thread; field in class:ThreadPoolExecutor.Worker
[all...]

Completed in 1984 milliseconds