/third_party/skia/third_party/externals/dawn/src/tests/unittests/ |
H A D | ObjectBaseTests.cpp | 37 int refcount = 1; in TEST() local 39 Object obj(&refcount); in TEST() 40 ASSERT_EQ(2, refcount); in TEST() 42 ASSERT_EQ(1, refcount); in TEST() 47 int refcount = 1; in TEST() local 49 Object object = Object::Acquire(&refcount); in TEST() 50 ASSERT_EQ(1, refcount); in TEST() 52 ASSERT_EQ(0, refcount); in TEST() 57 int refcount = 1; in TEST() local 59 Object obj1(&refcount); in TEST() 69 int refcount = 1; TEST() local 83 int refcount = 1; TEST() local 94 int refcount = 1; TEST() local 109 int refcount = 1; TEST() local 125 int refcount = 1; TEST() local 143 int refcount = 1; TEST() local 157 int refcount = 1; TEST() local 171 int refcount = 1; TEST() local 187 int refcount = 1; TEST() local 207 int refcount = 1; TEST() local [all...] |
/third_party/NuttX/drivers/usbdev/gadget/fconfig/include/ |
H A D | obj_ref.h | 60 atomic_t refcount; member 65 atomic_set(&ref->refcount, val); in objref_init() 70 atomic_inc(&ref->refcount); in objref_get() 75 if (atomic_dec_and_test(&ref->refcount)) in objref_put() 85 return atomic_read(&ref->refcount); in objref_read()
|
/third_party/skia/third_party/externals/dawn/src/dawn_wire/client/ |
H A D | ObjectBase.h | 33 ObjectBase(Client* client, uint32_t refcount, uint32_t id) in ObjectBase() 34 : client(client), refcount(refcount), id(id) { in ObjectBase() 45 uint32_t refcount; member
|
/third_party/skia/third_party/externals/abseil-cpp/absl/strings/internal/ |
H A D | cordz_info.cc | 58 // CordSubstring A (refcount = 5) --> child Flat C (refcount = 2) 59 // CordSubstring B (refcount = 9) --> child Flat C (refcount = 2) 61 // Flat C has 2 incoming edges from the 2 substrings (refcount = 2) and is not 63 // attribute 50% of the memory (memory / refcount = 2) to each incoming edge. 64 // Rep A has a refcount of 5, so we attribute each incoming edge 1 / 5th of the 66 // is then 'memory C / (refcount C * refcount A) + (memory A / refcount 81 size_t refcount = rep->refcount.Get(); AnalyzeCordRep() local 113 size_t refcount; global() member [all...] |
H A D | cord_internal.h | 96 // Asserts that the current refcount is greater than 0. If the refcount is 104 int32_t refcount = count_.load(std::memory_order_acquire) & kRefcountMask; in Decrement() local 105 assert(refcount > 0 || refcount & kImmortalFlag); in Decrement() 106 return refcount != kRefIncrement && in Decrement() 111 // Same as Decrement but expect that refcount is greater than 1. 113 int32_t refcount = in DecrementExpectHighRefcount() local 116 assert(refcount > 0 || refcount in DecrementExpectHighRefcount() 214 RefcountAndFlags refcount; global() member [all...] |
H A D | cord_internal.cc | 41 assert(!rep->refcount.IsImmortal()); in Destroy() 45 if (!right->refcount.Decrement()) { in Destroy() 51 if (!left->refcount.Decrement()) { in Destroy() 69 if (!child->refcount.Decrement()) { in Destroy()
|
H A D | cord_rep_consume_test.cc | 99 EXPECT_TRUE(rep->refcount.IsOne()); in TEST() 116 EXPECT_FALSE(rep->refcount.IsOne()); in TEST() 134 EXPECT_TRUE(rep->refcount.IsOne()); in TEST() 151 EXPECT_FALSE(rep->refcount.IsOne()); in TEST() 166 EXPECT_TRUE(flat2->refcount.IsOne()); in TEST()
|
/third_party/skia/third_party/externals/dawn/src/dawn_native/ |
H A D | BuddyMemoryAllocator.cpp | 68 if (mTrackedSubAllocations[memoryIndex].refcount == 0) { in Allocate() 72 mTrackedSubAllocations[memoryIndex] = {/*refcount*/ 0, std::move(memory)}; in Allocate() 75 mTrackedSubAllocations[memoryIndex].refcount++; in Allocate() 95 ASSERT(mTrackedSubAllocations[memoryIndex].refcount > 0); in Deallocate() 96 mTrackedSubAllocations[memoryIndex].refcount--; in Deallocate() 98 if (mTrackedSubAllocations[memoryIndex].refcount == 0) { in Deallocate() 113 if (allocation.refcount > 0) { in ComputeTotalNumOfHeapsForTesting()
|
/third_party/libwebsockets/lib/misc/lwsac/ |
H A D | lwsac.c | 312 lachead->refcount++; in lwsac_reference() 313 lwsl_debug("%s: head %p: (det %d) refcount -> %d\n", in lwsac_reference() 314 __func__, head, lachead->detached, lachead->refcount); in lwsac_reference() 327 if (!lachead->refcount) in lwsac_unreference() 328 lwsl_warn("%s: refcount going below zero\n", __func__); in lwsac_unreference() 330 lachead->refcount--; in lwsac_unreference() 332 lwsl_debug("%s: head %p: (det %d) refcount -> %d\n", in lwsac_unreference() 333 __func__, *head, lachead->detached, lachead->refcount); in lwsac_unreference() 335 if (lachead->detached && !lachead->refcount) { in lwsac_unreference() 352 if (!lachead->refcount) { in lwsac_detach() [all...] |
H A D | cached-file.c | 83 lachead->refcount++; in lwsac_use_cached_file_start() 84 // lwsl_debug("%s: html refcount: %d\n", __func__, lachead->refcount); in lwsac_use_cached_file_start() 99 if (!lachead->refcount) in lwsac_use_cached_file_end() 100 lwsl_err("%s: html refcount zero on entry\n", __func__); in lwsac_use_cached_file_end() 102 if (lachead->refcount && !--lachead->refcount && lachead->detached) { in lwsac_use_cached_file_end() 118 if (lachead->refcount) in lwsac_use_cached_file_detach()
|
/third_party/python/Doc/tools/extensions/ |
H A D | c_annotations.py | 9 refcount.py and anno-api.py in the old Python documentation tools. 75 function, type, arg, refcount, comment = parts 81 if not refcount or refcount == "null": 82 refcount = None 84 refcount = int(refcount) 88 entry.args.append((arg, type, refcount)) 91 entry.result_refs = refcount 172 node.insert(0, nodes.emphasis(rc, rc, classes=['refcount'])) [all...] |
/third_party/ffmpeg/libavfilter/ |
H A D | formats.c | 39 if (!(tmp = av_realloc_array(ret->refs, ret->refcount + a->refcount, \ 44 for (i = 0; i < a->refcount; i ++) { \ 45 ret->refs[ret->refcount] = a->refs[i]; \ 46 *ret->refs[ret->refcount++] = ret; \ 101 av_assert2(check || (a->refcount && b->refcount)); in merge_formats_internal() 155 * Both a and b must have owners (i.e. refcount > 0) for these functions. 186 av_assert2(check || (a->refcount && b->refcount)); in merge_samplerates_internal() [all...] |
/third_party/mesa3d/src/virtio/vulkan/ |
H A D | vn_renderer.h | 12 struct vn_refcount refcount; member 23 struct vn_refcount refcount; member 288 assert(vn_refcount_is_valid(&shmem->refcount)); in vn_renderer_shmem_create() 301 vn_refcount_inc(&shmem->refcount); in vn_renderer_shmem_ref() 309 if (vn_refcount_dec(&shmem->refcount)) in vn_renderer_shmem_unref() 328 assert(vn_refcount_is_valid(&bo->refcount)); in vn_renderer_bo_create_from_device_memory() 349 assert(vn_refcount_is_valid(&bo->refcount)); in vn_renderer_bo_create_from_dma_buf() 360 vn_refcount_inc(&bo->refcount); in vn_renderer_bo_ref() 367 if (vn_refcount_dec(&bo->refcount)) in vn_renderer_bo_unref()
|
/third_party/eudev/src/libudev/ |
H A D | libudev-queue.c | 48 int refcount; member 56 * The initial refcount is 1, and needs to be decremented to 72 udev_queue->refcount = 1; in udev_queue_new() 91 udev_queue->refcount++; in udev_queue_ref() 99 * Drop a reference of a udev queue context. If the refcount reaches zero, 109 udev_queue->refcount--; in udev_queue_unref() 110 if (udev_queue->refcount > 0) in udev_queue_unref()
|
/third_party/libwebsockets/lib/system/async-dns/ |
H A D | async-dns.c | 95 lwsl_wsi_debug(w, "q: %p, c: %p, refcount %d -> %d", in lws_async_dns_complete() 96 q, c, c->refcount, c->refcount + 1); in lws_async_dns_complete() 97 c->refcount++; in lws_async_dns_complete() 114 lwsl_wsi_debug(q->dns ? q->dns->wsi : NULL, "q: %p, c: %p, refcount %d -> %d", in lws_async_dns_complete() 115 q, c, c->refcount, c->refcount + 1); in lws_async_dns_complete() 116 c->refcount++; in lws_async_dns_complete() 434 c->incomplete, c->flags, c->refcount, c->results); in lws_adns_dump() 513 lwsl_debug("%s: c %p, %s, refcount in lws_async_dns_freeaddrinfo() [all...] |
/third_party/eudev/src/udev/ |
H A D | udev-ctrl.c | 53 int refcount; member 59 int refcount; member 70 int refcount; member 83 uctrl->refcount = 1; in udev_ctrl_new_from_fd() 146 uctrl->refcount++; in udev_ctrl_ref() 152 if (uctrl && -- uctrl->refcount == 0) { in udev_ctrl_unref() 196 conn->refcount = 1; in udev_ctrl_get_connection() 243 conn->refcount++; in udev_ctrl_connection_ref() 248 if (conn && -- conn->refcount == 0) { in udev_ctrl_connection_unref() 363 uctrl_msg->refcount in udev_ctrl_receive_msg() [all...] |
/third_party/ffmpeg/libavutil/ |
H A D | buffer.c | 40 atomic_init(&buf->refcount, 1); in buffer_create() 112 atomic_fetch_add_explicit(&buf->buffer->refcount, 1, memory_order_relaxed); in av_buffer_ref() 129 if (atomic_fetch_sub_explicit(&b->refcount, 1, memory_order_acq_rel) == 1) { in buffer_replace() 152 return atomic_load(&buf->buffer->refcount) == 1; in av_buffer_is_writable() 162 return atomic_load(&buf->buffer->refcount); in av_buffer_get_ref_count() 275 atomic_init(&pool->refcount, 1); in av_buffer_pool_init2() 291 atomic_init(&pool->refcount, 1); in av_buffer_pool_init() 335 if (atomic_fetch_sub_explicit(&pool->refcount, 1, memory_order_acq_rel) == 1) in av_buffer_pool_uninit() 352 if (atomic_fetch_sub_explicit(&pool->refcount, 1, memory_order_acq_rel) == 1) in pool_release_buffer() 409 atomic_fetch_add_explicit(&pool->refcount, in av_buffer_pool_get() [all...] |
/third_party/mesa3d/src/gallium/frontends/nine/ |
H A D | nine_buffer_upload.c | 46 unsigned refcount; /* How many sub-buffers live inside the buffer */ member 92 group->refcount = 0; in nine_upload_create_buffer_group() 122 assert(group->refcount == 0); in nine_upload_destroy_buffer_group() 257 group->refcount += 1; in nine_upload_create_buffer() 270 buf->parent->refcount--; in nine_upload_release_buffer() 271 if (buf->parent->refcount == 0) { in nine_upload_release_buffer() 290 DBG("%d\n", buf->parent->refcount); in nine_upload_buffer_get_map()
|
/third_party/mesa3d/src/gallium/winsys/nouveau/drm/ |
H A D | nouveau_drm_winsys.c | 29 if (screen->refcount == -1) in nouveau_drm_screen_unref() 33 ret = --screen->refcount; in nouveau_drm_screen_unref() 61 screen->refcount++; in nouveau_drm_screen_create() 127 screen->refcount = 1; in nouveau_drm_screen_create()
|
/third_party/mesa3d/src/vulkan/runtime/ |
H A D | vk_sync_timeline.c | 199 assert(point->refcount == 0 && !point->pending); in vk_sync_timeline_point_free_locked() 217 point->refcount++; in vk_sync_timeline_point_ref() 224 assert(point->refcount > 0); in vk_sync_timeline_point_unref() 225 point->refcount--; in vk_sync_timeline_point_unref() 226 if (point->refcount == 0 && !point->pending) in vk_sync_timeline_point_unref() 243 if (point->refcount == 0) in vk_sync_timeline_point_complete() 269 assert(point->refcount >= 0); in vk_sync_timeline_gc_locked() 270 if (point->refcount > 0 && !drain) in vk_sync_timeline_gc_locked() 303 assert(point->refcount == 0); in vk_sync_timeline_point_install()
|
/third_party/wpa_supplicant/wpa_supplicant-2.9/src/l2_packet/ |
H A D | l2_packet_ndis.c | 54 int refcount; member 309 l2 = l2_ndisuio_global->l2[l2_ndisuio_global->refcount - 1]; in l2_packet_rx_event() 362 if (l2_ndisuio_global->refcount >= 2) { in l2_packet_init() 367 l2_ndisuio_global->refcount++; in l2_packet_init() 372 l2_ndisuio_global->l2[l2_ndisuio_global->refcount - 1] = l2; in l2_packet_init() 387 if (l2_ndisuio_global->refcount > 1) { in l2_packet_init() 471 l2_ndisuio_global->refcount--; in l2_packet_deinit() 472 l2_ndisuio_global->l2[l2_ndisuio_global->refcount] = NULL; in l2_packet_deinit() 473 if (l2_ndisuio_global->refcount) { in l2_packet_deinit()
|
/third_party/wpa_supplicant/wpa_supplicant-2.9_standard/src/l2_packet/ |
H A D | l2_packet_ndis.c | 54 int refcount; member 310 l2 = l2_ndisuio_global->l2[l2_ndisuio_global->refcount - 1]; in l2_packet_rx_event() 363 if (l2_ndisuio_global->refcount >= 2) { in l2_packet_init() 368 l2_ndisuio_global->refcount++; in l2_packet_init() 373 l2_ndisuio_global->l2[l2_ndisuio_global->refcount - 1] = l2; in l2_packet_init() 388 if (l2_ndisuio_global->refcount > 1) { in l2_packet_init() 472 l2_ndisuio_global->refcount--; in l2_packet_deinit() 473 l2_ndisuio_global->l2[l2_ndisuio_global->refcount] = NULL; in l2_packet_deinit() 474 if (l2_ndisuio_global->refcount) { in l2_packet_deinit()
|
/third_party/mesa3d/src/drm-shim/ |
H A D | device.c | 120 p_atomic_set(&shim_fd->refcount, 1); in drm_shim_file_create() 138 p_atomic_inc(&shim_fd->refcount); in drm_shim_fd_register() 157 if (!p_atomic_dec_zero(&shim_fd->refcount)) in drm_shim_fd_unregister() 352 p_atomic_inc(&bo->refcount); in drm_shim_bo_lookup() 360 p_atomic_inc(&bo->refcount); in drm_shim_bo_get() 366 if (p_atomic_dec_return(&bo->refcount) == 0) in drm_shim_bo_put()
|
/third_party/node/test/js-native-api/test_reference/ |
H A D | test_reference.c | 162 uint32_t refcount; in IncrementRefcount() local 163 NODE_API_CALL(env, napi_reference_ref(env, test_reference, &refcount)); in IncrementRefcount() 166 NODE_API_CALL(env, napi_create_uint32(env, refcount, &result)); in IncrementRefcount() 174 uint32_t refcount; in DecrementRefcount() local 175 NODE_API_CALL(env, napi_reference_unref(env, test_reference, &refcount)); in DecrementRefcount() 178 NODE_API_CALL(env, napi_create_uint32(env, refcount, &result)); in DecrementRefcount()
|
/third_party/mesa3d/src/gallium/drivers/crocus/ |
H A D | crocus_bufmgr.h | 90 int refcount; member 192 p_atomic_inc(&bo->refcount); in crocus_bo_reference() 216 assert(p_atomic_read(&bo->refcount) > 0); in crocus_bo_unreference() 218 if (atomic_add_unless(&bo->refcount, -1, 1)) { in crocus_bo_unreference() 245 * Reduces the refcount on the userspace mapping of the buffer
|