Lines Matching defs:TSD
61 ALWAYS_INLINE TSD<Allocator> *getTSDAndLock(bool *UnlockRequired) {
62 TSD<Allocator> *TSD = getCurrentTSD();
63 DCHECK(TSD);
66 if (TSD->tryLock())
67 return TSD;
69 return getTSDAndLockSlow(TSD);
85 ALWAYS_INLINE void setCurrentTSD(TSD<Allocator> *CurrentTSD) {
97 ALWAYS_INLINE TSD<Allocator> *getCurrentTSD() {
99 return reinterpret_cast<TSD<Allocator> *>(*getAndroidTlsPtr());
103 return reinterpret_cast<TSD<Allocator> *>(pthread_getspecific(PThreadKey));
122 NOINLINE TSD<Allocator> *getTSDAndLockSlow(TSD<Allocator> *CurrentTSD) {
124 // Use the Precedence of the current TSD as our random seed. Since we are
131 TSD<Allocator> *CandidateTSD = nullptr;
139 // A 0 precedence here means another thread just locked this TSD.
166 TSD<Allocator> TSDs[MaxTSDCount];
168 static THREADLOCAL TSD<Allocator> *ThreadTSD;
174 THREADLOCAL TSD<Allocator>