Function at 0x180007c80
Capabilities:
Resume thread

Disassembly:
push rbx
push rdi
sub rsp, 0x38
xor edi, edi
mov qword [rsp + 0x58], rsi
mov ebx, edi
xor eax, eax
mov esi, 1
lock cmpxchg dword [0x180388020], esi
je 0x180007cc2
cmp rbx, 0x20
jae 0x180007cab
xor ecx, ecx
jmp 0x180007cad
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rbx
xor eax, eax
lock cmpxchg dword [0x180388020], esi
jne 0x180007ca1
cmp qword [0x180388028], rdi
je 0x180007cd2
xor ecx, ecx
call fcn.1800618fc
mov eax, edi
mov rbx, rdi
xchg dword [0x180388020], eax
xor eax, eax
lock cmpxchg dword [0x180388020], esi
je 0x180007d11
nop dword [rax]
cmp rbx, 0x20
jae 0x180007cfa
xor ecx, ecx
jmp 0x180007cfc
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rbx
xor eax, eax
lock cmpxchg dword [0x180388020], esi
jne 0x180007cf0
cmp qword [0x180388028], rdi
je 0x180007ec7
mov ecx, dword [0x1803883bc]
mov ebx, edi
test ecx, ecx
je 0x180007ec7
mov rdx, qword [0x1803883b0]
mov rax, rdx
cmp qword [rax], rdi
je 0x180007d4c
inc ebx
add rax, 0x38
cmp ebx, ecx
jb 0x180007d38
jmp 0x180007ec7
cmp ebx, 0xffffffff
je 0x180007ec7
mov qword [rsp + 0x60], r12
mov eax, ebx
imul r12, rax, 0x38
mov qword [rsp + 0x30], r14
mov r14d, ebx
test byte [r12 + rdx + 0x20], 2
je 0x180007e23
xor r8d, r8d
lea rcx, [rsp + 0x20]
mov edx, ebx
call fcn.180061400
test eax, eax
jne 0x180007ebd
xor edx, edx
mov qword [rsp + 0x68], r13
mov ecx, ebx
call fcn.1800617ec
mov r13d, eax
cmp qword [rsp + 0x20], rdi
je 0x180007e0e
mov ecx, dword [rsp + 0x2c]
test ecx, ecx
je 0x180007dfa
mov rsi, qword [rsp + 0x20]
mov qword [rsp + 0x50], rbp
mov ebp, ecx
mov r8d, dword [rsi]
test r8d, r8d
je 0x180007de6
xor edx, edx
mov ecx, 0x5a
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rbx, rax
test rax, rax
je 0x180007de6
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
add rsi, 4
sub rbp, 1
jne 0x180007db7
mov rbp, qword [rsp + 0x50]
mov esi, 1
mov r8, qword [rsp + 0x20]
xor edx, edx
mov rcx, qword [0x180388028]
call qword [sym.imp.KERNEL32.dll_HeapFree]
test r13d, r13d
mov r13, qword [rsp + 0x68]
jne 0x180007ebd
mov rdx, qword [0x1803883b0]
mov rcx, qword [r12 + rdx + 0x10]
call fcn.180062178
mov edx, dword [0x1803883bc]
dec edx
cmp r14d, edx
jae 0x180007e73
mov eax, edx
imul rcx, rax, 0x38
mov rax, qword [0x1803883b0]
movups xmm0, xmmword [rcx + rax]
movups xmmword [r12 + rax], xmm0
movups xmm1, xmmword [rcx + rax + 0x10]
movups xmmword [r12 + rax + 0x10], xmm1
movups xmm0, xmmword [rcx + rax + 0x20]
movups xmmword [r12 + rax + 0x20], xmm0
movsd xmm1, qword [rcx + rax + 0x30]
movsd qword [r12 + rax + 0x30], xmm1
mov ecx, dword [0x1803883b8]
mov eax, ecx
mov dword [0x1803883bc], edx
shr eax, 1
cmp eax, 0x20
jb 0x180007ebd
cmp eax, edx
jb 0x180007ebd
mov r8, qword [0x1803883b0]
mov eax, ecx
mov rcx, qword [0x180388028]
xor edx, edx
shr rax, 1
imul r9, rax, 0x38
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
test rax, rax
je 0x180007ebd
shr dword [0x1803883b8], 1
mov qword [0x1803883b0], rax
mov r12, qword [rsp + 0x60]
mov r14, qword [rsp + 0x30]
mov eax, edi
mov rbx, rdi
xchg dword [0x180388020], eax
xor eax, eax
lock cmpxchg dword [0x180388020], esi
je 0x180007f01
nop
cmp rbx, 0x20
jae 0x180007eea
xor ecx, ecx
jmp 0x180007eec
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rbx
xor eax, eax
lock cmpxchg dword [0x180388020], esi
jne 0x180007ee0
cmp qword [0x180388028], rdi
mov rsi, qword [rsp + 0x58]
je 0x180007f81
xor ecx, ecx
call fcn.1800618fc
test eax, eax
jne 0x180007f81
mov rcx, qword [0x1803883a8]
mov qword [0x1803883a8], rdi
test rcx, rcx
je 0x180007f49
nop dword [rax]
mov rbx, qword [rcx]
xor edx, edx
mov r8d, 0x8000
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rcx, rbx
test rbx, rbx
jne 0x180007f30
mov r8, qword [0x1803883b0]
xor edx, edx
mov rcx, qword [0x180388028]
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, qword [0x180388028]
call qword [sym.imp.KERNEL32.dll_HeapDestroy]
mov qword [0x180388028], rdi
mov qword [0x1803883b0], rdi
mov qword [0x1803883b8], rdi
xchg dword [0x180388020], edi
add rsp, 0x38
pop rdi
pop rbx
ret