Function at 0x508bb0
Capabilities:
Check for time delay via queryperformancecounter

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x70
mov edi, ecx
mov eax, dword [0x64a040]
xor eax, ebp
mov dword [esp + 0x68], eax
mov eax, dword [ecx + 0xa0]
mov ecx, dword [ecx + 0xa4]
cmp eax, ecx
je 0x508e26
mov edx, ecx
sub edx, eax
sar edx, 3
imul eax, edx, 0xba2e8ba3
cmp eax, dword [ebp + 0xc]
jne 0x50924e
cmp dword [edi + 0x6c], 0
je 0x508e07
mov eax, dword [edi + 0x58]
mov edx, dword [edi + 0x5c]
mov ecx, eax
or ecx, edx
je 0x508e07
mov ecx, dword [edi + 0x8c]
test ecx, ecx
je 0x509248
mov esi, dword [ecx + 0xa4]
sub esi, dword [ecx + 0xa0]
cmp esi, 0x58
jne 0x508e07
movzx ecx, byte [edi + 0x68]
mov dword [esp + 8], 3
mov byte [esp + 0x18], cl
test cl, cl
jne 0x508c50
mov byte [edi + 0x68], 1
mov dword [esp + 8], 5
lea ecx, [edi + 0x58]
mov dword [esp + 0x10], ecx
mov dword [esp + 0x5c], 0xffffffff
mov dword [esp + 0x58], 0xffffffff
mov ecx, dword [ebp + 8]
cmp byte [ecx + 8], 0
jne 0x508d2b
mov ecx, dword [fcn.0056d830]
cmp ecx, 0x56aca0
jne 0x508d19
mov dword [esp + 0x64], 0
mov dword [esp + 0x60], 0
lea eax, [esp + 0x60]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov ebx, dword [esp + 0x60]
mov esi, dword [esp + 0x64]
cmp ebx, 0x7bd05af7
mov eax, esi
sbb eax, 0x863
jge 0x509396
mov ecx, 0xf4240
mov eax, ebx
mul ecx
imul ecx, esi, 0xf4240
add ecx, edx
push dword [0x64f6a4]
push dword [0x64f6a0]
push ecx
push eax
call fcn.005a13d0
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], edx
mov eax, dword [ebp + 8]
cmp byte [eax + 8], 0
jne 0x5092e4
test eax, eax
je 0x5092d5
mov ebx, dword [esp + 0x60]
mov esi, dword [esp + 0x64]
mov dword [eax], ebx
mov dword [eax + 4], esi
mov byte [eax + 8], 1
mov ecx, dword [esp + 0x10]
mov eax, dword [ecx]
mov edx, dword [ecx + 4]
jmp 0x508d30
call dword [0x6445dc]
lea eax, [esp + 0x60]
push eax
call ecx
add esp, 4
jmp 0x508ce8
mov ebx, dword [ecx]
mov esi, dword [ecx + 4]
mov ecx, ebx
sub ecx, eax
mov eax, esi
sbb eax, edx
mov dword [esp + 0x58], ebx
seto bl
mov dword [esp + 0x5c], esi
mov edx, eax
sar edx, 0x1f
test bl, bl
cmovne ecx, edx
add edx, 0x80000000
test bl, bl
cmove edx, eax
xor esi, esi
mov eax, 0x1c9c37f
cmp eax, ecx
mov eax, 0
sbb eax, edx
mov dword [esp + 0xc], edi
jl 0x508de4
mov dword [esp + 4], ecx
mov ebx, ecx
add ebx, 1
mov eax, edx
adc eax, 0x80000000
mov ecx, 1
cmp ecx, ebx
sbb esi, eax
mov eax, edi
mov edi, dword [esp + 8]
mov esi, dword [eax + edi*8 + 0x10]
mov ecx, dword [eax + edi*8 + 0x14]
jae 0x5092f6
add esi, dword [esp + 4]
adc ecx, edx
seto dl
mov eax, ecx
sar eax, 0x1f
test dl, dl
cmovne esi, eax
add eax, 0x80000000
test dl, dl
cmove eax, ecx
cmp esi, 0x186a0
mov ecx, eax
sbb ecx, 0
mov edx, dword [esp + 0xc]
mov dword [edx + edi*8 + 0x10], esi
mov dword [edx + edi*8 + 0x14], eax
jge 0x509198
cmp dword [edx + 0x8c], 0
mov edi, edx
je 0x50924b
movzx eax, byte [0x64f50d]
test al, al
setne bl
jne 0x50926b
mov byte [edi + 0x88], bl
movsd xmm0, qword [esp + 0x58]
movsd qword [edi + 0x58], xmm0
mov ebx, dword [edi + 0xa4]
cmp dword [edi + 0xa0], ebx
je 0x509239
cmp dword [ebx - 0x30], 0
mov dword [ebx - 0x30], 1
je 0x508e3b
mov ecx, dword [esp + 0x68]
xor ecx, ebp
call fcn.005810d5
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret 8
mov eax, dword [ebx - 0x50]
or eax, dword [ebx - 0x4c]
jne 0x5092cf
mov eax, dword [ebx - 0x48]
or eax, dword [ebx - 0x44]
jne 0x5092d2
lea edi, [ebx - 0x58]
mov edx, dword [edi]
mov esi, dword [edi + 4]
mov eax, edx
or eax, esi
mov dword [esp + 8], ebx
jne 0x5090eb
mov eax, dword [0x65c7a0]
mov ecx, dword [0x64d82c]
mov edx, dword fs:[0x2c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x509162
cmp byte [0x65c79c], 0
je 0x508f47
mov esi, dword [ebx - 0x40]
mov edx, dword [ebx - 0x3c]
mov eax, dword [esp + 8]
mov ebx, dword [eax - 0x34]
mov eax, edx
shld eax, esi, 0x17
mov edi, esi
shl edi, 0x17
xor edi, esi
mov ecx, dword [esp + 8]
mov esi, dword [ecx - 0x38]
xor eax, edx
mov ecx, eax
shld ecx, edi, 0xf
mov dword [esp + 0xc], ecx
mov edx, ebx
shld edx, esi, 6
mov ecx, ebx
shr ecx, 0x1a
xor ecx, ebx
xor ecx, eax
shr eax, 0x11
xor eax, ecx
xor edx, esi
xor edx, edi
xor edx, dword [esp + 0xc]
mov ecx, dword [esp + 8]
mov dword [ecx - 0x40], esi
mov ecx, dword [esp + 8]
mov dword [ecx - 0x3c], ebx
mov ecx, dword [esp + 8]
mov dword [ecx - 0x38], edx
add edx, esi
mov ecx, dword [esp + 8]
mov dword [ecx - 0x34], eax
adc eax, ebx
mov ebx, dword [esp + 8]
mov ecx, eax
shr ecx, 0xb
movd xmm0, ecx
shld eax, edx, 0x15
movd xmm1, eax
punpckldq xmm1, xmm0
movq qword [esp + 0x30], xmm1
fild qword [esp + 0x30]
fstp qword [esp + 0x28]
movsd xmm0, qword [esp + 0x28]
mulsd xmm0, qword [0x62d150]
movsd xmm1, qword [0x62d158]
ucomisd xmm1, xmm0
ja 0x509017
mov dword [esp + 0x50], 0xa
movzx eax, byte [0x64f42e]
test al, al
jne 0x509357
lea ecx, [ebx - 0x20]
mov eax, dword [ebx - 0x10]
inc eax
mov dword [ebx - 0x10], eax
push 0
push eax
call fcn.00401120
jmp 0x508e26
call dword [0x6445dc]
lea eax, [esp + 0x60]
push eax
call ecx
add esp, 4
jmp 0x508feb
mov ecx, dword [fcn.0056d830]
cmp ecx, 0x56aca0
jne 0x508f75
xor eax, eax
lea esi, [esp + 0x60]
mov dword [esi + 4], eax
mov dword [esi], eax
push esi
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov edi, dword [esi]
mov esi, dword [esi + 4]
cmp edi, 0x7bd05af7
mov eax, esi
sbb eax, 0x863
jge 0x509523
mov ecx, 0xf4240
mov eax, edi
mul ecx
imul ecx, esi, 0xf4240
add ecx, edx
push dword [0x64f6a4]
push dword [0x64f6a0]
push ecx
push eax
call fcn.005a13d0
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], edx
mov edx, dword [ebp + 8]
cmp byte [edx + 8], 0
jne 0x50949a
test edx, edx
je 0x5092d5
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x64]
mov dword [edx], eax
mov dword [edx + 4], ecx
mov byte [edx + 8], 1
mov ebx, dword [esp + 8]
jmp 0x509029
mov ecx, dword [ebp + 8]
cmp byte [ecx + 8], 0
je 0x508f87
mov eax, dword [ecx]
mov ecx, dword [ecx + 4]
mov dword [ebx - 0x50], eax
mov dword [ebx - 0x4c], ecx
lea esi, [esp + 0x60]
push esi
call fcn.004055a0
add esp, 4
movsd xmm0, qword [esi]
movsd qword [ebx - 0x48], xmm0
jmp 0x508f47
call dword [0x6445dc]
lea eax, [esp + 0x60]
push eax
call ecx
add esp, 4
jmp 0x5090be
mov ecx, dword [fcn.0056d830]
cmp ecx, 0x56aca0
jne 0x50904a
xor eax, eax
lea esi, [esp + 0x60]
mov dword [esi + 4], eax
mov dword [esi], eax
push esi
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov eax, dword [esi]
mov esi, dword [esi + 4]
cmp eax, 0x7bd05af7
mov ecx, esi
sbb ecx, 0x863
jge 0x5095ad
mov ecx, 0xf4240
mul ecx
imul ecx, esi, 0xf4240
add ecx, edx
push dword [0x64f6a4]
push dword [0x64f6a0]
push ecx
push eax
call fcn.005a13d0
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], edx
mov edx, dword [ebp + 8]
cmp byte [edx + 8], 0
jne 0x5094ac
test edx, edx
je 0x5092d5
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x64]
mov dword [edx], eax
mov dword [edx + 4], ecx
mov byte [edx + 8], 1
mov edx, dword [edi]
mov esi, dword [edi + 4]
jmp 0x5090fd
mov ecx, dword [ebp + 8]
cmp byte [ecx + 8], 0
je 0x50905c
mov eax, dword [ecx]
mov ecx, dword [ecx + 4]
sub eax, edx
sbb ecx, esi
seto bl
mov edx, ecx
sar edx, 0x1f
test bl, bl
cmovne eax, edx
add edx, 0x80000000
test bl, bl
cmove edx, ecx
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], edx
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], edx
sub esp, 0x10
movsd xmm0, qword [esp + 0x68]
movsd qword [esp + 8], xmm0
movsd xmm0, qword [esp + 0x60]
movsd qword [esp], xmm0
mov ecx, edi
mov edx, str.Scheduling.ThreadController.IdleDuration
call fcn.004020f0
add esp, 0x10
xor eax, eax
mov dword [edi + 4], eax
mov dword [edi], eax
mov ebx, dword [esp + 8]
jmp 0x508e69
push 0x65c7a0
call fcn.0057dc73
add esp, 4
cmp dword [0x65c7a0], 0xffffffff
jne 0x508e8a
call fcn.004112e0
mov byte [0x65c79c], al
push 0x65c7a0
call fcn.0057dcc2
add esp, 4
jmp 0x508e8a
movd xmm0, esi
movd xmm1, eax
punpckldq xmm0, xmm1
movq qword [esp + 0x40], xmm0
fild qword [esp + 0x40]
fstp qword [esp + 0x38]
movsd xmm0, qword [esp + 0x38]
divsd xmm0, qword [0x63ca60]
cvttsd2si esi, xmm0
mov ebx, dword [edx + 0x6c]
mov eax, dword [ebx]
mov ecx, dword [eax + 0x18]
mov dword [esp + 4], ecx
call dword [0x6445dc]
mov ecx, ebx
push esi
push edi
call dword [esp + 0xc]
mov eax, esi
neg eax
cmovs eax, esi
mov ecx, 0x3e8
mul ecx
xor ecx, ecx
mov ebx, eax
neg ebx
sbb ecx, edx
test esi, esi
cmovns ecx, edx
cmovns ebx, eax
mov esi, dword [esp + 0xc]
mov eax, dword [esi + edi*8 + 0x10]
sub eax, ebx
mov ebx, edi
mov edx, dword [esi + edi*8 + 0x14]
mov edi, esi
sbb edx, ecx
mov ecx, eax
seto al
mov esi, edx
sar esi, 0x1f
test al, al
cmovne ecx, esi
add esi, 0x80000000
test al, al
cmove esi, edx
mov dword [edi + ebx*8 + 0x10], ecx
mov dword [edi + ebx*8 + 0x14], esi
mov edx, edi
jmp 0x508dd5
push str....._third_partylibc_srcinclude_vector:622:_assertion__empty___failed:_back___called_on_an_empty_vector_n
push 0x62a183
call fcn.005aacb0
int3
int3
lea ebx, [edi + 0xa0]
add ecx, 0xffffffa8
mov edx, dword [ebp + 8]
call fcn.005f2a40
mov ecx, ebx
call fcn.005f2ab0
jmp 0x508e07
mov esi, edi
cmp byte [edi + 0x88], 0
jne 0x50928b
mov dword [esp + 0x4c], 0xe9
mov al, byte [0x64f50d]
test al, al
jne 0x5094be
cmp byte [esp + 0x18], 0
mov ecx, str.ApplicationTask
mov eax, str.NativeTask
cmove eax, ecx
mov dword [esp + 0x50], 0xe9
mov cl, byte [0x64f50d]
test cl, cl
jne 0x509466
mov dword [esp + 0x50], 0xe9
mov al, byte [0x64f50d]
test al, al
jne 0x50942d
mov edi, esi
jmp 0x508df6
int3
int3
push str....._third_partylibc_srcinclude__memoryconstruct_at.h:40:_assertion___location___nullptr_failed:_null_pointer_given_to_construct_at_n
push 0x62a183
call fcn.005aacb0
mov ebx, dword [esp + 0x60]
mov esi, dword [esp + 0x64]
mov dword [eax], ebx
mov dword [eax + 4], esi
jmp 0x508d0e
mov edi, esi
mov eax, 1
add edi, eax
mov ebx, ecx
adc ebx, 0x80000000
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 4]
xor ebx, esi
xor edx, ecx
mov esi, 0x80000000
add eax, 0xffffffff
mov dword [esp + 4], eax
adc esi, 0xffffffff
or edx, ebx
jne 0x509337
mov ebx, dword [esp + 8]
mov edi, dword [esp + 0xc]
mov ecx, dword [esp + 4]
jmp 0x50922a
xor eax, eax
xor ecx, ecx
inc ecx
cmp ecx, edi
sbb eax, dword [esp + 0x14]
mov ebx, dword [esp + 8]
mov edi, dword [esp + 0xc]
mov ecx, dword [esp + 4]
jb 0x50922a
int3
mov esi, dword [ebx - 0xc]
test esi, esi
je 0x509650
movzx edi, al
lea ebx, [esp + 0x60]
mov ecx, dword [ebp + 8]
push ebx
call fcn.0050a290
lea eax, [esp + 0x58]
mov dword [eax], str.ThreadController_active
lea edx, [esp + 0x50]
mov ecx, edi
push esi
push ebx
push eax
call fcn.005f2d00
add esp, 0xc
mov ebx, dword [esp + 8]
jmp 0x508f5e
mov eax, dword [0x64f6a0]
mov dword [esp + 0x1c], eax
mov ecx, dword [0x64f6a4]
mov dword [esp + 0x14], ecx
push ecx
push eax
push esi
push ebx
call fcn.005a13d0
mov dword [esp + 4], eax
mov ecx, edx
mov eax, dword [esp + 4]
mul dword [esp + 0x1c]
mov dword [esp + 0x24], eax
mov eax, esi
mov esi, dword [esp + 4]
imul esi, dword [esp + 0x14]
add edx, esi
imul esi, ecx, 0xf4240
mov dword [esp + 0x20], esi
mov esi, dword [esp + 0x1c]
imul ecx, esi
add ecx, edx
sub ebx, dword [esp + 0x24]
sbb eax, ecx
mov ecx, eax
mov edx, 0xf4240
mov eax, dword [esp + 4]
mul edx
mov dword [esp + 4], eax
add edx, dword [esp + 0x20]
mov dword [esp + 0x20], edx
mov eax, ebx
mov edx, 0xf4240
mul edx
imul ecx, ecx, 0xf4240
add edx, ecx
push dword [esp + 0x14]
push esi
push edx
push eax
call fcn.005a13d0
add eax, dword [esp + 4]
adc edx, dword [esp + 0x20]
jmp 0x508ce0
cmp byte [esi + 0x80], 0
je 0x509641
movzx ecx, al
lea eax, [esi + 0x70]
lea edx, [esp + 0x60]
mov dword [edx], 0
lea edx, [esp + 0x50]
lea edi, [esp + 0x58]
push edi
push eax
lea eax, [esp + 0x68]
push eax
call fcn.005f2ff0
add esp, 0xc
jmp 0x5092c8
cmp byte [esi + 0x80], 0
je 0x509641
movzx ecx, cl
lea edx, [esi + 0x70]
lea edi, [esp + 0x60]
mov dword [edi], eax
lea eax, [esp + 0x50]
push dword [esp + 0x10]
push edx
push 1
push edi
push eax
push ecx
call fcn.005c00a0
add esp, 0x18
jmp 0x5092b3
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x64]
mov dword [edx], eax
mov dword [edx + 4], ecx
jmp 0x509011
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x64]
mov dword [edx], eax
mov dword [edx + 4], ecx
jmp 0x5090e4
mov edx, 0xfff0bdc0
mov ecx, esi
add edx, dword [esi + 0x58]
mov ecx, dword [esi + 0x5c]
adc ecx, 0xffffffff
mov edi, 0x80000000
cmovno edi, ecx
mov ecx, 0
cmovo edx, ecx
mov dword [esp + 0x60], edx
mov dword [esp + 0x64], edi
mov ecx, dword [esp + 0xc]
cmp byte [ecx + 0x80], 0
je 0x509641
movzx eax, al
lea ecx, [esi + 0x70]
lea edx, [esp + 0x50]
mov dword [edx], str.MessagePumpPhases
lea edi, [esp + 0x60]
push edi
push ecx
push 3
push edx
lea ecx, [esp + 0x5c]
push ecx
push eax
call fcn.005c00a0
add esp, 0x18
jmp 0x50928b
mov ebx, dword [0x64f6a0]
mov dword [esp + 0x14], ebx
mov eax, dword [0x64f6a4]
mov dword [esp + 0xc], eax
push eax
push ebx
push esi
push edi
call fcn.005a13d0
mov dword [esp + 4], eax
mov ecx, edx
mov eax, dword [esp + 4]
mul ebx
mov dword [esp + 0x18], eax
mov eax, dword [esp + 4]
mov ebx, eax
imul ebx, dword [esp + 0xc]
add edx, ebx
imul ebx, ecx, 0xf4240
mov dword [esp + 0x10], ebx
mov ebx, dword [esp + 0x14]
imul ecx, ebx
add ecx, edx
sub edi, dword [esp + 0x18]
sbb esi, ecx
mov ecx, 0xf4240
mul ecx
mov dword [esp + 4], eax
add edx, dword [esp + 0x10]
mov dword [esp + 0x10], edx
mov eax, edi
mul ecx
imul ecx, esi, 0xf4240
add edx, ecx
push dword [esp + 0xc]
push ebx
push edx
push eax
call fcn.005a13d0
add eax, dword [esp + 4]
adc edx, dword [esp + 0x10]
jmp 0x508fe3
mov ebx, dword [0x64f6a0]
mov dword [esp + 4], ebx
mov ecx, dword [0x64f6a4]
mov dword [esp + 0xc], ecx
push ecx
push ebx
push esi
push eax
mov dword [esp + 0x28], eax
call fcn.005a13d0
mov dword [esp + 0x10], eax
mov ecx, edx
mov eax, dword [esp + 0x10]
mul ebx
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x10]
mov ebx, eax
imul ebx, dword [esp + 0xc]
add edx, ebx
imul ebx, ecx, 0xf4240
mov dword [esp + 0x14], ebx
imul ecx, dword [esp + 4]
add ecx, edx
mov ebx, dword [esp + 0x18]
sub ebx, dword [esp + 0x1c]
sbb esi, ecx
mov ecx, 0xf4240
mul ecx
mov dword [esp + 0x10], eax
add edx, dword [esp + 0x14]
mov dword [esp + 0x18], edx
mov eax, ebx
mul ecx
imul ecx, esi, 0xf4240
add edx, ecx
push dword [esp + 0xc]
push dword [esp + 8]
push edx
push eax
call fcn.005a13d0
add eax, dword [esp + 0x10]
adc edx, dword [esp + 0x18]
jmp 0x5090b6
push str....._third_partylibc_srcincludeoptional:806:_assertion_this__has_value___failed:_optional_operator_called_on_a_disengaged_value_n
push 0x62a183
call fcn.005aacb0
int3