SideTable& table = SideTables()[this];
size_t& refcntStorage = table.refcnts[this];
refcntStorage += SIDE_TABLE_RC_ONE;
复制代码
SideTable& table = SideTables()[this];
RefcountMap::iterator it = table.refcnts.find(this);
it->second -= SIDE_TABLE_RC_ONE;
复制代码
SideTable& table = SideTables()[this];
size_t refcnt_result = 1;
RefcountMap::iterator it = table.refcnts.find(this);
refcnt_result += it->second >> SIDE_TABLE_RC_SHIFT;
复制代码
5.dealloc 数据结构
{
id __weak obj1 = obj;
}
{
id obj1;
objc_initWeak(&obj1, obj);
}
复制代码
void *ctx = objc_autoreleasePoolPush();
...
objc_autoreleasePoolPop(ctx);
复制代码
void *objc_autoreleasePoolPush(void) <=> void *AutoreleasePoolPage::push(void)
void objc_autoreleasePoolPop(void* ctx) <=> AutoreleasePoolPage::pop(void* ctx)
复制代码