{"type": "func", "start": 6442481024, "end": 6442481128, "name": "cocos2d::CCAutoreleasePool::clear", "pseudocode": "// \n// cocos2d::CCAutoreleasePool::clear from 0x180007580 to 0x1800075e8 (104 bytes)\n// \n// 4 xrefs:\n// > cocos2d::CCPoolManager::finalize @ 0x180007638\n// > cocos2d::CCPoolManager::pop @ 0x1800076b3\n// > <???> @ 0x1801438a8\n// > <???> @ 0x1801ada68\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nvoid __fastcall cocos2d::CCAutoreleasePool::clear(cocos2d::CCAutoreleasePool *this)\n{\n  cocos2d::CCArray *m_pManagedObjectArray; // rax\n  cocos2d::ccArray *data; // rdx\n  __int64 num; // rax\n  cocos2d::CCObject **arr; // rdx\n  cocos2d::CCObject **i; // rcx\n\n  if ( (unsigned int)cocos2d::CCArray::count(this->m_pManagedObjectArray) )\n  {\n    m_pManagedObjectArray = this->m_pManagedObjectArray;\n    if ( m_pManagedObjectArray )\n    {\n      data = m_pManagedObjectArray->data;\n      num = data->num;\n      if ( (_DWORD)num )\n      {\n        arr = data->arr;\n        for ( i = &arr[num - 1]; i >= arr; --i )\n        {\n          if ( !*i )\n            break;\n          --(*i)->m_uAutoReleaseCount;\n        }\n      }\n    }\n    cocos2d::CCArray::removeAllObjects(this->m_pManagedObjectArray);\n  }\n}", "assembly": "; \n; cocos2d::CCAutoreleasePool::clear from 0x180007580 to 0x1800075e8 (104 bytes)\n; \n; 4 xrefs:\n; > cocos2d::CCPoolManager::finalize @ 0x180007638\n; > cocos2d::CCPoolManager::pop @ 0x1800076b3\n; > <???> @ 0x1801438a8\n; > <???> @ 0x1801ada68\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\npush    rbx                                                            ; +0x0, 0x180007580\nsub     rsp, 20h                                                       ; +0x2, 0x180007582\nmov     rbx, rcx                                                       ; +0x6, 0x180007586\nmov     rcx, [rcx+38h]; this                                           ; +0x9, 0x180007589\ncall    ?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0xd, 0x18000758d\ntest    eax, eax                                                       ; +0x12, 0x180007592\njz      short loc_1800075E2                                            ; +0x14, 0x180007594\nmov     rax, [rbx+38h]                                                 ; +0x16, 0x180007596\ntest    rax, rax                                                       ; +0x1a, 0x18000759a\njz      short loc_1800075D4                                            ; +0x1d, 0x18000759d\nmov     rdx, [rax+38h]                                                 ; +0x1f, 0x18000759f\nmov     eax, [rdx]                                                     ; +0x23, 0x1800075a3\ntest    eax, eax                                                       ; +0x25, 0x1800075a5\njz      short loc_1800075D4                                            ; +0x27, 0x1800075a7\nmov     rdx, [rdx+10h]                                                 ; +0x29, 0x1800075a9\nlea     rcx, [rax-1]                                                   ; +0x2d, 0x1800075ad\nlea     rcx, [rdx+rcx*8]                                               ; +0x31, 0x1800075b1\ncmp     rcx, rdx                                                       ; +0x35, 0x1800075b5\njb      short loc_1800075D4                                            ; +0x38, 0x1800075b8\nnop     word ptr [rax+rax+00h]                                         ; +0x3a, 0x1800075ba\nmov     rax, [rcx]                                                     ; +0x40, 0x1800075c0\ntest    rax, rax                                                       ; +0x43, 0x1800075c3\njz      short loc_1800075D4                                            ; +0x46, 0x1800075c6\ndec     dword ptr [rax+18h]                                            ; +0x48, 0x1800075c8\nsub     rcx, 8                                                         ; +0x4b, 0x1800075cb\ncmp     rcx, rdx                                                       ; +0x4f, 0x1800075cf\njnb     short loc_1800075C0                                            ; +0x52, 0x1800075d2\nmov     rcx, [rbx+38h]; this                                           ; +0x54, 0x1800075d4\nadd     rsp, 20h                                                       ; +0x58, 0x1800075d8\npop     rbx                                                            ; +0x5c, 0x1800075dc\njmp     ?removeAllObjects@CCArray@cocos2d@@QEAAXXZ; cocos2d::CCArray::removeAllObjects(void) ; +0x5d, 0x1800075dd\nadd     rsp, 20h                                                       ; +0x62, 0x1800075e2\npop     rbx                                                            ; +0x66, 0x1800075e6\nretn                                                                   ; +0x67, 0x1800075e7", "xrefs": ["cocos2d::CCPoolManager::finalize @ 0x180007638", "cocos2d::CCPoolManager::pop @ 0x1800076b3", "<???> @ 0x1801438a8", "<???> @ 0x1801ada68"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}