{"type": "func", "start": 6443058736, "end": 6443058942, "name": "cocos2d::CCProfilingResetTimingBlock", "pseudocode": "// \n// cocos2d::CCProfilingResetTimingBlock from 0x180094630 to 0x1800946fe (206 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x1801438a8\n// > <???> @ 0x1801b6708\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\n// Hidden C++ exception states: #wind=1\nvoid __fastcall cocos2d::CCProfilingResetTimingBlock(cocos2d *this, const char *a2)\n{\n  struct cocos2d::CCProfiler *v3; // rdi\n  __int64 v4; // rbx\n  struct cocos2d::timezone *v5; // r8\n  void *v6; // rcx\n  void *Block[2]; // [rsp+20h] [rbp-38h] BYREF\n  __m128i si128; // [rsp+30h] [rbp-28h]\n\n  v3 = cocos2d::CCProfiler::sharedProfiler();\n  sub_180005910(Block, this);\n  v4 = cocos2d::CCDictionary::objectForKey((__int64)v3[1].__vftable, (unsigned __int8 *)Block);\n  if ( si128.m128i_i64[1] > 0xFuLL )\n  {\n    v6 = Block[0];\n    if ( (unsigned __int64)(si128.m128i_i64[1] + 1) >= 0x1000 )\n    {\n      v6 = *((void **)Block[0] - 1);\n      if ( (unsigned __int64)((char *)Block[0] - (char *)v6 - 8) > 0x1F )\n        invalid_parameter_noinfo_noreturn();\n    }\n    j_j_free_0(v6);\n  }\n  si128 = _mm_load_si128((const __m128i *)&xmmword_1800E7160);\n  LOBYTE(Block[0]) = 0;\n  *(_QWORD *)(v4 + 88) = 0;\n  *(_DWORD *)(v4 + 96) = 0;\n  *(_QWORD *)(v4 + 104) = 0;\n  *(_QWORD *)(v4 + 112) = 100000000;\n  cocos2d::gettimeofday((cocos2d *)(v4 + 120), nullptr, v5);\n}", "assembly": "; \n; cocos2d::CCProfilingResetTimingBlock from 0x180094630 to 0x1800946fe (206 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x1801438a8\n; > <???> @ 0x1801b6708\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\nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x180094630\npush    rdi                                                            ; +0x5, 0x180094635\nsub     rsp, 50h                                                       ; +0x6, 0x180094636\nmov     rax, cs:__security_cookie                                      ; +0xa, 0x18009463a\nxor     rax, rsp                                                       ; +0x11, 0x180094641\nmov     [rsp+58h+var_18], rax                                          ; +0x14, 0x180094644\nmov     rbx, rcx                                                       ; +0x19, 0x180094649\ncall    ?sharedProfiler@CCProfiler@cocos2d@@SAPEAV12@XZ; cocos2d::CCProfiler::sharedProfiler(void) ; +0x1c, 0x18009464c\nmov     rdi, rax                                                       ; +0x21, 0x180094651\nmov     rdx, rbx                                                       ; +0x24, 0x180094654\nlea     rcx, [rsp+58h+Block]                                           ; +0x27, 0x180094657\ncall    sub_180005910                                                  ; +0x2c, 0x18009465c\nnop                                                                    ; +0x31, 0x180094661\nlea     rdx, [rsp+58h+Block]                                           ; +0x32, 0x180094662\nmov     rcx, [rdi+38h]                                                 ; +0x37, 0x180094667\ncall    ?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z; cocos2d::CCDictionary::objectForKey(std::string const &) ; +0x3b, 0x18009466b\nmov     rbx, rax                                                       ; +0x40, 0x180094670\nmov     rdx, [rsp+58h+var_20]                                          ; +0x43, 0x180094673\ncmp     rdx, 0Fh                                                       ; +0x48, 0x180094678\njbe     short loc_1800946B3                                            ; +0x4c, 0x18009467c\ninc     rdx                                                            ; +0x4e, 0x18009467e\nmov     rcx, [rsp+58h+Block]; Block                                    ; +0x51, 0x180094681\nmov     rax, rcx                                                       ; +0x56, 0x180094686\ncmp     rdx, 1000h                                                     ; +0x59, 0x180094689\njb      short loc_1800946AE                                            ; +0x60, 0x180094690\nadd     rdx, 27h ; '''                                                 ; +0x62, 0x180094692\nmov     rcx, [rcx-8]                                                   ; +0x66, 0x180094696\nsub     rax, rcx                                                       ; +0x6a, 0x18009469a\nadd     rax, 0FFFFFFFFFFFFFFF8h                                        ; +0x6d, 0x18009469d\ncmp     rax, 1Fh                                                       ; +0x71, 0x1800946a1\njbe     short loc_1800946AE                                            ; +0x75, 0x1800946a5\ncall    cs:_invalid_parameter_noinfo_noreturn                          ; +0x77, 0x1800946a7\nalign 2                                                                ; +0x7d, 0x1800946ad\ncall    j_j_free_0                                                     ; +0x7e, 0x1800946ae\nmovdqa  xmm0, cs:xmmword_1800E7160                                     ; +0x83, 0x1800946b3\nmovdqu  xmmword ptr [rsp+30h], xmm0                                    ; +0x8b, 0x1800946bb\nmov     byte ptr [rsp+58h+Block], 0                                    ; +0x91, 0x1800946c1\nxor     eax, eax                                                       ; +0x96, 0x1800946c6\nmov     [rbx+58h], rax                                                 ; +0x98, 0x1800946c8\nmov     [rbx+60h], eax                                                 ; +0x9c, 0x1800946cc\nmov     [rbx+68h], rax                                                 ; +0x9f, 0x1800946cf\nmov     qword ptr [rbx+70h], 5F5E100h                                  ; +0xa3, 0x1800946d3\nlea     rcx, [rbx+78h]; this                                           ; +0xab, 0x1800946db\nxor     edx, edx; struct timeval *                                     ; +0xaf, 0x1800946df\ncall    ?gettimeofday@cocos2d@@YAHPEAUtimeval@@PEAUtimezone@1@@Z; cocos2d::gettimeofday(timeval *,cocos2d::timezone *) ; +0xb1, 0x1800946e1\nmov     rcx, [rsp+58h+var_18]                                          ; +0xb6, 0x1800946e6\nxor     rcx, rsp; StackCookie                                          ; +0xbb, 0x1800946eb\ncall    __security_check_cookie                                        ; +0xbe, 0x1800946ee\nmov     rbx, [rsp+58h+arg_8]                                           ; +0xc3, 0x1800946f3\nadd     rsp, 50h                                                       ; +0xc8, 0x1800946f8\npop     rdi                                                            ; +0xcc, 0x1800946fc\nretn                                                                   ; +0xcd, 0x1800946fd", "xrefs": ["<???> @ 0x1801438a8", "<???> @ 0x1801b6708"], "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"}