Lines Matching refs:id
235 ALOGD("\t%c ID %p (ref %d):", inc, refs->id, refs->ref); in ~weakref_impl()
249 ALOGD("\t%c ID %p (ref %d):", inc, refs->id, refs->ref); in ~weakref_impl()
264 void addStrongRef(const void* id) { in addStrongRef() argument
267 addRef(&mStrongRefs, id, mStrong.load(std::memory_order_relaxed)); in addStrongRef()
270 void removeStrongRef(const void* id) { in removeStrongRef() argument
274 removeRef(&mStrongRefs, id); in removeStrongRef()
276 addRef(&mStrongRefs, id, -mStrong.load(std::memory_order_relaxed)); in removeStrongRef()
287 void addWeakRef(const void* id) { in addWeakRef() argument
288 addRef(&mWeakRefs, id, mWeak.load(std::memory_order_relaxed)); in addWeakRef()
291 void removeWeakRef(const void* id) { in removeWeakRef() argument
293 removeRef(&mWeakRefs, id); in removeWeakRef()
295 addRef(&mWeakRefs, id, -mWeak.load(std::memory_order_relaxed)); in removeWeakRef()
346 const void* id; member
353 void addRef(ref_entry** refs, const void* id, int32_t mRef) in addRef() argument
363 ref->id = id; in addRef()
372 void removeRef(ref_entry** refs, const void* id) in removeRef() argument
380 if (ref->id == id) { in removeRef()
391 id, mBase, this); in removeRef()
396 ALOGD("\t%c ID %p (ref %d):", inc, ref->id, ref->ref); in removeRef()
412 if (ref->id == old_id) { in renameRefsId()
413 ref->id = new_id; in renameRefsId()
426 inc, refs->id, refs->ref); in printRefsLocked()
451 void RefBase::incStrong(const void* id) const in incStrong()
454 refs->incWeak(id); in incStrong()
456 refs->addStrongRef(id); in incStrong()
460 ALOGD("incStrong of %p from %p: cnt=%d\n", this, id, c); in incStrong()
474 void RefBase::incStrongRequireStrong(const void* id) const { in incStrongRequireStrong()
476 refs->incWeak(id); in incStrongRequireStrong()
478 refs->addStrongRef(id); in incStrongRequireStrong()
484 ALOGD("incStrong (requiring strong) of %p from %p: cnt=%d\n", this, id, c); in incStrongRequireStrong()
488 void RefBase::decStrong(const void* id) const in decStrong()
491 refs->removeStrongRef(id); in decStrong()
494 ALOGD("decStrong of %p from %p: cnt=%d\n", this, id, c); in decStrong()
500 refs->mBase->onLastStrongRef(id); in decStrong()
518 refs->decWeak(id); in decStrong()
521 void RefBase::forceIncStrong(const void* id) const in forceIncStrong()
526 refs->incWeak(id); in forceIncStrong()
528 refs->addStrongRef(id); in forceIncStrong()
533 ALOGD("forceIncStrong of %p from %p: cnt=%d\n", this, id, c); in forceIncStrong()
557 void RefBase::weakref_type::incWeak(const void* id) in incWeak() argument
560 impl->addWeakRef(id); in incWeak()
566 void RefBase::weakref_type::incWeakRequireWeak(const void* id) in incWeakRequireWeak() argument
569 impl->addWeakRef(id); in incWeakRequireWeak()
575 void RefBase::weakref_type::decWeak(const void* id) in decWeak() argument
578 impl->removeWeakRef(id); in decWeak()
609 impl->mBase->onLastWeakRef(id); in decWeak()
614 bool RefBase::weakref_type::attemptIncStrong(const void* id) in attemptIncStrong() argument
616 incWeak(id); in attemptIncStrong()
646 decWeak(id); in attemptIncStrong()
666 decWeak(id); in attemptIncStrong()
673 if (!impl->mBase->onIncStrongAttempted(FIRST_INC_STRONG, id)) { in attemptIncStrong()
675 decWeak(id); in attemptIncStrong()
687 impl->mBase->onLastStrongRef(id); in attemptIncStrong()
692 impl->addStrongRef(id); in attemptIncStrong()
695 ALOGD("attemptIncStrong of %p from %p: cnt=%d\n", this, id, curCount); in attemptIncStrong()
713 bool RefBase::weakref_type::attemptIncWeak(const void* id) in attemptIncWeak() argument
729 impl->addWeakRef(id); in attemptIncWeak()
752 RefBase::weakref_type* RefBase::createWeak(const void* id) const in createWeak()
754 mRefs->incWeak(id); in createWeak()