Searched refs:lock (Results 1 - 25 of 393) sorted by relevance

1234567891011>>

/openjdk7/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/
H A DcmsLockVerifier.hpp33 // main GC thread or the CMS thread might hold the lock on behalf of
37 static void assert_locked(const Mutex* lock, const Mutex* p_lock1, const Mutex* p_lock2)
39 static void assert_locked(const Mutex* lock, const Mutex* p_lock) { argument
40 assert_locked(lock, p_lock, NULL);
42 static void assert_locked(const Mutex* lock) { argument
43 assert_locked(lock, NULL);
H A DcmsLockVerifier.cpp33 // or the CMS thread might hold the lock on behalf of the parallel
37 void CMSLockVerifier::assert_locked(const Mutex* lock, argument
46 if (lock == NULL) { // a "lock-free" structure, e.g. MUT, protected by CMS token
70 // Make sure that we are holding the associated lock.
71 assert_lock_strong(lock);
83 // Make sure that the VM or CMS thread holds lock on our behalf
87 assert(lock->owner() == VMThread::vm_thread() ||
88 lock->owner() == ConcurrentMarkSweepThread::cmst(),
/openjdk7/jdk/src/share/classes/sun/awt/datatransfer/
H A DToolkitThreadBlockedHandler.java29 public void lock(); method in interface:ToolkitThreadBlockedHandler
/openjdk7/jdk/src/share/classes/java/util/concurrent/
H A DDelayQueue.java71 private transient final ReentrantLock lock = new ReentrantLock(); field in class:DelayQueue
97 private final Condition available = lock.newCondition();
135 final ReentrantLock lock = this.lock;
136 lock.lock();
145 lock.unlock();
182 final ReentrantLock lock = this.lock;
183 lock
[all...]
H A DArrayBlockingQueue.java103 /** Main lock guarding all access */
104 final ReentrantLock lock; field in class:ArrayBlockingQueue
150 * Call only when holding lock.
161 * Call only when holding lock.
176 * Call only when holding lock.
227 lock = new ReentrantLock(fair);
228 notEmpty = lock.newCondition();
229 notFull = lock.newCondition();
252 final ReentrantLock lock = this.lock;
[all...]
H A DLinkedBlockingDeque.java80 * single lock and using conditions to manage blocking.
154 /** Main lock guarding all access */
155 final ReentrantLock lock = new ReentrantLock(); field in class:LinkedBlockingDeque
158 private final Condition notEmpty = lock.newCondition();
161 private final Condition notFull = lock.newCondition();
194 final ReentrantLock lock = this.lock;
195 lock.lock(); // Never contended, but necessary for visibility
204 lock
[all...]
H A DCyclicBarrier.java137 * using the barrier - due to the non-deterministic way the lock
148 /** The lock for guarding barrier entry */
149 private final ReentrantLock lock = new ReentrantLock(); field in class:CyclicBarrier
151 private final Condition trip = lock.newCondition();
168 * Called only while holding lock.
180 * Called only while holding lock.
194 final ReentrantLock lock = this.lock;
195 lock.lock();
[all...]
H A DPriorityBlockingQueue.java104 * operations protected with a single lock. However, allocation
106 * holding main lock) in order to allow takes to operate
109 * build-up. The need to back away from lock during allocation
111 * java.util.PriorityQueue operations within a lock, as was done
155 private final ReentrantLock lock; field in class:PriorityBlockingQueue
212 this.lock = new ReentrantLock();
213 this.notEmpty = lock.newCondition();
235 this.lock = new ReentrantLock();
236 this.notEmpty = lock.newCondition();
272 * holding lock
[all...]
H A DCopyOnWriteArrayList.java82 /** The lock protecting all mutators */
83 transient final ReentrantLock lock = new ReentrantLock(); field in class:CopyOnWriteArrayList
387 final ReentrantLock lock = this.lock;
388 lock.lock();
404 lock.unlock();
415 final ReentrantLock lock = this.lock;
416 lock
[all...]
/openjdk7/jdk/src/share/classes/java/util/
H A DTimerTask.java40 final Object lock = new Object(); field in class:TimerTask
117 synchronized(lock) {
153 synchronized(lock) {
/openjdk7/jdk/test/java/lang/ThreadGroup/
H A DStop.java33 private static final Object lock = new Object(); field in class:Stop
49 synchronized (lock) {
56 lock.notifyAll();
69 synchronized(lock){
71 lock.wait();
/openjdk7/jdk/src/share/classes/sun/rmi/transport/tcp/
H A DMultiplexOutputStream.java63 * lock acquired to access shared variables:
66 * invoked while this lock is held, since they could potentially
68 * full, and the manager may need to acquire this lock to process
71 private Object lock = new Object(); field in class:MultiplexOutputStream
126 synchronized (lock) {
129 lock.wait();
141 synchronized (lock) {
147 synchronized (lock) {
179 synchronized (lock) {
181 lock
[all...]
/openjdk7/jdk/test/java/awt/event/InvocationEvent/
H A DInvocationEventTest.java50 Object lock = new Object();
51 InvocationEvent event = new InvocationEvent(tk, runnable, lock, true);
57 synchronized(lock) {
60 lock.wait();
/openjdk7/jdk/src/share/classes/sun/management/
H A DSensor.java51 private Object lock; field in class:Sensor
65 this.lock = new Object();
83 synchronized (lock) {
96 synchronized (lock) {
106 synchronized (lock) {
118 synchronized (lock) {
132 synchronized (lock) {
144 synchronized (lock) {
156 synchronized (lock) {
H A DFileSystem.java38 private static final Object lock = new Object(); field in class:FileSystem
47 synchronized (lock) {
/openjdk7/jdk/src/share/classes/sun/misc/
H A DLock.java29 * The Lock class provides a simple, useful interface to a lock.
39 * a lock, and one of the methods may throw an exception, you must be
40 * prepared to release the lock similarly to the following example:
46 * myLock.lock();
65 * Create a lock, which is initially not locked.
71 * Acquire the lock. If someone else has the lock, wait until it
73 * will not return until the lock has been acquired.
78 public final synchronized void lock() throws InterruptedException { method in class:Lock
86 * Release the lock
[all...]
/openjdk7/jdk/test/java/nio/channels/FileChannel/
H A DLock.java34 * Testing FileChannel's lock method.
65 FileLock lock;
67 lock = channel.lock();
69 lock = channel.tryLock();
70 lock.release();
76 // Grab the lock
79 FileLock lock = null;
82 lock = fc.lock(
[all...]
/openjdk7/jdk/src/share/classes/java/io/
H A DWriter.java69 protected Object lock; field in class:Writer
76 this.lock = this;
83 * @param lock
86 protected Writer(Object lock) { argument
87 if (lock == null) {
90 this.lock = lock;
108 synchronized (lock) {
181 synchronized (lock) {
H A DReader.java60 protected Object lock; field in class:Reader
67 this.lock = this;
74 * @param lock The Object to synchronize on.
76 protected Reader(Object lock) { argument
77 if (lock == null) {
80 this.lock = lock;
180 synchronized (lock) {
/openjdk7/jdk/test/sun/awt/AppContext/8012933/
H A DTest8012933.java38 final Object lock = new Object(); field in class:Test8012933
66 synchronized (lock) {
68 lock.notifyAll();
74 synchronized (lock) {
78 lock.wait();
/openjdk7/jdk/src/windows/native/com/sun/media/sound/
H A DPLATFORM_API_WinOS_Util.c59 CRITICAL_SECTION* lock = (CRITICAL_SECTION*) malloc(sizeof(CRITICAL_SECTION)); local
60 InitializeCriticalSection(lock);
62 return lock;
65 void MIDI_DestroyLock(void* lock) { argument
66 if (lock) {
67 DeleteCriticalSection((CRITICAL_SECTION*) lock);
68 free(lock);
73 void MIDI_Lock(void* lock) { argument
74 if (lock) {
75 EnterCriticalSection((CRITICAL_SECTION*) lock);
79 MIDI_Unlock(void* lock) argument
[all...]
/openjdk7/jdk/test/com/sun/jdi/
H A DMixedSuspendTest.sh46 static String lock = "startLock";
53 synchronized(lock) {
56 lock.wait();
67 synchronized(lock) {
74 synchronized(lock) {
75 lock.notifyAll();
78 synchronized(lock) {
/openjdk7/jdk/test/java/util/concurrent/SynchronousQueue/
H A DFairness.java38 final ReentrantLock lock = new ReentrantLock();
39 final Condition ready = lock.newCondition();
42 lock.lock();
47 lock.lock();
49 lock.unlock();
/openjdk7/jdk/test/java/util/concurrent/locks/ReentrantReadWriteLock/
H A DBug6571733.java27 * @summary Check that regaining a read lock succeeds after a write
28 * lock attempt times out
41 final ReentrantReadWriteLock lock = new ReentrantReadWriteLock(fairness);
43 // obtain read lock
44 lock.readLock().lock();
48 check(! lock.writeLock().tryLock(0, TimeUnit.DAYS));
50 lock.readLock().lock();
51 lock
[all...]
/openjdk7/jdk/test/java/util/concurrent/locks/ReentrantLock/
H A DTimeoutLockLoops.java78 private final ReentrantLock lock = new ReentrantLock(); field in class:TimeoutLockLoops.ReentrantLockLoop
89 lock.lock();
91 lock.unlock();
95 while (!lock.tryLock()); // Jam lock
96 // lock.lock();
117 final ReentrantLock lock = this.lock;
[all...]

Completed in 87 milliseconds

1234567891011>>