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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4796d2
mov eax, dword fs:[0]
push eax
sub esp, 0x118
push ebx
push esi
push edi
mov eax, dword [0x4eec64]
xor eax, esp
push eax
lea eax, [esp + 0x128]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [esp + 0x24], ebx
fldz
fcom dword [ebx + 0xbc]
fnstsw ax
test ah, 5
jp 0x41bdca
fcom dword [ebp + 0x20]
fnstsw ax
test ah, 0x44
jp 0x41bdca
fld dword [ebx + 0xbc]
fstp dword [ebp + 0x20]
xor edi, edi
fstp dword [ebx + 0xbc]
push edi
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov esi, eax
push 0xc
push esi
call dword [sym.imp.GDI32.dll_GetDeviceCaps]
push esi
mov dword [0x4f0a40], eax
call dword [sym.imp.GDI32.dll_DeleteDC]
mov eax, dword [ebx + 0x94]
cmp eax, dword [ebx + 0x9c]
jge 0x41cd31
mov ecx, dword [ebx + 0x98]
cmp ecx, dword [ebx + 0xa0]
jge 0x41cd31
lea esi, [ebx + 0x10]
mov dword [esp + 0x40], esi
mov dword [esp + 0xac], esi
mov dword [esp + 0xb0], ebx
cmp dword [ebx + 8], edi
je 0x41be37
push esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
jmp 0x41be40
mov edx, dword [ebx]
mov eax, dword [edx + 8]
mov ecx, ebx
call eax
mov dword [esp + 0x130], edi
mov eax, dword [ebx + 0xa4]
or ecx, 0xffffffff
cmp eax, edi
je 0x41cd13
cmp dword [ebp + 8], ecx
jne 0x41be90
cmp dword [ebp + 0x10], ecx
jne 0x41be90
cmp dword [ebp + 0x14], ecx
jne 0x41be90
cmp dword [ebp + 0xc], ecx
jne 0x41be90
mov ecx, dword [ebx + 0x94]
mov edx, dword [ebx + 0x98]
mov eax, dword [ebx + 0x9c]
mov dword [ebp + 8], ecx
mov ecx, dword [ebx + 0xa0]
mov dword [ebp + 0xc], edx
mov dword [ebp + 0x10], eax
mov dword [ebp + 0x14], ecx
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], edi
lea ecx, [esp + 0xb4]
mov byte [esp + 0x130], 1
call fcn.00411ac0
mov eax, dword [ebx + 0x94]
mov edi, dword [ebp + 8]
cmp eax, edi
mov esi, dword [ebx + 0x98]
mov edx, dword [ebx + 0x9c]
mov ecx, dword [ebx + 0xa0]
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], esi
mov dword [esp + 0x5c], edx
mov dword [esp + 0x60], ecx
jge 0x41bee1
mov eax, edi
mov dword [esp + 0x54], eax
mov edi, dword [ebp + 0xc]
cmp esi, edi
jge 0x41beee
mov esi, edi
mov dword [esp + 0x58], esi
mov edi, dword [ebp + 0x10]
cmp edx, edi
jle 0x41befb
mov edx, edi
mov dword [esp + 0x5c], edx
mov edi, dword [ebp + 0x14]
cmp ecx, edi
jle 0x41bf08
mov ecx, edi
mov dword [esp + 0x60], ecx
mov dword [esp + 0x10c], eax
lea eax, [ebx + 0x38]
mov dword [esp + 0x110], esi
mov dword [esp + 0x108], pe_nt_image_headers32
mov dword [esp + 0x114], edx
mov dword [esp + 0x118], ecx
mov dword [esp + 0x11c], eax
mov esi, 9
mov edi, edi
lea edx, [esp + 0xb4]
push edx
lea eax, [esp + 0x20]
push eax
call fcn.0041df40
sub esi, 1
jne 0x41bf40
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x1c]
shr ecx, 1
imul ecx, ecx, 0x6c
lea eax, [ecx + edx - 0x6c]
xor edx, edx
mov dword [esp + 0x2c], edx
mov dword [esp + 0x30], edx
lea ecx, [esp + 0x2c]
mov dword [eax], ecx
mov dword [esp + 0x14], edx
mov dword [esp + 0x18], edx
mov byte [esp + 0x130], 3
fld1
mov ecx, dword [ebx + 0xa4]
fst dword [esp + 0x74]
fldz
push edx
fst dword [esp + 0x7c]
push edx
fst dword [esp + 0x84]
lea edx, [esp + 0x7c]
fst dword [esp + 0x88]
push edx
fst dword [esp + 0x94]
lea edx, [esp + 0x38]
fst dword [esp + 0x98]
push edx
fstp dword [esp + 0xa0]
mov byte [esp + 0xa8], 1
lea edx, [esp + 0x24]
push edx
fst dword [esp + 0x98]
fstp dword [esp + 0xa8]
mov eax, dword [ecx]
mov eax, dword [eax + 0x2c]
call eax
lea esi, [esp + 0x54]
lea edi, [esp + 0x14]
call fcn.00436fe0
mov ecx, edi
call fcn.00437040
mov ecx, edi
push ecx
call fcn.00436700
add esp, 4
mov ecx, edi
call fcn.00437040
mov ecx, dword [esp + 0x18]
xor esi, esi
shr ecx, 1
jne 0x41c0b5
mov byte [esp + 0x130], 2
mov eax, dword [esp + 0x14]
cmp eax, esi
je 0x41c038
push eax
call fcn.0045c158
add esp, 4
mov edi, 1
and dword [esp + 0x18], edi
mov byte [esp + 0x130], 1
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x14], esi
cmp eax, esi
je 0x41c05e
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x30], edi
mov byte [esp + 0x130], 0
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x2c], esi
cmp eax, esi
je 0x41c07f
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x20], edi
mov dword [esp + 0x1c], esi
mov dword [esp + 0x130], 0xffffffff
cmp dword [ebx + 8], esi
je 0x41c0a7
mov edx, dword [esp + 0x40]
push edx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x41cd31
mov eax, dword [ebx]
mov edx, dword [eax + 0xc]
mov ecx, ebx
call edx
jmp 0x41cd31
mov dword [esp + 0x4c], esi
mov dword [esp + 0x50], esi
xor edi, edi
mov dword [esp + 0x44], edi
mov dword [esp + 0x48], esi
mov byte [esp + 0x130], 5
fldz
fcomp dword [ebp + 0x20]
fnstsw ax
test ah, 0x44
jnp 0x41c4c0
push ecx
lea esi, [esp + 0x50]
call fcn.0041dd70
mov eax, dword [esp + 0x18]
shr eax, 1
push eax
lea esi, [esp + 0x48]
call fcn.0041dd70
test dword [esp + 0x18], 0xfffffffe
mov ecx, dword [esp + 0x4c]
mov eax, dword [esp + 0x44]
mov dword [esp + 0x3c], edi
jbe 0x41c4a1
mov dword [esp + 0x28], eax
lea edx, [ecx + 0x1c]
sub eax, ecx
mov ecx, dword [esp + 0x14]
mov dword [esp + 0x64], edx
mov dword [esp + 0x6c], eax
jmp 0x41c130
mov ebx, dword [edi + ecx + 8]
mov esi, dword [edi + ecx]
mov eax, dword [edi + ecx + 4]
mov ecx, dword [edi + ecx + 0xc]
mov edx, ebx
sub edx, esi
mov dword [esp + 0x54], esi
mov dword [esp + 0x58], eax
test dl, 1
je 0x41c151
inc ebx
sub ebx, dword [esp + 0x54]
mov esi, ecx
sub esi, dword [esp + 0x58]
mov ecx, dword [esp + 0x64]
push 0
push esi
add ecx, 0xffffffe4
push ebx
call fcn.0040f600
mov dword [esp + 0x34], eax
test eax, eax
jne 0x41c239
mov eax, dword [esp + 0x64]
mov ecx, dword [esp + 0x54]
mov edx, dword [esp + 0x58]
push 0
push esi
mov dword [eax - 4], ecx
mov ecx, dword [esp + 0x30]
push ebx
mov dword [eax], edx
call fcn.0040f600
mov ebx, eax
test ebx, ebx
jne 0x41c36f
mov eax, dword [esp + 0x54]
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x58]
mov dword [ecx + 0x18], eax
mov ecx, dword [esp + 0x64]
mov eax, dword [esp + 0x6c]
mov dword [eax + ecx], edx
mov ecx, dword [esp + 0x14]
mov edx, dword [edi + ecx]
cmp edx, dword [edi + ecx + 8]
jge 0x41c20d
mov eax, dword [edi + ecx + 4]
cmp eax, dword [edi + ecx + 0xc]
jge 0x41c20d
mov esi, dword [esp + 0x24]
mov ecx, edx
neg eax
neg ecx
add esi, 0x38
mov dword [esi + 0x18], ecx
or ecx, 0xffffffff
mov dword [esi + 0x1c], eax
sub esp, 0x10
mov eax, esp
mov dword [eax], ecx
or edx, ecx
mov dword [eax + 4], edx
or ebx, ecx
mov dword [eax + 8], ebx
or ecx, ecx
mov dword [eax + 0xc], ecx
mov eax, dword [esp + 0x74]
add eax, 0xffffffe4
push eax
call fcn.0040f9b0
mov ecx, dword [esp + 0x14]
mov eax, dword [esp + 0x3c]
mov edx, 0x24
add dword [esp + 0x28], edx
add dword [esp + 0x64], edx
mov edx, dword [esp + 0x18]
inc eax
shr edx, 1
add edi, 0x10
mov dword [esp + 0x3c], eax
cmp eax, edx
jb 0x41c130
jmp 0x41c4a5
mov byte [esp + 0x130], 4
mov eax, dword [esp + 0x44]
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
xor ebx, ebx
cmp eax, ebx
je 0x41c275
mov ecx, dword [eax - 4]
lea esi, [eax - 4]
push fcn.0040f2a0
push ecx
push 0x24
push eax
call fcn.0045c6d8
push 0x4f85e0
call edi
push esi
call fcn.00402770
add esp, 4
mov byte [esp + 0x130], 3
mov eax, dword [esp + 0x4c]
cmp eax, ebx
je 0x41c2a9
mov edx, dword [eax - 4]
lea esi, [eax - 4]
push fcn.0040f2a0
push edx
push 0x24
push eax
call fcn.0045c6d8
push 0x4f85e0
call edi
push esi
call fcn.00402770
add esp, 4
mov byte [esp + 0x130], 2
mov eax, dword [esp + 0x14]
cmp eax, ebx
je 0x41c2c2
push eax
call fcn.0045c158
add esp, 4
mov esi, 1
and dword [esp + 0x18], esi
mov byte [esp + 0x130], 1
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x14], ebx
cmp eax, ebx
je 0x41c2e8
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x30], esi
mov byte [esp + 0x130], 0
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x2c], ebx
cmp eax, ebx
je 0x41c309
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x20], esi
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x130], 0xffffffff
cmp dword [ecx + 8], ebx
je 0x41c34c
mov eax, dword [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov edx, dword [ecx]
mov eax, dword [edx + 0xc]
call eax
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov byte [esp + 0x130], 4
mov eax, dword [esp + 0x44]
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
je 0x41c3a9
mov ecx, dword [eax - 4]
lea esi, [eax - 4]
push fcn.0040f2a0
push ecx
push 0x24
push eax
call fcn.0045c6d8
push 0x4f85e0
call edi
push esi
call fcn.00402770
add esp, 4
mov byte [esp + 0x130], 3
mov eax, dword [esp + 0x4c]
test eax, eax
je 0x41c3dd
mov edx, dword [eax - 4]
lea esi, [eax - 4]
push fcn.0040f2a0
push edx
push 0x24
push eax
call fcn.0045c6d8
push 0x4f85e0
call edi
push esi
call fcn.00402770
add esp, 4
mov byte [esp + 0x130], 2
mov eax, dword [esp + 0x14]
xor esi, esi
cmp eax, esi
je 0x41c3f8
push eax
call fcn.0045c158
add esp, 4
mov edi, 1
and dword [esp + 0x18], edi
mov byte [esp + 0x130], 1
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x14], esi
cmp eax, esi
je 0x41c41e
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x30], edi
mov byte [esp + 0x130], 0
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x2c], esi
cmp eax, esi
je 0x41c43f
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x20], edi
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x1c], esi
mov dword [esp + 0x130], 0xffffffff
cmp dword [ecx + 8], esi
je 0x41c480
mov eax, dword [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, ebx
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov edx, dword [ecx]
mov eax, dword [edx + 0xc]
call eax
mov eax, ebx
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov ecx, dword [esp + 0x14]
mov eax, dword [esp + 0x24]
mov ebx, dword [esp + 0x24]
mov edi, dword [esp + 0x44]
add eax, 0x38
xor edx, edx
mov dword [eax + 0x18], edx
mov dword [eax + 0x1c], edx
xor esi, esi
jmp 0x41c4c4
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
test edx, 0xfffffffe
jbe 0x41c545
mov dword [esp + 0x28], esi
mov edx, dword [esp + 0x28]
lea eax, [edx + ecx]
mov edx, dword [eax]
cmp edx, dword [eax + 8]
jge 0x41c531
mov edx, dword [eax + 4]
cmp edx, dword [eax + 0xc]
jge 0x41c531
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x1c]
shr ecx, 1
imul ecx, ecx, 0x6c
lea ecx, [ecx + edx - 0x14]
mov edx, dword [eax]
mov dword [ecx], edx
mov edx, dword [eax + 4]
mov dword [ecx + 4], edx
mov edx, dword [eax + 8]
mov dword [ecx + 8], edx
mov eax, dword [eax + 0xc]
lea edx, [esp + 0x1c]
mov dword [ecx + 0xc], eax
mov ecx, dword [ebx + 0xa4]
push edx
call fcn.00413f00
mov dword [esp + 0x34], eax
test eax, eax
jne 0x41c73d
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
add dword [esp + 0x28], 0x10
mov eax, edx
inc esi
shr eax, 1
cmp esi, eax
jb 0x41c4d4
xor esi, esi
fldz
fcomp dword [ebp + 0x20]
fnstsw ax
test ah, 0x44
jnp 0x41c5eb
mov dword [esp + 0x3c], esi
test edx, 0xfffffffe
jbe 0x41c5df
mov edx, dword [esp + 0x44]
xor edi, edi
mov dword [esp + 0x28], edx
jmp 0x41c570
mov eax, dword [edi + ecx]
cmp eax, dword [edi + ecx + 8]
jge 0x41c5c4
mov edx, dword [edi + ecx + 4]
cmp edx, dword [edi + ecx + 0xc]
jge 0x41c5c4
mov ecx, dword [edi + ecx]
mov esi, dword [esp + 0x24]
mov eax, edx
neg ecx
neg eax
add esi, 0x38
mov dword [esi + 0x18], ecx
or ecx, 0xffffffff
sub esp, 0x10
mov dword [esi + 0x1c], eax
mov eax, esp
mov dword [eax], ecx
or edx, ecx
or ebx, ecx
mov dword [eax + 4], edx
mov dword [eax + 8], ebx
or ecx, ecx
mov dword [eax + 0xc], ecx
mov eax, dword [esp + 0x38]
push eax
call fcn.0040f9b0
mov ecx, dword [esp + 0x14]
mov ebx, dword [esp + 0x24]
mov eax, dword [esp + 0x3c]
mov edx, dword [esp + 0x18]
add dword [esp + 0x28], 0x24
inc eax
shr edx, 1
add edi, 0x10
mov dword [esp + 0x3c], eax
cmp eax, edx
jb 0x41c570
mov edi, dword [esp + 0x44]
xor eax, eax
mov dword [ebx + 0x50], eax
mov dword [ebx + 0x54], eax
mov eax, dword [esp + 0x20]
shr eax, 1
je 0x41c602
dec eax
push eax
lea edi, [esp + 0x20]
call fcn.00415b40
mov edi, dword [esp + 0x44]
cmp byte [ebp + 0x1c], 0
je 0x41c896
cmp byte [ebp + 0x18], 0
mov esi, ebx
sete al
movzx ecx, al
push ecx
call fcn.0041ad40
mov dword [esp + 0x34], eax
test eax, eax
je 0x41c896
xor esi, esi
mov byte [esp + 0x130], 4
cmp edi, esi
je 0x41c662
mov edx, dword [edi - 4]
push fcn.0040f2a0
lea esi, [edi - 4]
push edx
push 0x24
push edi
call fcn.0045c6d8
push 0x4f85e0
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
push esi
call fcn.00402770
add esp, 4
xor esi, esi
mov byte [esp + 0x130], 3
mov eax, dword [esp + 0x4c]
cmp eax, esi
je 0x41c69a
mov ecx, dword [eax - 4]
lea edi, [eax - 4]
push fcn.0040f2a0
push ecx
push 0x24
push eax
call fcn.0045c6d8
push 0x4f85e0
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
push edi
call fcn.00402770
add esp, 4
mov byte [esp + 0x130], 2
mov eax, dword [esp + 0x14]
cmp eax, esi
je 0x41c6b3
push eax
call fcn.0045c158
add esp, 4
mov edi, 1
and dword [esp + 0x18], edi
mov byte [esp + 0x130], 1
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x14], esi
cmp eax, esi
je 0x41c6d9
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x30], edi
mov byte [esp + 0x130], 0
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x2c], esi
cmp eax, esi
je 0x41c6fa
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x20], edi
mov dword [esp + 0x1c], esi
mov dword [esp + 0x130], 0xffffffff
cmp dword [ebx + 8], esi
je 0x41c871
mov edx, dword [esp + 0x40]
push edx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
xor esi, esi
mov byte [esp + 0x130], 4
cmp edi, esi
je 0x41c775
mov ecx, dword [edi - 4]
push fcn.0040f2a0
lea esi, [edi - 4]
push ecx
push 0x24
push edi
call fcn.0045c6d8
push 0x4f85e0
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
push esi
call fcn.00402770
add esp, 4
xor esi, esi
mov byte [esp + 0x130], 3
mov eax, dword [esp + 0x4c]
cmp eax, esi
je 0x41c7ad
mov edx, dword [eax - 4]
lea edi, [eax - 4]
push fcn.0040f2a0
push edx
push 0x24
push eax
call fcn.0045c6d8
push 0x4f85e0
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
push edi
call fcn.00402770
add esp, 4
mov byte [esp + 0x130], 2
mov eax, dword [esp + 0x14]
cmp eax, esi
je 0x41c7c6
push eax
call fcn.0045c158
add esp, 4
mov edi, 1
and dword [esp + 0x18], edi
mov byte [esp + 0x130], 1
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x14], esi
cmp eax, esi
je 0x41c7ec
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x30], edi
mov byte [esp + 0x130], 0
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x2c], esi
cmp eax, esi
je 0x41c80d
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x20], edi
mov dword [esp + 0x1c], esi
mov dword [esp + 0x130], 0xffffffff
cmp dword [ebx + 8], esi
je 0x41c84c
mov eax, dword [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov edx, dword [ebx]
mov eax, dword [edx + 0xc]
mov ecx, ebx
call eax
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov eax, dword [ebx]
mov edx, dword [eax + 0xc]
mov ecx, ebx
call edx
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
fldz
fcomp dword [ebp + 0x20]
fnstsw ax
test ah, 0x44
jnp 0x41cae3
lea eax, [esp + 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
fild qword [esp + 0x34]
mov ebx, dword [esp + 0x24]
fstp qword [esp + 0x6c]
lea ecx, [ecx]
mov esi, dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
lea ecx, [esp + 0x64]
push ecx
call esi
fild qword [esp + 0x64]
fstp qword [esp + 0x34]
fldz
fld qword [0x4f85a0]
fucom st(1)
fnstsw ax
fstp st(1)
test ah, 0x44
jp 0x41c90b
lea edx, [esp + 0x9c]
fstp st(0)
push edx
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
fild qword [esp + 0x9c]
fdivr qword [0x48b4b0]
fst qword [0x4f85a0]
fld dword [ebp + 0x20]
fld qword [esp + 0x34]
fsub qword [esp + 0x6c]
fmulp st(2)
fxch st(1)
fstp dword [esp + 0x34]
fld dword [esp + 0x34]
fcompp
fnstsw ax
test ah, 5
jp 0x41ca98
lea eax, [esp + 0xa4]
push eax
call esi
fild qword [esp + 0xa4]
fstp qword [esp + 0x34]
fldz
fld qword [0x4f85a0]
fucom st(1)
fnstsw ax
fstp st(1)
test ah, 0x44
jp 0x41c974
lea ecx, [esp + 0x54]
fstp st(0)
push ecx
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
fild qword [esp + 0x54]
fdivr qword [0x48b4b0]
fst qword [0x4f85a0]
fld qword [esp + 0x34]
fsub qword [esp + 0x6c]
fmulp st(1)
fstp dword [esp + 0x34]
fld dword [esp + 0x34]
fdiv dword [ebp + 0x20]
fstp dword [esp + 0x34]
fld dword [esp + 0x34]
fld st(0)
fxch st(1)
fadd st(0), st(0)
fsubr qword [0x490070]
fld st(1)
fmulp st(2)
fmulp st(1)
fstp dword [esp + 0x34]
fld dword [esp + 0x34]
fmul qword [0x490168]
fstp dword [esp + 0x34]
fld dword [esp + 0x34]
fistp dword [esp + 0x28]
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x14]
mov dword [esp + 0x3c], 0
test ecx, 0xfffffffe
jbe 0x41ca2d
mov esi, dword [esp + 0x4c]
mov ebx, dword [esp + 0x44]
xor edi, edi
sub ebx, esi
mov edx, dword [edi + eax]
cmp edx, dword [edi + eax + 8]
jge 0x41ca15
mov edx, dword [edi + eax + 4]
cmp edx, dword [edi + eax + 0xc]
jge 0x41ca15
mov ecx, dword [esp + 0x28]
lea eax, [esi + ebx]
push eax
mov eax, dword [esp + 0x28]
add eax, 0x38
push eax
push ecx
call fcn.00431cc0
mov ecx, dword [esp + 0x24]
mov eax, dword [esp + 0x20]
add esp, 0xc
inc dword [esp + 0x3c]
mov edx, ecx
shr edx, 1
add edi, 0x10
add esi, 0x24
cmp dword [esp + 0x3c], edx
jb 0x41c9e1
mov ebx, dword [esp + 0x24]
xor edi, edi
test ecx, 0xfffffffe
jbe 0x41c8c0
xor esi, esi
lea ecx, [ecx]
mov edx, dword [esi + eax]
cmp edx, dword [esi + eax + 8]
jge 0x41ca87
mov edx, dword [esi + eax + 4]
cmp edx, dword [esi + eax + 0xc]
jge 0x41ca87
mov edx, dword [ebx]
mov ebx, dword [esi + eax]
mov edx, dword [edx + 0x10]
sub esp, 0x10
mov ecx, esp
mov dword [ecx], ebx
mov ebx, dword [esi + eax + 4]
mov dword [ecx + 4], ebx
mov ebx, dword [esi + eax + 8]
mov eax, dword [esi + eax + 0xc]
mov dword [ecx + 8], ebx
mov ebx, dword [esp + 0x34]
mov dword [ecx + 0xc], eax
mov ecx, ebx
call edx
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x14]
mov edx, ecx
inc edi
shr edx, 1
add esi, 0x10
cmp edi, edx
jb 0x41ca40
jmp 0x41c8c0
xor edi, edi
test dword [esp + 0x18], 0xfffffffe
jbe 0x41cae3
mov esi, dword [esp + 0x44]
or ebx, 0xffffffff
jmp 0x41cab0
sub esp, 0x10
mov eax, esp
mov dword [eax], ebx
or ecx, 0xffffffff
mov dword [eax + 4], ecx
or ecx, ecx
mov dword [eax + 8], ecx
or ecx, 0xffffffff
mov dword [eax + 0xc], ecx
mov eax, dword [esp + 0x34]
add eax, 0x38
push eax
call fcn.0040f9b0
mov eax, dword [esp + 0x18]
inc edi
shr eax, 1
add esi, 0x24
cmp edi, eax
jb 0x41cab0
cmp byte [ebp + 0x18], 0
jne 0x41cc20
mov edi, dword [esp + 0x24]
mov eax, dword [edi + 0x64]
add edi, 0x64
test eax, eax
je 0x41cb04
push eax
call fcn.0045c158
add esp, 4
mov ebx, 1
and dword [edi + 4], ebx
mov eax, dword [edi + 4]
mov dword [edi], 0
test byte [esp + 0x18], bl
je 0x41cba8
test bl, al
jne 0x41cc12
or eax, ebx
mov esi, eax
shr esi, 1
mov dword [edi + 4], eax
je 0x41cc12
test ebx, eax
je 0x41cc12
test bl, al
je 0x41cb48
push esi
jmp 0x41cc00
cmp esi, 1
jb 0x41cb56
lea ecx, [ecx]
add ebx, ebx
cmp ebx, esi
jbe 0x41cb50
mov edx, eax
shr edx, 1
mov eax, edx
mov dword [esp + 0x34], eax
fild dword [esp + 0x34]
test eax, eax
jge 0x41cb6e
fadd dword [0x490020]
fstp dword [esp + 0x34]
mov eax, dword [esp + 0x34]
shr eax, 0x17
and eax, 0xff
lea ecx, [eax - 0x7f]
test ecx, ecx
jl 0x41cb8e
mov eax, 1
shl eax, cl
jmp 0x41cb90
xor eax, eax
cmp eax, edx
jae 0x41cb96
add eax, eax
cmp eax, ebx
je 0x41cba0
push ebx
call fcn.00415bd0
mov edx, dword [edi + 4]
and edx, 1
jmp 0x41cc0a
test al, 1
je 0x41cc12
and eax, 0xfffffffe
mov esi, eax
shr esi, 1
mov dword [edi + 4], eax
je 0x41cc12
mov ecx, eax
and ecx, ebx
cmp cl, 1
je 0x41cc12
test al, 1
je 0x41cbe6
push esi
call fcn.00415bd0
mov eax, dword [edi + 4]
and eax, ebx
lea edx, [esi + esi]
or edx, eax
lea eax, [esp + 0x14]
push eax
mov esi, edi
mov dword [edi + 4], edx
call fcn.0041ded0
jmp 0x41cc2e
mov eax, ebx
cmp esi, ebx
jb 0x41cbf6
lea esp, [esp]
add eax, eax
cmp eax, esi
jbe 0x41cbf0
mov ecx, dword [edi + 4]
shr ecx, 1
cmp ecx, eax
je 0x41cc05
push eax
call fcn.00415bd0
mov edx, dword [edi + 4]
and edx, ebx
lea ecx, [esi + esi]
or ecx, edx
mov dword [edi + 4], ecx
lea eax, [esp + 0x14]
push eax
mov esi, edi
call fcn.0041ded0
jmp 0x41cc2e
mov esi, dword [esp + 0x24]
lea ecx, [esp + 0x14]
push ecx
call fcn.0041bbf0
mov byte [esp + 0x130], 4
mov eax, dword [esp + 0x44]
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
xor ebx, ebx
cmp eax, ebx
je 0x41cc6a
mov edx, dword [eax - 4]
lea esi, [eax - 4]
push fcn.0040f2a0
push edx
push 0x24
push eax
call fcn.0045c6d8
push 0x4f85e0
call edi
push esi
call fcn.00402770
add esp, 4
mov byte [esp + 0x130], 3
mov eax, dword [esp + 0x4c]
cmp eax, ebx
je 0x41cc9e
mov ecx, dword [eax - 4]
lea esi, [eax - 4]
push fcn.0040f2a0
push ecx
push 0x24
push eax
call fcn.0045c6d8
push 0x4f85e0
call edi
push esi
call fcn.00402770
add esp, 4
mov byte [esp + 0x130], 2
mov eax, dword [esp + 0x14]
cmp eax, ebx
je 0x41ccb7
push eax
call fcn.0045c158
add esp, 4
mov esi, 1
and dword [esp + 0x18], esi
mov byte [esp + 0x130], 1
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x14], ebx
cmp eax, ebx
je 0x41ccdd
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x30], esi
mov byte [esp + 0x130], 0
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x2c], ebx
cmp eax, ebx
je 0x41ccfe
push eax
call fcn.00402770
add esp, 4
and dword [esp + 0x20], esi
mov esi, dword [esp + 0x40]
mov dword [esp + 0x1c], ebx
mov ebx, dword [esp + 0x24]
xor edi, edi
or ecx, 0xffffffff
mov dword [esp + 0x130], ecx
cmp dword [ebx + 8], edi
je 0x41cd28
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x41cd31
mov edx, dword [ebx]
mov eax, dword [edx + 0xc]
mov ecx, ebx
call eax
xor eax, eax
mov ecx, dword [esp + 0x128]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c