HomeSort by relevance Sort by last modified time
    Searched refs:lock (Results 51 - 75 of 2572) sorted by null

1 23 4 5 6 7 8 91011>>

  /external/python/cpython2/Python/
thread_atheos.h 147 * Lock support.
156 fastmutex_t *lock; local
166 lock = (fastmutex_t *) malloc(sizeof(fastmutex_t));
167 if (lock == NULL) {
173 PyOS_snprintf(name, sizeof(name), "python lock (%d)", this_lock);
176 if (fastmutex_create(name, lock) < 0) {
179 free(lock);
180 lock = NULL;
182 dprintf(("PyThread_allocate_lock()-> %p\n", lock));
183 return (PyThread_type_lock) lock;
    [all...]
thread_pthread.h 98 /* A pthread mutex isn't sufficient to model the Python lock type
101 * -> a thread tries to lock a mutex it already has locked
107 * The pthread_lock struct implements a Python lock as a "locked?" bit
115 /* a <cond, mutex> pair to handle an acquire of a locked lock */
253 * Lock support.
259 sem_t *lock; local
266 lock = (sem_t *)malloc(sizeof(sem_t));
268 if (lock) {
269 status = sem_init(lock,0,1);
273 free((void *)lock);
362 pthread_lock *lock; local
    [all...]
thread_os2.h 82 * Lock support. This is implemented with an event semaphore and critical
109 type_os2_lock lock = (type_os2_lock)malloc(sizeof(struct os2_lock_t));
115 lock->is_set = 0;
117 DosCreateEventSem(NULL, &lock->changed, 0, 0);
121 lock->changed));
123 return (PyThread_type_lock)lock;
131 type_os2_lock lock = (type_os2_lock)aLock; local
143 DosCloseEventSem(lock->changed);
149 * Return 1 on success if the lock was acquired
151 * and 0 if the lock was not acquired
161 type_os2_lock lock = (type_os2_lock)aLock; local
208 type_os2_lock lock = (type_os2_lock)aLock; local
    [all...]
  /art/test/980-redefine-object/src-ex/
TestWatcher.java 22 // Lock to synchronize access to the static state of this class.
23 private static final ReentrantLock lock = new ReentrantLock(); field in class:TestWatcher
29 lock.lock();
35 if (!lock.isHeldByCurrentThread()) {
39 lock.unlock();
  /external/python/cpython3/Modules/
hashlib.h 37 * LEAVE_HASHLIB block or explicitly acquire and release the lock inside
44 if ((obj)->lock) { \
45 if (!PyThread_acquire_lock((obj)->lock, 0)) { \
47 PyThread_acquire_lock((obj)->lock, 1); \
52 if ((obj)->lock) { \
53 PyThread_release_lock((obj)->lock); \
  /external/libchrome/base/synchronization/
lock_unittest.cc 5 #include "base/synchronization/lock.h"
21 explicit BasicLockTestThread(Lock* lock) : lock_(lock), acquired_(0) {}
47 Lock* lock_;
54 Lock lock; local
55 BasicLockTestThread thread(&lock);
62 lock.Acquire();
64 lock.Release()
114 Lock lock; local
154 Lock lock; local
218 Lock lock; local
234 Lock lock; local
    [all...]
  /cts/tests/tests/appop/src/android/app/appops/cts/
UidStateForceActivity.kt 24 private val lock = ReentrantLock()
25 private val condition = lock.newCondition()
31 lock.withLock {
40 lock.withLock {
46 lock.withLock {
  /device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Python/
thread_pthread.h 98 /* A pthread mutex isn't sufficient to model the Python lock type
101 * -> a thread tries to lock a mutex it already has locked
107 * The pthread_lock struct implements a Python lock as a "locked?" bit
115 /* a <cond, mutex> pair to handle an acquire of a locked lock */
252 * Lock support.
258 sem_t *lock; local
265 lock = (sem_t *)malloc(sizeof(sem_t));
267 if (lock) {
268 status = sem_init(lock,0,1);
272 free((void *)lock);
358 pthread_lock *lock; local
    [all...]
thread_os2.h 82 * Lock support. This is implemented with an event semaphore and critical
109 type_os2_lock lock = (type_os2_lock)malloc(sizeof(struct os2_lock_t));
115 lock->is_set = 0;
117 DosCreateEventSem(NULL, &lock->changed, 0, 0);
121 lock->changed));
123 return (PyThread_type_lock)lock;
131 type_os2_lock lock = (type_os2_lock)aLock; local
143 DosCloseEventSem(lock->changed);
149 * Return 1 on success if the lock was acquired
151 * and 0 if the lock was not acquired.
161 type_os2_lock lock = (type_os2_lock)aLock; local
208 type_os2_lock lock = (type_os2_lock)aLock; local
    [all...]
  /external/guava/guava/src/com/google/common/util/concurrent/
Monitor.java 120 * private final ReentrantLock lock = new ReentrantLock();
121 * private final Condition valuePresent = lock.newCondition();
122 * private final Condition valueAbsent = lock.newCondition();
126 * lock.lock();
136 * lock.unlock();
141 * lock.lock();
149 * lock.unlock();
209 // guard.lock();
325 private final ReentrantLock lock; field in class:Monitor
374 final ReentrantLock lock = this.lock; local
423 final ReentrantLock lock = this.lock; local
447 final ReentrantLock lock = this.lock; local
476 final ReentrantLock lock = this.lock; local
517 final ReentrantLock lock = this.lock; local
571 final ReentrantLock lock = this.lock; local
594 final ReentrantLock lock = this.lock; local
642 final ReentrantLock lock = this.lock; local
669 final ReentrantLock lock = this.lock; local
765 final ReentrantLock lock = this.lock; local
    [all...]
  /external/libevent/
evthread-internal.h 50 /* Global function pointers to lock-related functions. NULL if locking isn't
62 * running a given event_base's loop. Requires lock. */
69 * thread. Requires lock. */
75 /** Allocate a new lock, and store it in lockvar, a void*. Sets lockvar to
81 /** Free a given lock, if it is present and locking is enabled. */
89 /** Acquire a lock. */
93 evthread_lock_fns_.lock(mode, lockvar); \
96 /** Release a lock */
113 /** Lock an event_base, if it is set up for locking. Acquires the lock
    [all...]
evthread_pthread.c 48 pthread_mutex_t *lock = mm_malloc(sizeof(pthread_mutex_t)); local
49 if (!lock)
53 if (pthread_mutex_init(lock, attr)) {
54 mm_free(lock);
57 return lock;
63 pthread_mutex_t *lock = lock_; local
64 pthread_mutex_destroy(lock);
65 mm_free(lock);
71 pthread_mutex_t *lock = lock_; local
73 return pthread_mutex_trylock(lock);
81 pthread_mutex_t *lock = lock_; local
141 pthread_mutex_t *lock = lock_; local
    [all...]
  /external/libchrome/mojo/public/cpp/bindings/lib/
may_auto_lock.h 11 #include "base/synchronization/lock.h"
16 // Similar to base::AutoLock, except that it does nothing if |lock| passed into
20 explicit MayAutoLock(base::Optional<base::Lock>* lock)
21 : lock_(lock->has_value() ? &lock->value() : nullptr) {
34 base::Lock* lock_;
38 // Similar to base::AutoUnlock, except that it does nothing if |lock| passed
42 explicit MayAutoUnlock(base::Optional<base::Lock>* lock)
    [all...]
  /external/webrtc/webrtc/base/
sharedexclusivelock.h 20 // This class provides shared-exclusive lock. It can be used in cases like
44 explicit SharedScope(SharedExclusiveLock* lock) SHARED_LOCK_FUNCTION(lock)
45 : lock_(lock) {
59 explicit ExclusiveScope(SharedExclusiveLock* lock)
60 EXCLUSIVE_LOCK_FUNCTION(lock)
61 : lock_(lock) {
  /external/compiler-rt/test/tsan/Darwin/
osspinlock-norace.cc 7 OSSpinLock lock; variable
10 OSSpinLockLock(&lock);
12 OSSpinLockUnlock(&lock);
  /external/libchrome/base/test/
simple_test_tick_clock.cc 16 AutoLock lock(lock_);
21 AutoLock lock(lock_);
27 AutoLock lock(lock_);
  /art/test/1932-monitor-events-misc/
monitor_misc.cc 39 jobject lock) {
51 jint res = env->MonitorEnter(lock);
54 env->CallStaticVoidMethod(klass, print_state, lock, exc.get(), res);
55 env->MonitorExit(lock);
  /external/jacoco/org.jacoco.core.test/src/org/jacoco/core/test/filter/targets/
Synchronized.java 24 private static final Object lock = new Object(); field in class:Synchronized
28 synchronized (lock) { // $line-monitorEnter$
35 synchronized (lock) { // $line-explicitException.monitorEnter$
41 synchronized (lock) { // $line-implicitException.monitorEnter$
  /external/jemalloc/include/jemalloc/internal/
mutex.h 37 SRWLOCK lock; member in struct:malloc_mutex_s
39 CRITICAL_SECTION lock;
42 os_unfair_lock lock;
44 OSSpinLock lock;
46 pthread_mutex_t lock;
49 pthread_mutex_t lock;
92 AcquireSRWLockExclusive(&mutex->lock);
94 EnterCriticalSection(&mutex->lock);
97 os_unfair_lock_lock(&mutex->lock);
99 OSSpinLockLock(&mutex->lock);
    [all...]
  /external/boringssl/src/crypto/
thread_win.c 45 void CRYPTO_MUTEX_init(CRYPTO_MUTEX *lock) {
46 InitializeSRWLock((SRWLOCK *) lock);
49 void CRYPTO_MUTEX_lock_read(CRYPTO_MUTEX *lock) {
50 AcquireSRWLockShared((SRWLOCK *) lock);
53 void CRYPTO_MUTEX_lock_write(CRYPTO_MUTEX *lock) {
54 AcquireSRWLockExclusive((SRWLOCK *) lock);
57 void CRYPTO_MUTEX_unlock_read(CRYPTO_MUTEX *lock) {
58 ReleaseSRWLockShared((SRWLOCK *) lock);
61 void CRYPTO_MUTEX_unlock_write(CRYPTO_MUTEX *lock) {
62 ReleaseSRWLockExclusive((SRWLOCK *) lock);
    [all...]
  /device/google/marlin/camera/QCamera2/HAL/
QCameraParametersIntf.cpp 56 Mutex::Autolock lock(mLock);
67 Mutex::Autolock lock(mLock);
81 Mutex::Autolock lock(mLock);
88 Mutex::Autolock lock(mLock);
95 Mutex::Autolock lock(mLock);
102 Mutex::Autolock lock(mLock);
109 Mutex::Autolock lock(mLock);
116 Mutex::Autolock lock(mLock);
124 Mutex::Autolock lock(mLock);
132 Mutex::Autolock lock(mLock)
    [all...]
  /external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/
ShadowPowerManagerTest.java 38 PowerManager.WakeLock lock = powerManager.newWakeLock(0, "TAG"); local
39 assertThat(lock.isHeld()).isFalse();
40 lock.acquire();
41 assertThat(lock.isHeld()).isTrue();
42 lock.acquire();
44 assertThat(lock.isHeld()).isTrue();
45 lock.release();
47 assertThat(lock.isHeld()).isTrue();
48 lock.release();
49 assertThat(lock.isHeld()).isFalse()
71 PowerManager.WakeLock lock = powerManager.newWakeLock(0, "TAG"); local
95 PowerManager.WakeLock lock = powerManager.newWakeLock(0, "TAG"); local
111 PowerManager.WakeLock lock = powerManager.newWakeLock(0, "TAG"); local
124 PowerManager.WakeLock lock = powerManager.newWakeLock(0, "TAG"); local
178 PowerManager.WakeLock lock = powerManager.newWakeLock(0, "TAG"); local
    [all...]
  /external/androidplot/AndroidPlot-Core/src/main/java/com/androidplot/xy/
SimpleXYSeries.java 40 lock.readLock().lock();
45 lock.readLock().unlock();
56 private ReentrantReadWriteLock lock = new ReentrantReadWriteLock(true); field in class:SimpleXYSeries
95 lock.writeLock().lock();
99 lock.writeLock().unlock();
111 lock.writeLock().lock();
155 lock.writeLock().unlock();
    [all...]
  /cts/tests/tests/telecom/src/android/telecom/cts/
ConnectionTest.java 44 final Semaphore lock = new Semaphore(0); local
45 Connection connection = createConnection(lock);
47 waitForStateChange(lock);
51 waitForStateChange(lock);
55 waitForStateChange(lock);
59 waitForStateChange(lock);
63 waitForStateChange(lock);
67 waitForStateChange(lock);
71 waitForStateChange(lock);
75 waitForStateChange(lock);
131 final Semaphore lock = new Semaphore(0); local
146 final Semaphore lock = new Semaphore(0); local
161 final Semaphore lock = new Semaphore(0); local
178 final Semaphore lock = new Semaphore(0); local
194 final Semaphore lock = new Semaphore(0); local
213 final Semaphore lock = new Semaphore(0); local
227 final Semaphore lock = new Semaphore(0); local
254 final Semaphore lock = new Semaphore(0); local
281 final Semaphore lock = new Semaphore(0); local
309 final Semaphore lock = new Semaphore(0); local
338 final Semaphore lock = new Semaphore(0); local
350 final Semaphore lock = new Semaphore(0); local
366 final Semaphore lock = new Semaphore(0); local
381 final Semaphore lock = new Semaphore(0); local
    [all...]
  /external/libchrome/base/task_scheduler/
scheduler_lock_impl.cc 27 const SchedulerLockImpl* const lock,
29 DCHECK_NE(lock, predecessor) << "Reentrant locks are unsupported.";
31 allowed_predecessor_map_[lock] = predecessor;
32 AssertSafePredecessor(lock);
35 void UnregisterLock(const SchedulerLockImpl* const lock) {
37 allowed_predecessor_map_.erase(lock);
40 void RecordAcquisition(const SchedulerLockImpl* const lock) {
41 AssertSafeAcquire(lock);
42 GetAcquiredLocksOnCurrentThread()->push_back(lock);
45 void RecordRelease(const SchedulerLockImpl* const lock) {
    [all...]

Completed in 2861 milliseconds

1 23 4 5 6 7 8 91011>>