Function at 0x100397864
Capabilities:
Allocate or change rwx memory
Encode data using xor

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xc0
mov rax, qword [0x100404bb0]
xor rax, rsp
mov qword [rsp + 0xb8], rax
lea r12, [rcx + 0x18]
lea rax, [0x100000000]
mov qword [rsp + 0x78], rdx
lea r11, [0x100000000]
mov qword [rsp + 0x90], rcx
mov r14, qword [r12]
mov ebp, dword [r14 + 1]
mov ecx, 0xfffffff
mov edx, dword [r14 + 5]
mov qword [rsp + 0x98], r12
and rdx, rcx
and rbp, rcx
add rbp, rax
mov eax, dword [0x100015964]
mov rcx, rax
lea rsi, [rax + rdx - 1]
mov rax, rsi
xor edx, edx
mov qword [rsp + 0x88], rbp
div rcx
sub rsi, rdx
mov eax, dword [0x100015964]
xor r15d, r15d
mov r10d, dword [0x10028bf00]
mov eax, dword [0x100015964]
mov eax, dword [0x10028bf00]
cmp eax, r15d
je 0x1003979aa
mov rax, r15
mov edi, dword [0x10028bf00]
mov r8, r15
dec edi
inc rdi
cmp rdi, r15
mov r9, rdi
je 0x100397963
mov rcx, qword [0x1003fe198]
imul rcx, rcx, 0x343fd
shl rax, 0x10
shr r9, 0x10
add rcx, 0x269ec3
mov rdx, rcx
shr rdx, 0x10
movzx edx, dx
or rax, rdx
cmp r9, r15
jne 0x100397934
mov qword [0x1003fe198], rcx
xor edx, edx
div rdi
cmp r10, r15
jbe 0x10039799e
inc r8
mov eax, 0xef0b
mov ecx, 0xffff10f4
lock cmpxchg dword [r11 + rdx*4 + 0x4059e0], ecx
je 0x100397c2f
lea rax, [rdx + 1]
mov ecx, dword [0x10028bf00]
xor edx, edx
div rcx
cmp r8, r10
jb 0x10039796d
mov rbx, r15
cmp rbx, r15
jne 0x100397add
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rdi, r15
mov r13d, eax
inc rdi
mov rcx, qword [0x100405548]
cmp rcx, r15
mov rax, r15
mov r8, rcx
mov r9, rcx
je 0x100397a04
mov rcx, qword [0x1003fe198]
imul rcx, rcx, 0x343fd
shl rax, 0x10
shr r9, 0x10
add rcx, 0x269ec3
mov rdx, rcx
shr rdx, 0x10
movzx edx, dx
or rax, rdx
cmp r9, r15
jne 0x1003979d5
mov qword [0x1003fe198], rcx
xor edx, edx
mov r9d, 0x40
div r8
mov rcx, rdx
mov rdx, rsi
shl rcx, 0x10
mov r8d, 0x3000
add rcx, qword [0x10041cd78]
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
cmp rax, r15
mov rbx, rax
je 0x100397a71
mov qword [rsp + 0x28], r15
mov r8d, esi
mov rcx, rax
lea r9, [0x100363da0]
mov qword [rsp + 0x20], r15
mov rdx, rax
or rcx, 3
call qword [sym.imp.ntdll.dll_RtlInstallFunctionTableCallback]
movzx edx, al
cmp edx, r15d
jne 0x100397a86
xor edx, edx
mov rcx, rbx
mov r8d, 0x8000
call qword [sym.imp.KERNEL32.dll_VirtualFree]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_Sleep]
cmp rdi, 0x11
jb 0x1003979b6
mov rbx, r15
cmp rbx, 0x10000
jb 0x100397a94
test bl, 3
je 0x100397aba
cmp rbx, r15
je 0x100397ab7
mov rcx, rbx
or rcx, 3
call qword [sym.imp.ntdll.dll_RtlDeleteFunctionTable]
mov r8d, 0x8000
xor edx, edx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rbx, r15
mov ecx, r13d
call qword [sym.imp.KERNEL32.dll_SetLastError]
cmp rbx, r15
lea r11, [0x100000000]
je 0x1003978f8
mov rcx, rsi
xor eax, eax
mov rdi, rbx
rep stosb byte [rdi], al
mov eax, 0x3ab488c7
mov rax, r15
add qword [r12], 9
mov esi, ebp
mov r14d, dword [r14 + 5]
mov r8d, dword [0x100015964]
and r14d, 0xfffffff
sub r8, r14
lea r13, [0x100000000]
inc r8
mov qword [rsp + 0xa0], r14
sub esi, r13d
mov rdi, r8
mov dword [rsp + 0x30], esi
cmp r8, r15
je 0x100397b58
mov rcx, qword [0x1003fe198]
imul rcx, rcx, 0x343fd
shl rax, 0x10
shr rdi, 0x10
add rcx, 0x269ec3
mov rdx, rcx
shr rdx, 0x10
movzx edx, dx
or rax, rdx
cmp rdi, r15
jne 0x100397b29
mov qword [0x1003fe198], rcx
xor edx, edx
mov ecx, esi
div r8
add rbx, rdx
mov rdx, r14
mov r8, rbx
mov qword [rsp + 0x80], rbx
mov eax, 0xb19ff811
lea rcx, [rsp + 0x70]
mov dil, r15b
mov rdx, qword [r14 + rbp]
mov qword [rsp + 0x70], rdx
mov eax, 0xfa05234c
mov rcx, r13
mov r9d, dword [rsp + 0x74]
mov eax, 0xfffffff
mov r10, qword [rsp + 0x70]
and r10, rax
and r9, rax
add r10, r13
mov rax, qword [0x10014dad0]
sub rcx, rax
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x68], rcx
mov r15d, 4
jne 0x100397c46
xor r8d, r8d
test r9, r9
je 0x100397f4d
mov ecx, dword [rsp + 0x44]
mov edx, dword [rsp + 0x40]
movzx eax, byte [r8 + r10]
inc r8
sub eax, 0x1279a1d2
add edx, eax
add eax, ecx
mov ecx, eax
imul ecx, ecx, 0x2a75
rol ecx, 0xe
ror eax, 0xe
xor ecx, eax
mov eax, ecx
imul eax, eax, 0x2a75
rol eax, 0xe
ror ecx, 0xe
xor eax, ecx
mov ecx, eax
imul ecx, ecx, 0x2a75
rol ecx, 0xe
ror eax, 0xe
xor ecx, eax
add edx, ecx
cmp r8, r9
jb 0x100397bda
mov dword [rsp + 0x44], ecx
mov dword [rsp + 0x40], edx
jmp 0x100397f4d
mov ecx, dword [0x100015964]
imul rcx, rdx
lea rbx, [rcx + r11 + 0x3df000]
jmp 0x1003979a1
lea rax, [r10 + r9]
mov rbx, 0xfffffffffffff000
movsxd rcx, dword [0x10000003c]
mov r8d, dword [rcx + r13 + 0xb0]
mov qword [rsp + 0xa8], rax
mov eax, r10d
sub eax, r13d
mov r11d, eax
add r8, r13
and r11, rbx
mov r13d, dword [rcx + r13 + 0xb4]
mov ecx, eax
sub rax, r11
mov qword [rsp + 0x50], rax
lea rax, [rcx + r9]
mov rcx, rax
and rcx, rbx
mov qword [rsp + 0x48], rcx
sub rax, rcx
add r13, r8
mov qword [rsp + 0x38], r13
mov qword [rsp + 0x58], rax
jmp 0x100397cb9
mov eax, dword [r8]
cmp rax, r11
jae 0x100397cbe
mov eax, dword [r8 + 4]
add r8, rax
cmp r8, r13
jne 0x100397caa
xor ebx, ebx
cmp r8, r13
je 0x100397d01
mov eax, dword [r8]
cmp rax, r11
jne 0x100397d01
mov ecx, dword [r8 + 4]
sub rcx, 8
shr rcx, 1
je 0x100397cfc
mov r9, qword [rsp + 0x50]
lea rdx, [r8 + 8]
movzx eax, word [rdx]
and eax, 0xfff
cmp rax, r9
jae 0x100397cfc
inc rbx
add rdx, 2
cmp rbx, rcx
jne 0x100397ce3
mov rcx, qword [rsp + 0x48]
mov r14, qword [rsp + 0x68]
mov edx, dword [rsp + 0x44]
mov r9d, dword [rsp + 0x40]
lea rbp, [0x100000000]
cmp r8, r13
je 0x100397ec6
mov eax, dword [r8]
cmp rax, rcx
ja 0x100397ec6
mov r11d, dword [r8 + 4]
lea rax, [r11 - 8]
shr rax, 1
cmp rbx, rax
jne 0x100397d57
add r8, r11
cmp r8, r13
je 0x100397ec6
mov eax, dword [r8]
cmp rax, rcx
ja 0x100397ec6
xor ebx, ebx
jmp 0x100397d2b
mov eax, dword [r8]
cmp rax, rcx
jne 0x100397d75
movzx eax, word [r8 + rbx*2 + 8]
and eax, 0xfff
cmp rax, qword [rsp + 0x58]
jae 0x100397ec6
mov rax, rbx
inc rbx
mov r11d, 0xf000
test word [r8 + rax*2 + 8], r11w
je 0x100397d16
xor esi, esi
movzx r11d, word [r8 + rax*2 + 8]
mov r13d, r11d
and r13d, 0xfff
add r13d, dword [r8]
add r13, rbp
mov rax, r13
sub rax, r10
je 0x100397dff
mov r12, rax
movzx eax, byte [rsi + r10]
inc rsi
sub eax, 0x1279a1d2
add r9d, eax
add eax, edx
mov ecx, eax
imul ecx, ecx, 0x2a75
rol ecx, 0xe
ror eax, 0xe
xor ecx, eax
mov eax, ecx
imul eax, eax, 0x2a75
rol eax, 0xe
ror ecx, 0xe
xor eax, ecx
mov edx, eax
imul edx, edx, 0x2a75
rol edx, 0xe
ror eax, 0xe
xor edx, eax
add r9d, edx
cmp rsi, r12
jb 0x100397dac
mov dword [rsp + 0x44], edx
mov dword [rsp + 0x40], r9d
shr r11d, 0xc
mov rax, qword [r13]
mov qword [rsp + 0x60], rax
cmp r11d, 3
je 0x100397e22
sub r11d, 0xa
neg r11d
sbb r10d, r10d
add r10d, 3
jmp 0x100397e28
mov r10d, 2
mov r11, r14
neg r11
sub r10d, 2
je 0x100397e50
cmp r10d, 1
je 0x100397e40
or r10, 0xffffffffffffffff
jmp 0x100397e58
mov r10d, 8
add rax, r11
mov qword [rsp + 0x60], rax
jmp 0x100397e58
mov r10, r15
add dword [rsp + 0x60], r11d
xor r11d, r11d
test r10, r10
je 0x100397eb4
movzx eax, byte [rsp + r11 + 0x60]
inc r11
sub eax, 0x1279a1d2
add r9d, eax
add eax, edx
mov ecx, eax
imul ecx, ecx, 0x2a75
rol ecx, 0xe
ror eax, 0xe
xor ecx, eax
mov eax, ecx
imul eax, eax, 0x2a75
rol eax, 0xe
ror ecx, 0xe
xor eax, ecx
mov edx, eax
imul edx, edx, 0x2a75
rol edx, 0xe
ror eax, 0xe
xor edx, eax
add r9d, edx
cmp r11, r10
jb 0x100397e60
mov dword [rsp + 0x44], edx
mov dword [rsp + 0x40], r9d
mov rcx, qword [rsp + 0x48]
add r10, r13
mov r13, qword [rsp + 0x38]
jmp 0x100397d16
xor r8d, r8d
mov esi, dword [rsp + 0x30]
mov rbp, qword [rsp + 0x88]
mov r12, qword [rsp + 0x98]
mov r14, qword [rsp + 0xa0]
mov r11, qword [rsp + 0xa8]
sub r11, r10
je 0x100397f45
movzx eax, byte [r8 + r10]
inc r8
sub eax, 0x1279a1d2
add r9d, eax
add eax, edx
mov ecx, eax
imul ecx, ecx, 0x2a75
rol ecx, 0xe
ror eax, 0xe
xor ecx, eax
mov eax, ecx
imul eax, eax, 0x2a75
rol eax, 0xe
ror ecx, 0xe
xor eax, ecx
mov edx, eax
imul edx, edx, 0x2a75
rol edx, 0xe
ror eax, 0xe
xor edx, eax
add r9d, edx
cmp r8, r11
jb 0x100397ef2
mov dword [rsp + 0x44], edx
mov dword [rsp + 0x40], r9d
mov rbx, qword [rsp + 0x80]
xor ecx, ecx
mov rax, rcx
inc rcx
and eax, 7
cmp rcx, 8
mov al, byte [rsp + rax + 0x40]
mov byte [rsp + rcx + 0xaf], al
jb 0x100397f4f
mov eax, 0x5819f7c2
mov rax, qword [rsp + 0xb0]
mov r13, r14
mov r11, rbx
mov qword [rsp + 0x50], rbp
mov qword [rsp + 0x48], rbx
and r13d, 7
mov r10, rbp
je 0x100398445
xor r8d, r8d
xor r11d, r11d
mov ebx, esi
and dword [rsp + 0x58], r8d
not ebx
test r13d, r13d
mov dword [rsp + 0x38], r8d
jle 0x100397fe6
lea r9d, [r8 + 0x38]
cmp r11d, r15d
movzx edx, byte [r10]
jge 0x100397fc5
lea ecx, [r9 - 0x20]
shl edx, cl
or dword [rsp + 0x58], edx
jmp 0x100397fcd
mov ecx, r9d
shl edx, cl
or r8d, edx
inc r11d
inc r10
sub r9d, 8
cmp r11d, r13d
jl 0x100397fb0
mov dword [rsp + 0x38], r8d
mov qword [rsp + 0x50], r10
mov edx, esi
movzx r10d, word [rsp + 0xb6]
movzx r9d, ax
mov ecx, esi
mov r8d, dword [rsp + 0xb4]
movzx r11d, r8w
xor edx, r11d
rol edx, 3
rol ecx, 8
imul edx, r10d
sub edx, ecx
xor ebx, edx
mov esi, ebx
mov ecx, ebx
shr ecx, 7
xor esi, r10d
imul esi, r11d
add esi, ecx
xor esi, dword [rsp + 0x30]
mov ecx, esi
lea edx, [r8 + rsi]
ror edx, 1
rol ecx, 7
movzx r8d, word [rsp + 0xb2]
imul edx, r8d
add ecx, edx
xor ebx, ecx
mov ecx, ebx
mov edx, dword [rsp + 0xb4]
ror ecx, 8
sub ecx, r9d
imul ecx, r11d
xor esi, ecx
mov ecx, eax
xor edx, esi
sub ecx, edx
mov edx, eax
xor ebx, ecx
sub edx, ebx
mov ecx, ebx
rol edx, 3
ror ecx, 0xf
imul edx, r11d
xor ecx, edx
xor esi, ecx
mov ecx, esi
sub ecx, dword [rsp + 0xb4]
sub ecx, r8d
xor ebx, ecx
mov ecx, ebx
mov edx, ebx
ror edx, 9
xor ecx, r10d
imul ecx, r9d
xor edx, ecx
xor esi, edx
mov edx, esi
mov ecx, esi
xor edx, r8d
rol edx, 3
rol ecx, 0xb
imul edx, r10d
xor ecx, edx
xor ebx, ecx
mov edx, ebx
xor edx, r9d
mov ecx, ebx
shr ecx, 7
imul edx, r11d
xor edx, ecx
xor esi, edx
mov ecx, esi
mov edx, esi
sub edx, r10d
shr ecx, 9
rol edx, 6
imul edx, r8d
xor edx, ecx
xor ebx, edx
mov edx, ebx
xor edx, r11d
rol edx, 4
mov ecx, ebx
xor ebx, dword [rsp + 0x38]
shr ecx, 7
imul edx, r9d
add edx, ecx
xor r9d, r9d
xor edx, dword [rsp + 0x58]
xor esi, edx
mov ecx, esi
mov edx, ebx
test r13d, r13d
jle 0x10039812b
mov r8, qword [rsp + 0x48]
cmp r9d, r15d
jge 0x100398112
rol ecx, 8
mov byte [r8], cl
inc r8
xor dil, cl
jmp 0x10039811e
rol edx, 8
mov byte [r8], dl
inc r8
xor dil, dl
inc r9d
cmp r9d, r13d
jl 0x1003980ff
mov qword [rsp + 0x48], r8
lea ecx, [r13 - 4]
test ecx, ecx
jle 0x10039842d
sub r15d, ecx
shl r15d, 3
mov ecx, r15d
shr ebx, cl
shl ebx, cl
mov r11, qword [rsp + 0x48]
mov r13d, dword [rsp + 0x38]
mov r10, qword [rsp + 0x50]
mov r15, r14
shr r15, 3
test r15, r15
je 0x100398375
mov r12d, dword [rsp + 0x58]
mov r14d, dword [rsp + 0xb4]
movzx ecx, word [rsp + 0xb6]
mov dword [rsp + 0x68], ecx
neg ecx
mov dword [rsp + 0x50], ecx
mov ebp, dword [rsp + 0x50]
movzx ecx, word [rsp + 0xb2]
mov dword [rsp + 0x48], ecx
movzx ecx, r14w
mov dword [rsp + 0x38], ecx
movzx ecx, ax
mov dword [rsp + 0x30], ecx
movzx r8d, byte [r10 + 4]
movzx r9d, byte [r10 + 1]
movzx ecx, byte [r10]
shl ecx, 8
shl r8d, 8
add r10, 8
or r9d, ecx
shl r9d, 8
movzx ecx, byte [r10 - 6]
or r9d, ecx
shl r9d, 8
movzx ecx, byte [r10 - 5]
or r9d, ecx
movzx ecx, byte [r10 - 3]
or r8d, ecx
xor esi, r9d
shl r8d, 8
movzx ecx, byte [r10 - 2]
mov edx, esi
xor edx, dword [rsp + 0x38]
or r8d, ecx
shl r8d, 8
movzx ecx, byte [r10 - 1]
or r8d, ecx
rol edx, 3
mov ecx, esi
rol ecx, 8
imul edx, dword [rsp + 0x68]
sub edx, ecx
xor edx, r8d
xor ebx, edx
mov edx, ebx
mov ecx, ebx
xor edx, dword [rsp + 0x68]
shr ecx, 7
imul edx, dword [rsp + 0x38]
add edx, ecx
xor esi, edx
lea edx, [r14 + rsi]
mov ecx, esi
ror edx, 1
rol ecx, 7
imul edx, dword [rsp + 0x48]
add ecx, edx
mov edx, r14d
xor ebx, ecx
mov ecx, ebx
ror ecx, 8
sub ecx, dword [rsp + 0x30]
imul ecx, dword [rsp + 0x38]
xor esi, ecx
xor edx, esi
mov ecx, eax
sub ecx, edx
mov edx, eax
xor ebx, ecx
sub edx, ebx
mov ecx, ebx
rol edx, 3
ror ecx, 0xf
imul edx, dword [rsp + 0x38]
xor ecx, edx
xor esi, ecx
movzx edx, word [rsp + 0xb2]
mov ecx, esi
sub ecx, r14d
sub ecx, edx
xor ebx, ecx
mov edx, ebx
mov ecx, ebx
xor ecx, dword [rsp + 0x68]
ror edx, 9
imul ecx, dword [rsp + 0x30]
xor edx, ecx
xor esi, edx
movzx ecx, word [rsp + 0xb2]
mov edx, esi
xor edx, ecx
mov ecx, esi
rol edx, 3
rol ecx, 0xb
imul edx, dword [rsp + 0x68]
xor ecx, edx
xor ebx, ecx
mov edx, ebx
xor edx, dword [rsp + 0x30]
mov ecx, ebx
shr ecx, 7
imul edx, dword [rsp + 0x38]
xor edx, ecx
xor esi, edx
lea edx, [rsi + rbp]
rol edx, 6
movzx ecx, word [rsp + 0xb2]
imul edx, ecx
mov ecx, esi
shr ecx, 9
xor edx, ecx
xor ebx, edx
mov edx, ebx
mov ecx, ebx
xor ebx, r13d
xor edx, dword [rsp + 0x38]
mov byte [r11 + 7], bl
shr ecx, 7
mov r13d, r8d
rol edx, 4
imul edx, dword [rsp + 0x30]
add edx, ecx
xor edx, r12d
mov r12d, r9d
xor esi, edx
mov byte [r11 + 3], sil
xor dil, sil
ror esi, 8
mov byte [r11 + 2], sil
xor dil, bl
ror ebx, 8
mov byte [r11 + 6], bl
xor dil, sil
ror esi, 8
xor dil, bl
ror ebx, 8
mov byte [r11 + 1], sil
xor dil, sil
ror esi, 8
xor dil, bl
mov byte [r11 + 5], bl
ror ebx, 8
mov byte [r11], sil
mov byte [r11 + 4], bl
add r11, 8
mov cl, bl
xor cl, sil
xor dil, cl
ror esi, 8
ror ebx, 8
sub r15, 1
jne 0x1003981a2
mov rbp, qword [rsp + 0x88]
mov r14, qword [rsp + 0xa0]
mov r12, qword [rsp + 0x98]
mov al, byte [r14 + rbp + 8]
xor al, dil
je 0x10039846f
call fcn.10000228c
and r12, 0xfffffffffffffff8
lea r13, [0x10006d7ac]
mov r10, rax
mov r9d, 0xffff
mov rax, 0xfffffffffffff000
and r10, rax
lea r8, [r12 + 0xfff]
and r8, rax
xor edi, edi
mov r11, qword [rsp + 0x90]
mov qword [r11 + 0x10], r13
mov rcx, qword [0x1003fe198]
imul rcx, rcx, 0x343fd
shl rdi, 0x10
shr r9, 0x10
add rcx, 0x269ec3
mov rax, rcx
shr rax, 0x10
movzx edx, ax
or rdi, rdx
test r9, r9
jne 0x1003983c6
mov qword [0x1003fe198], rcx
movabs rax, 0x8000800080008001
mul rdi
mov rax, qword [rsp + 0x78]
shr rdx, 0xf
mov qword [rax + 0x98], r10
imul rdx, rdx, 0xffff
sub rdi, rdx
inc rdi
mov qword [rax + 0xb0], rdi
mov qword [rsp + 0x78], r9
jmp 0x100398465
xor ebx, ebx
test ecx, ecx
jns 0x100398145
neg ecx
shl ecx, 3
shr esi, cl
shl esi, cl
jmp 0x100398145
xor ebx, ebx
mov dword [rsp + 0x58], esi
mov r13d, esi
xor esi, esi
not r13d
jmp 0x100398154
mov rax, qword [rsp + 0x78]
mov qword [r12], rax
add r12, 8
cmp r12, r8
jb 0x100398458
jmp 0x100398588
mov rbx, rbp
mov rax, qword [0x10014dad0]
lea r15, [0x100000000]
mov rsi, r15
mov r13, qword [rsp + 0x80]
sub rbx, r13
sub rsi, rax
jne 0x10039849c
test rbx, rbx
je 0x100398575
mov r11, r13
mov rcx, qword [0x100019a28]
xor edi, edi
sub r11, rbp
sub ebp, r15d
lea r8d, [rcx - 1]
lea r12d, [r14 + rbp]
test r8d, r8d
lea r14, [0x100000000]
js 0x1003984f2
lea eax, [r8 + rdi]
cdq
sub eax, edx
sar eax, 1
movsxd rdx, eax
mov r9d, dword [r14 + rdx*4 + 0x19a2c]
and r9d, 0xfffffff
cmp ebp, r9d
jae 0x1003984e8
lea r8d, [rax - 1]
jmp 0x1003984ed
jbe 0x1003984f7
lea edi, [rax + 1]
cmp r8d, edi
jge 0x1003984c2
movsxd r10, edi
jmp 0x10039856e
movsxd r10, eax
jmp 0x10039856e
mov edx, dword [r14 + r10*4 + 0x19a2c]
mov eax, edx
and eax, 0xfffffff
cmp eax, r12d
jae 0x100398575
mov edi, edx
mov r8, rdx
sar edx, 0x1e
shl edi, 2
and r8d, 0xfffffff
and edx, 3
sar edi, 0x1e
add r8, r15
xor r9d, r9d
and edi, 3
sub edi, 1
je 0x10039854a
sub edi, 1
je 0x100398545
cmp edi, 1
jne 0x100398550
mov r9, rsi
jmp 0x100398550
mov r9, rbx
jmp 0x100398550
mov r9, rsi
sub r9, rbx
sub edx, 2
je 0x100398560
cmp edx, 1
jne 0x10039856b
add qword [r8 + r11], r9
jmp 0x100398564
add dword [r8 + r11], r9d
mov rcx, qword [0x100019a28]
inc r10
mov eax, ecx
cmp r10, rax
jb 0x1003984fc
mov eax, dword [0x100015964]
mov eax, 0xbbbcd15b
mov r11, qword [rsp + 0x90]
mov qword [r11 + 0x10], r13
mov rcx, qword [rsp + 0xb8]
xor rcx, rsp
call fcn.1003005f0
mov rbx, qword [rsp + 0x110]
add rsp, 0xc0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret