Home
last modified time | relevance | path

Searched refs:memory_order_relaxed (Results 1 – 25 of 70) sorted by relevance

123

/external/compiler-rt/lib/sanitizer_common/tests/
Dsanitizer_atomic_test.cc55 CheckStoreLoad<atomic_uint8_t, memory_order_relaxed, memory_order_relaxed>(); in TEST()
56 CheckStoreLoad<atomic_uint8_t, memory_order_consume, memory_order_relaxed>(); in TEST()
57 CheckStoreLoad<atomic_uint8_t, memory_order_acquire, memory_order_relaxed>(); in TEST()
58 CheckStoreLoad<atomic_uint8_t, memory_order_relaxed, memory_order_release>(); in TEST()
61 CheckStoreLoad<atomic_uint16_t, memory_order_relaxed, memory_order_relaxed>(); in TEST()
62 CheckStoreLoad<atomic_uint16_t, memory_order_consume, memory_order_relaxed>(); in TEST()
63 CheckStoreLoad<atomic_uint16_t, memory_order_acquire, memory_order_relaxed>(); in TEST()
64 CheckStoreLoad<atomic_uint16_t, memory_order_relaxed, memory_order_release>(); in TEST()
67 CheckStoreLoad<atomic_uint32_t, memory_order_relaxed, memory_order_relaxed>(); in TEST()
68 CheckStoreLoad<atomic_uint32_t, memory_order_consume, memory_order_relaxed>(); in TEST()
[all …]
/external/clang/test/Sema/
Datomic-ops.c100 int load_n_1 = __atomic_load_n(I, memory_order_relaxed); in f()
101 int *load_n_2 = __atomic_load_n(P, memory_order_relaxed); in f()
102 …float load_n_3 = __atomic_load_n(D, memory_order_relaxed); // expected-error {{must be a pointer t… in f()
103 …__atomic_load_n(s1, memory_order_relaxed); // expected-error {{must be a pointer to integer or poi… in f()
105 …__atomic_load(i, I, memory_order_relaxed); // expected-error {{must be a pointer to a trivially-co… in f()
106 …__atomic_load(I, i, memory_order_relaxed); // expected-warning {{passing '_Atomic(int) *' to param… in f()
107 __atomic_load(I, *P, memory_order_relaxed); in f()
108 __atomic_load(I, *P, memory_order_relaxed, 42); // expected-error {{too many arguments}} in f()
198 int k = atomic_load_explicit(&n, memory_order_relaxed); in f()
199 atomic_store_explicit(&n, k, memory_order_relaxed); in f()
[all …]
/external/compiler-rt/lib/sanitizer_common/
Dsanitizer_addrhashmap.h184 if (atomic_load(&b->add, memory_order_relaxed)) { in acquire()
186 AddBucket *add = (AddBucket*)atomic_load(&b->add, memory_order_relaxed); in acquire()
189 uptr addr1 = atomic_load(&c->addr, memory_order_relaxed); in acquire()
205 uptr addr1 = atomic_load(&c->addr, memory_order_relaxed); in acquire()
217 AddBucket *add = (AddBucket*)atomic_load(&b->add, memory_order_relaxed); in acquire()
221 uptr addr1 = atomic_load(&c->addr, memory_order_relaxed); in acquire()
245 uptr addr1 = atomic_load(&c->addr, memory_order_relaxed); in acquire()
260 atomic_store(&b->add, (uptr)add, memory_order_relaxed); in acquire()
272 atomic_store(&b->add, (uptr)add1, memory_order_relaxed); in acquire()
278 CHECK_EQ(atomic_load(&c->addr, memory_order_relaxed), 0); in acquire()
[all …]
Dsanitizer_mutex.h26 atomic_store(&state_, 0, memory_order_relaxed); in Init()
44 CHECK_EQ(atomic_load(&state_, memory_order_relaxed), 1); in CheckLocked()
56 if (atomic_load(&state_, memory_order_relaxed) == 0 in LockSlow()
96 atomic_store(&state_, kUnlocked, memory_order_relaxed); in RWMutex()
100 CHECK_EQ(atomic_load(&state_, memory_order_relaxed), kUnlocked); in ~RWMutex()
132 CHECK_NE(atomic_load(&state_, memory_order_relaxed), kUnlocked); in CheckLocked()
150 u32 cmp = atomic_load(&state_, memory_order_relaxed); in LockSlow()
Dsanitizer_coverage_libcdep.cc198 atomic_store(&pc_array_index, 0, memory_order_relaxed); in Enable()
200 atomic_store(&pc_array_size, 0, memory_order_relaxed); in Enable()
202 atomic_store(&pc_array_size, kPcArrayMaxSize, memory_order_relaxed); in Enable()
207 atomic_store(&cc_array_size, kCcArrayMaxSize, memory_order_relaxed); in Enable()
208 atomic_store(&cc_array_index, 0, memory_order_relaxed); in Enable()
227 uptr idx = atomic_fetch_add(&pc_array_index, 1, memory_order_relaxed); in InitializeGuardArray()
256 atomic_store(&pc_array_index, 0, memory_order_relaxed); in ReinitializeGuards()
267 uptr size = atomic_load(&pc_array_size, memory_order_relaxed); in ReInit()
277 CHECK_EQ(atomic_load(&pc_array_index, memory_order_relaxed), 0); in ReInit()
296 uptr size = atomic_load(&pc_array_size, memory_order_relaxed); in Extend()
[all …]
Dsanitizer_atomic_clang_other.h27 DCHECK(mo & (memory_order_relaxed | memory_order_consume in atomic_load()
34 if (mo == memory_order_relaxed) { in atomic_load()
64 DCHECK(mo & (memory_order_relaxed | memory_order_release in atomic_store()
70 if (mo == memory_order_relaxed) { in atomic_store()
Dsanitizer_atomic_clang_x86.h30 DCHECK(mo & (memory_order_relaxed | memory_order_consume in atomic_load()
37 if (mo == memory_order_relaxed) { in atomic_load()
76 DCHECK(mo & (memory_order_relaxed | memory_order_release in atomic_store()
82 if (mo == memory_order_relaxed) { in atomic_store()
Dsanitizer_lfstack.h29 atomic_store(&head_, 0, memory_order_relaxed); in Clear()
33 return (atomic_load(&head_, memory_order_relaxed) & kPtrMask) == 0; in Empty()
37 u64 cmp = atomic_load(&head_, memory_order_relaxed); in Push()
Dsanitizer_stackdepot.cc40 atomic_load(&hash_and_use_count, memory_order_relaxed) & kHashMask; in eq()
75 atomic_store(&hash_and_use_count, hash & kHashMask, memory_order_relaxed); in store()
92 return atomic_load(&node_->hash_and_use_count, memory_order_relaxed) & in use_count()
97 atomic_fetch_add(&node_->hash_and_use_count, 1, memory_order_relaxed) & in inc_use_count_unsafe()
Dsanitizer_quarantine.h128 return atomic_load(&size_, memory_order_relaxed); in Size()
146 atomic_store(&c->size_, 0, memory_order_relaxed); in Transfer()
168 atomic_store(&size_, Size() + add, memory_order_relaxed); in SizeAdd()
171 atomic_store(&size_, Size() - sub, memory_order_relaxed); in SizeSub()
Dsanitizer_tls_get_addr.cc50 atomic_fetch_sub(&number_of_live_dtls, 1, memory_order_relaxed); in DTLS_Deallocate()
60 atomic_fetch_add(&number_of_live_dtls, 1, memory_order_relaxed); in DTLS_Resize()
93 atomic_load(&number_of_live_dtls, memory_order_relaxed)); in DTLS_on_tls_get_addr()
Dsanitizer_atomic_msvc.h70 DCHECK(mo & (memory_order_relaxed | memory_order_consume in atomic_load()
75 if (mo == memory_order_relaxed) { in atomic_load()
87 DCHECK(mo & (memory_order_relaxed | memory_order_release in atomic_store()
91 if (mo == memory_order_relaxed) { in atomic_store()
Dsanitizer_deadlock_detector2.cc157 atomic_store(&m->owner, 0, memory_order_relaxed); in MutexInit()
200 uptr owner = atomic_load(&m->owner, memory_order_relaxed); in MutexBeforeLock()
279 uptr owner = atomic_load(&m->owner, memory_order_relaxed); in MutexAfterLock()
291 atomic_store(&m->owner, (uptr)cb->lt, memory_order_relaxed); in MutexAfterLock()
311 uptr owner = atomic_load(&m->owner, memory_order_relaxed); in MutexBeforeUnlock()
317 atomic_store(&m->owner, 0, memory_order_relaxed); in MutexBeforeUnlock()
Dsanitizer_stoptheworld_linux_libcdep.cc223 atomic_store(&inst->arg->done, 1, memory_order_relaxed); in TracerThreadSignalHandler()
300 atomic_store(&tracer_thread_argument->done, 1, memory_order_relaxed); in TracerThread()
374 atomic_store(&tracer_thread_argument.done, 0, memory_order_relaxed); in StopTheWorld()
430 while (atomic_load(&tracer_thread_argument.done, memory_order_relaxed) == 0) in StopTheWorld()
Dsanitizer_stackdepotbase.h77 uptr cmp = atomic_load(p, memory_order_relaxed); in lock()
118 u32 id = atomic_fetch_add(&seq[part], 1, memory_order_relaxed) + 1; in Put()
170 uptr s = atomic_load(p, memory_order_relaxed); in UnlockAll()
/external/compiler-rt/lib/tsan/rtl/
Dtsan_fd.cc53 atomic_store(&s->rc, 1, memory_order_relaxed); in allocsync()
58 if (s && atomic_load(&s->rc, memory_order_relaxed) != (u64)-1) in ref()
59 atomic_fetch_add(&s->rc, 1, memory_order_relaxed); in ref()
64 if (s && atomic_load(&s->rc, memory_order_relaxed) != (u64)-1) { in unref()
117 atomic_store(&fdctx.globsync.rc, (u64)-1, memory_order_relaxed); in FdInit()
118 atomic_store(&fdctx.filesync.rc, (u64)-1, memory_order_relaxed); in FdInit()
119 atomic_store(&fdctx.socksync.rc, (u64)-1, memory_order_relaxed); in FdInit()
127 FdDesc *tab = (FdDesc*)atomic_load(&fdctx.tab[l1], memory_order_relaxed); in FdOnFork()
139 FdDesc *tab = (FdDesc*)atomic_load(&fdctx.tab[l1], memory_order_relaxed); in FdLocation()
Dtsan_mutex.cc217 atomic_store(&state_, kUnlocked, memory_order_relaxed); in Mutex()
221 CHECK_EQ(atomic_load(&state_, memory_order_relaxed), kUnlocked); in ~Mutex()
233 if (atomic_load(&state_, memory_order_relaxed) == kUnlocked) { in Lock()
284 CHECK_NE(atomic_load(&state_, memory_order_relaxed), 0); in CheckLocked()
/external/libcxx/test/std/atomics/atomics.flag/
Dtest_and_set.pass.cpp33 assert(f.test_and_set(std::memory_order_relaxed) == 0); in main()
34 assert(f.test_and_set(std::memory_order_relaxed) == 1); in main()
75 assert(f.test_and_set(std::memory_order_relaxed) == 0); in main()
76 assert(f.test_and_set(std::memory_order_relaxed) == 1); in main()
Datomic_flag_clear_explicit.pass.cpp27 atomic_flag_clear_explicit(&f, std::memory_order_relaxed); in main()
45 atomic_flag_clear_explicit(&f, std::memory_order_relaxed); in main()
Dclear.pass.cpp33 f.clear(std::memory_order_relaxed); in main()
57 f.clear(std::memory_order_relaxed); in main()
Datomic_flag_test_and_set_explicit.pass.cpp27 assert(atomic_flag_test_and_set_explicit(&f, std::memory_order_relaxed) == 0); in main()
63 assert(atomic_flag_test_and_set_explicit(&f, std::memory_order_relaxed) == 0); in main()
/external/clang/test/CodeGen/
Dbig-atomic-ops.c13 memory_order_relaxed, memory_order_consume, memory_order_acquire, enumerator
117 return __c11_atomic_load(d, memory_order_relaxed); in ff1()
140 return __c11_atomic_fetch_add(p, 1, memory_order_relaxed); in fp2()
148 return __atomic_fetch_sub(p, 4, memory_order_relaxed); in fp2a()
Datomic-ops-libcall.c4 memory_order_relaxed, memory_order_consume, memory_order_acquire, enumerator
36 return __atomic_fetch_sub(p, 4, memory_order_relaxed); in fp2a()
Datomic-ops.c152 return __c11_atomic_load(d, memory_order_relaxed); in ff1()
248 return __c11_atomic_fetch_add(p, 1, memory_order_relaxed); in fp2()
256 return __atomic_fetch_sub(p, 4, memory_order_relaxed); in fp2a()
428 __c11_atomic_compare_exchange_strong(ptr, ptr2, 43, memory_order_acquire, memory_order_relaxed); in failureOrder()
/external/compiler-rt/lib/dfsan/
Ddfsan.cc142 atomic_fetch_add(&__dfsan_last_label, 1, memory_order_relaxed) + 1; in __dfsan_union()
205 atomic_fetch_add(&__dfsan_last_label, 1, memory_order_relaxed) + 1; in dfsan_create_label()
291 atomic_load(&__dfsan_last_label, memory_order_relaxed); in dfsan_get_label_count()
299 atomic_load(&__dfsan_last_label, memory_order_relaxed); in dfsan_dump_labels()

123