Home | History | Annotate | Download | only in utils

Lines Matching full:refs

103             ref_entry* refs = mStrongRefs;
104 while (refs) {
105 char inc = refs->ref >= 0 ? '+' : '-';
106 LOGD("\t%c ID %p (ref %d):", inc, refs->id, refs->ref);
108 refs->stack.dump();
110 refs = refs->next;
121 ref_entry* refs = mWeakRefs;
122 while (refs) {
123 char inc = refs->ref >= 0 ? '+' : '-';
124 LOGD("\t%c ID %p (ref %d):", inc, refs->id, refs->ref);
126 refs->stack.dump();
128 refs = refs->next;
224 void addRef(ref_entry** refs, const void* id, int32_t mRef)
238 ref->next = *refs;
239 *refs = ref;
243 void removeRef(ref_entry** refs, const void* id)
248 ref_entry* const head = *refs;
252 *refs = ref->next;
256 refs = &ref->next;
257 ref = *refs;
297 void printRefsLocked(String8* out, const ref_entry* refs) const
300 while (refs) {
301 char inc = refs->ref >= 0 ? '+' : '-';
303 inc, refs->id, refs->ref);
306 out->append(refs->stack.toString("\t\t"));
310 refs = refs->next;
330 weakref_impl* const refs = mRefs;
331 refs->incWeak(id);
333 refs->addStrongRef(id);
334 const int32_t c = android_atomic_inc(&refs->mStrong);
335 LOG_ASSERT(c > 0, "incStrong() called on %p after last strong ref", refs);
343 android_atomic_add(-INITIAL_STRONG_VALUE, &refs->mStrong);
344 refs->mBase->onFirstRef();
349 weakref_impl* const refs = mRefs;
350 refs->removeStrongRef(id);
351 const int32_t c = android_atomic_dec(&refs->mStrong);
355 LOG_ASSERT(c >= 1, "decStrong() called on %p too many times", refs);
357 refs->mBase->onLastStrongRef(id);
358 if ((refs->mFlags&OBJECT_LIFETIME_MASK) == OBJECT_LIFETIME_STRONG) {
362 refs->decWeak(id);
367 weakref_impl* const refs = mRefs;
368 refs->incWeak(id);
370 refs->addStrongRef(id);
371 const int32_t c = android_atomic_inc(&refs->mStrong);
373 refs);
380 android_atomic_add(-INITIAL_STRONG_VALUE, &refs->mStrong);
383 refs->mBase->onFirstRef();
424 // LOGV("Freeing refs %p of old RefBase %p\n", this, impl->mBase);