Function at 0x140008328
Capabilities:
Create thread

Disassembly:
mov rax, rsp
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x2c8]
sub rsp, 0x3a0
mov qword [rsp + 0x40], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rax, qword [0x140162470]
xor rax, rsp
mov qword [rbp + 0x290], rax
movzx r15d, cl
mov byte [rsp + 0x30], r15b
lea eax, [r15 - 0x41]
cdqe
lea rbx, [0x1401747a0]
mov rbx, qword [rbx + rax*8]
xor edi, edi
test rbx, rbx
jne 0x140008390
xor al, al
jmp 0x140008cdc
or rcx, 0xffffffffffffffff
call fcn.140006280
test eax, eax
je 0x140008389
lea rcx, [rsp + 0x38]
call fcn.14001ffb4
nop
mov dl, r15b
lea rcx, [rsp + 0x38]
call fcn.140007fa4
lea rdx, [rsp + 0x38]
mov rcx, rbx
call fcn.14002fb4c
test al, al
je 0x140008cc6
mov al, byte [rbx + 0x48]
test al, al
je 0x140008cc6
mov esi, 1
cmp al, sil
je 0x14000840b
cmp al, 2
je 0x1400083fe
sub al, 3
cmp al, sil
ja 0x140008cc6
mov rax, qword [0x140174648]
test dword [rax + 0x28], 0x8000
jmp 0x140008419
mov rax, qword [0x140174648]
test byte [rax + 0x28], sil
jmp 0x140008419
mov rax, qword [0x140174648]
test dword [rax + 0x28], 0x1000
je 0x140008cc6
call fcn.14001e674
test eax, eax
jne 0x140008cba
call fcn.14001e6f4
test eax, eax
jne 0x140008cba
mov r12, rdi
mov rax, qword [0x140174648]
mov r14d, 8
test dword [rax + 0x24], 0x200
je 0x1400084ca
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov rcx, rax
lea r8d, [r14 + 0x10]
mov edx, r14d
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r12, rax
mov byte [rax + 0x14], r15b
xor r9d, r9d
xor r8d, r8d
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov qword [r12], rax
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], edi
mov r9, r12
lea r8, [0x14000955c]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
test rax, rax
je 0x1400084c0
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
or edx, 0xffffffff
mov rcx, qword [r12]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [r12]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, qword [0x140174650]
mov byte [rax + 0x2a], sil
mov dword [rbx + 0x1b8], edi
mov rax, qword [0x140174648]
mov ecx, dword [rax + 0x24]
bt ecx, 0x13
jb 0x140008500
shr ecx, 0xb
and ecx, 0xf
lea eax, [rcx - 1]
cmp eax, 7
cmova ecx, esi
mov dword [rbx + 0x1b8], ecx
mov rcx, rbx
call fcn.14002f184
test al, al
je 0x140008c95
cmp dword [rbx + 0x8c], edi
je 0x140008c95
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax + InitCommonControls]
xor edx, edx
mov rcx, rbx
call fcn.140026f50
mov r13d, edi
mov dword [rsp + 0x34], edi
cmp dword [rbx + 0x8c], esi
jne 0x14000862f
lea rdx, [rsp + 0x50]
mov rcx, rbx
call fcn.140030738
test al, al
je 0x140008624
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov rcx, rax
mov r8d, 0xc88
mov edx, r14d
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r14, rax
test rax, rax
je 0x140008b6a
mov edx, 0x2e584fdf
mov r8d, 0x16
lea rcx, [0x140166c90]
call fcn.140001198
mov r8, rax
mov edx, esi
lea rcx, [rsp + 0x38]
call fcn.14002005c
mov edx, 0xe641cd6a
mov r8d, 0x2e
lea rcx, [0x140166ca8]
call fcn.140001198
mov r8, rax
mov edx, esi
lea rcx, [rsp + 0x38]
call fcn.14002005c
and dword [r14 + 0x10], 0xfffffff1
or dword [r14 + 0x10], esi
movzx ecx, byte [rsp + 0x50]
mov eax, 0x100
imul cx, ax
movzx eax, byte [rsp + 0x51]
add cx, ax
movzx eax, cx
add eax, 2
movsxd r8, eax
lea rcx, [r14 + 0x28]
lea rdx, [rsp + 0x50]
call fcn.1400e7dd0
mov rdx, r14
mov rcx, rbx
call fcn.140026fe4
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov rcx, rax
mov r8, r14
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov r13d, esi
jmp 0x140008b6a
mov dword [rbx + 0x90], esi
jmp 0x140008b6a
mov rdx, qword [rbx + 0x1b0]
test rdx, rdx
je 0x14000864e
mov rax, qword [0x140174648]
mov ecx, dword [rax + 0x28]
and ecx, 0xfff
mov dword [rdx + 0x20], ecx
mov dword [rbx + 0x1f8], edi
mov rax, qword [0x140174648]
movzx edx, word [rax + 0x2a]
and edx, esi
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
movzx ecx, word [rax + 0x2a]
xor ecx, edx
and ecx, 2
xor edx, ecx
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
movzx ecx, word [rax + 0x2a]
xor ecx, edx
and ecx, 4
xor edx, ecx
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
movzx ecx, word [rax + 0x2a]
xor ecx, edx
and ecx, r14d
xor edx, ecx
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
movzx ecx, word [rax + 0x2a]
xor ecx, edx
and ecx, 0x10
xor edx, ecx
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
movzx ecx, word [rax + 0x2a]
xor ecx, edx
and ecx, 0x20
xor edx, ecx
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
movzx ecx, word [rax + 0x2a]
xor ecx, edx
and ecx, 0x40
xor edx, ecx
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
movzx ecx, word [rax + 0x2a]
xor ecx, edx
and ecx, 0x80
xor edx, ecx
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
movzx r8d, word [rax + 0x2a]
xor r8d, edx
and r8d, 0x100
xor r8d, edx
mov dword [rbx + 0x1f8], r8d
mov rax, qword [0x140174648]
mov ecx, dword [rax + 0x24]
mov r9d, 0x8000
test r9d, ecx
je 0x14000874b
mov ecx, edi
jmp 0x140008751
shr ecx, 0x10
and ecx, 3
shl ecx, 9
xor ecx, r8d
mov edx, 0x600
and ecx, edx
xor ecx, r8d
mov dword [rbx + 0x1f8], ecx
mov rax, qword [0x140174648]
test dword [rax + 0x24], r9d
jne 0x140008786
test edx, ecx
jne 0x140008786
btr ecx, 0xa
bts ecx, 9
mov dword [rbx + 0x1f8], ecx
lea rdx, [rbp + 0x280]
call fcn.14000a7b0
mov rcx, rdi
mov al, byte [rbp + rcx*2 + 0x280]
mov byte [rcx + rbx + 0x1fc], al
add rcx, rsi
cmp rcx, 4
jl 0x140008795
lea rdx, [rbp + 0x280]
call fcn.14000a930
mov rcx, rdi
mov al, byte [rbp + rcx*2 + 0x280]
mov byte [rcx + rbx + 0x200], al
add rcx, rsi
cmp rcx, 5
jl 0x1400087bb
cmp dword [rbx + 0x8c], 2
jne 0x14000883a
mov rax, qword [0x140174648]
mov edx, dword [rax + 0x28]
shr edx, 0x11
xor edx, dword [rbx + 0x1f8]
and edx, 0x800
xor edx, dword [rbx + 0x1f8]
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
mov ecx, dword [rax + 0x28]
shr ecx, 0x11
xor ecx, edx
and ecx, 0x1000
xor edx, ecx
mov dword [rbx + 0x1f8], edx
mov rax, qword [0x140174648]
mov ecx, dword [rax + 0x28]
shr ecx, 0x11
xor ecx, edx
and ecx, 0x2000
xor ecx, edx
mov dword [rbx + 0x1f8], ecx
mov rcx, rbx
call fcn.140030380
test al, al
je 0x140008b6a
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov rcx, rax
mov r8d, 0xc88
mov edx, r14d
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r14, rax
test rax, rax
je 0x140008b6a
or r13, 0xffffffffffffffff
lea r15, [rax + 0x28]
mov rcx, rbx
call fcn.14002f0a4
mov byte [r15], al
mov rax, qword [0x140174648]
cmp qword [rax + 0x38], rdi
je 0x1400088c7
mov edx, dword [rax + 0x24]
shr edx, 0xa
xor edx, dword [r14 + 0x10]
mov eax, 0x100
and edx, eax
xor edx, dword [r14 + 0x10]
mov dword [r14 + 0x10], edx
mov rax, qword [0x140174648]
movzx ecx, word [rax + 0x26]
xor ecx, edx
and ecx, 0xf0
xor ecx, edx
mov dword [r14 + 0x10], ecx
mov rax, qword [0x140174648]
mov r8d, dword [rax + 0x24]
shr r8d, 0xd
xor r8d, dword [r14 + 0x10]
and r8d, 0x2000
xor r8d, dword [r14 + 0x10]
mov dword [r14 + 0x10], r8d
mov rax, qword [0x140174648]
mov ecx, dword [rax + 0x28]
shl ecx, 6
xor ecx, r8d
and ecx, 0x200
xor r8d, ecx
mov dword [r14 + 0x10], r8d
mov rax, qword [0x140174648]
mov ecx, dword [rax + 0x28]
shl ecx, 6
xor ecx, r8d
and ecx, 0x400
xor r8d, ecx
mov dword [r14 + 0x10], r8d
mov rax, qword [rbx + 0x290]
mov qword [r14 + 0x18], rax
mov rcx, qword [rbx + 0x298]
sub rcx, qword [rbx + 0x290]
movabs rax, 0x2aaaaaaaaaaaaaab
imul rcx
sar rdx, 2
mov rax, rdx
shr rax, 0x3f
add rdx, rax
mov dword [r14 + 0x14], edx
mov eax, dword [rbx + 0x8c]
cmp eax, 2
je 0x140008a67
cmp eax, 0xa
je 0x140008a56
cmp eax, 0xb
je 0x14000898c
jle 0x140008b35
cmp eax, 0xd
jle 0x140008a56
add eax, 0xffffffec
cmp eax, 3
ja 0x140008b35
and r8d, 0xfffffff4
or r8d, 4
mov dword [r14 + 0x10], r8d
mov rax, qword [0x140174648]
cmp qword [rax + 0x38], rdi
je 0x1400089b2
mov ecx, dword [rbx + 0x1f8]
shr ecx, 6
and ecx, esi
jmp 0x1400089b4
mov ecx, edi
shl ecx, 0xc
xor ecx, r8d
and ecx, 0x1000
xor ecx, r8d
mov dword [r14 + 0x10], ecx
cmp byte [rbx + 0x9e], dil
jne 0x1400089fd
movzx eax, byte [rbx + 0x9d]
shl eax, 0xb
xor eax, ecx
mov edx, 0x800
and eax, edx
xor ecx, eax
mov dword [r14 + 0x10], ecx
test edx, ecx
je 0x1400089fd
movups xmm0, xmmword [rbx + 0x210]
movdqu xmmword [r14 + 0xc78], xmm0
movzx eax, word [rbx + 0x222]
mov word [r14 + 0xc6a], ax
movzx eax, word [rbx + 0x220]
mov word [r14 + 0xc68], ax
movzx r8d, word [rbx + 0x220]
shl r8, 4
mov rdx, qword [rbx + 0x208]
mov rcx, r15
call fcn.1400e7dd0
mov eax, dword [rbx + 0x270]
mov dword [r14 + 0xc6c], eax
mov rax, qword [rbx + 0x268]
mov qword [r14 + 0xc70], rax
jmp 0x140008af9
and r8d, 0xfffffff2
or r8d, 2
mov dword [r14 + 0x10], r8d
jmp 0x140008b26
and r8d, 0xfffffff3
or r8d, 3
mov dword [r14 + 0x10], r8d
mov rax, qword [rbx + 0x208]
mov ecx, 8
lea edx, [rcx + 0x78]
movups xmm0, xmmword [rax]
movups xmmword [r15], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [r15 + 0x10], xmm1
movups xmm0, xmmword [rax + 0x20]
movups xmmword [r15 + 0x20], xmm0
movups xmm1, xmmword [rax + 0x30]
movups xmmword [r15 + 0x30], xmm1
movups xmm0, xmmword [rax + 0x40]
movups xmmword [r15 + 0x40], xmm0
movups xmm1, xmmword [rax + 0x50]
movups xmmword [r15 + 0x50], xmm1
movups xmm0, xmmword [rax + 0x60]
movups xmmword [r15 + 0x60], xmm0
add r15, rdx
movups xmm1, xmmword [rax + 0x70]
movups xmmword [r15 - 0x10], xmm1
add rax, rdx
dec rcx
jne 0x140008a82
mov rax, qword [rbx + 0x1c8]
sub rax, qword [rbx + 0x1c0]
and eax, 0xfffffffc
mov dword [r14 + 0x428], eax
mov rax, qword [rbx + 0x1c0]
mov qword [r14 + 0x42c], rax
mov rcx, qword [rbx + 0x228]
cmp rcx, 0xffffffffffffffff
je 0x140008b26
call qword [sym.imp.KERNEL32.dll_CloseHandle]
or qword [rbx + 0x228], 0xffffffffffffffff
mov edx, esi
mov cl, byte [rsp + 0x30]
call fcn.140027d0c
mov qword [r14 + 0x20], rax
mov r13, rax
mov rdx, r14
mov rcx, rbx
call fcn.140026fe4
mov dword [rsp + 0x34], esi
mov rcx, rbx
call fcn.14002ec7c
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov rcx, rax
mov r8, r14
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
cmp r13, 0xffffffffffffffff
je 0x140008b60
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r13d, dword [rsp + 0x34]
mov r15b, byte [rsp + 0x30]
test r12, r12
je 0x140008b8d
mov rcx, qword [r12 + 8]
call fcn.140009580
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov rcx, rax
mov r8, r12
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov r14b, dil
mov rcx, rbx
cmp r13d, esi
jne 0x140008bb1
mov dword [rbx + 0x88], 2
mov edx, 2
call fcn.140027074
jmp 0x140008c32
xor edx, edx
cmp dword [rbx + 0x90], esi
jne 0x140008c0f
mov dword [rbx + 0x88], edi
call fcn.140027074
mov r8d, esi
mov edx, 0x8d25cc69
lea rcx, [0x140166cd8]
call fcn.140001198
mov r8, rax
mov edx, esi
mov rcx, qword [rbx + 0x78]
call fcn.14002005c
mov edx, 0x2592d58b
mov r8d, 0x14
lea rcx, [0x140166cdc]
call fcn.140001198
mov r8, rax
mov edx, esi
mov rcx, qword [rbx + 0x78]
call fcn.14002005c
jmp 0x140008c32
mov r14b, sil
mov dword [rbx + 0x88], 3
call fcn.140027074
cmp dword [rbx + 0x90], 2
je 0x140008c32
mov rcx, rbx
call fcn.1400080b0
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax + 0x20]
mov byte [rbx + 0x81], sil
lea rcx, [rsp + 0x38]
call fcn.14001ffbc
mov rcx, qword [0x140174650]
mov r10, qword [rcx + 0x18]
test r10, r10
je 0x140008c7f
movsx eax, r15b
movzx r8d, ax
mov edx, 0x8068
mov r9d, 3
mov rcx, r10
call qword [sym.imp.USER32.dll_PostMessageW]
mov rcx, qword [0x140174650]
neg r14b
sbb edx, edx
neg edx
add edx, 2
call fcn.14000a350
call fcn.14000a294
jmp 0x140008ccf
test r12, r12
je 0x140008ccc
mov rcx, qword [r12 + 8]
call fcn.140009580
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov rcx, rax
mov r8, r12
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x140008ccc
mov dword [rbx + 0x88], 2
jmp 0x140008cc9
mov sil, dil
mov dil, sil
mov sil, dil
lea rcx, [rsp + 0x38]
call fcn.14001ffbc
mov al, sil
mov rcx, qword [rbp + 0x290]
xor rcx, rsp
call fcn.1400e7da0
lea r11, [rsp + 0x3a0]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret