Function at 0x140159f00
Capabilities:
Allocate or change rwx memory

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
mov eax, 0x10078
call fcn.140183a10
sub rsp, rax
mov r14, r9
mov edi, r8d
mov rbx, rdx
mov rsi, rcx
mov rax, qword [0x14030f948]
xor rax, rsp
mov qword [rsp + 0x10070], rax
mov rcx, rdx
mov edx, r8d
mov r8d, 4
call fcn.14015a235
mov ebp, eax
mov r15d, edi
cmp eax, 0xffffffff
jne 0x140159f69
mov rcx, rbx
mov edx, edi
mov r8d, 8
call fcn.14015a235
mov ebp, eax
cmp eax, 0xffffffff
je 0x140159fc2
mov rcx, rbx
mov rdx, r14
mov r8, r15
call fcn.140186330
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
mov rdx, rbx
mov r8, r15
call qword [sym.imp.KERNEL32.dll_FlushInstructionCache]
mov rcx, rbx
mov edx, edi
mov r8d, ebp
call fcn.14015a235
mov sil, 1
mov rcx, qword [rsp + 0x10070]
xor rcx, rsp
call fcn.140183a80
mov eax, esi
add rsp, 0x10078
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov r9, qword [rsi + 0x18]
movzx ecx, byte [rsi]
cmp r9, rbx
ja 0x140159fde
mov eax, 1
shl rax, cl
add rax, r9
cmp rax, rbx
ja 0x140159ffa
mov dword [rsp + 0x20], ecx
lea rdx, str.NaClSysToUser:_sysaddr_0x_08I64x__mem_start_0x_08I64x__addr_space__d_bits_n
mov ecx, 0xfffffffc
mov r8, rbx
call fcn.1400b8218
mov r9, qword [rsi + 0x18]
mov rbp, rbx
sub rbp, r9
lea r12, [r15 + rbp]
cmp r12, rbp
jbe 0x14015a00f
cmp r12, qword [rsi + 0x48]
jbe 0x14015a013
xor esi, esi
jmp 0x140159f9c
shr rbp, 0xc
dec r12
shr r12, 0xc
sub r12, rbp
inc r12
je 0x14015a215
lea rax, [rsi + 0x578]
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x48], r14
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x38], rbx
mov dword [rsp + 0x2c], edi
mov rcx, qword [rsp + 0x58]
mov rdx, rbp
call fcn.14003c9f2
test rax, rax
je 0x14015a206
mov rdi, qword [rax]
mov qword [rsp + 0x30], rbp
sub rdi, rbp
add rdi, qword [rax + 8]
cmp rdi, r12
mov qword [rsp + 0x50], r12
cmova rdi, r12
mov qword [rsp + 0x60], rax
cmp dword [rax + 0x14], 0
je 0x14015a1e1
test rdi, rdi
je 0x14015a1e1
mov r12, qword [rsp + 0x30]
shl r12, 0xc
mov r15, r12
neg r15
xor ebx, ebx
movzx r9d, byte [rsi]
test r15, r15
je 0x14015a0ba
mov rax, r12
mov ecx, r9d
shr rax, cl
test rax, rax
je 0x14015a0ce
mov ecx, 0xfffffffc
lea rdx, str.NaClUserToSys:_uaddr_0x_08I64x__addr_space__d_bits_n
mov r8, r12
call fcn.1400b8218
mov rbp, rsi
mov r13, qword [rsi + 0x18]
mov rax, qword [rsp + 0x60]
mov r14, qword [rax]
shl r14, 0xc
add r14, qword [rax + 0x30]
add r13, r12
add r14, r15
mov r8d, 0x10000
cmp r14, 0x10001
jl 0x14015a100
mov r14d, 0x10000
cmp r14, 0xffff
ja 0x14015a10e
sub r8, r14
jmp 0x14015a111
xor r8d, r8d
lea rcx, [rsp + r14]
add rcx, 0x70
mov dl, 0xf4
call fcn.1401867a0
lea rcx, [rsp + 0x70]
mov rdx, r13
mov r8, r14
call fcn.140186330
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
test eax, eax
je 0x14015a00f
mov edx, 0x10000
mov rcx, r13
mov r8d, 0x1000
mov r9d, 0x40
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
test rax, rax
jne 0x14015a17a
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 0xfffffffc
lea rdx, str.UnmapFiles:_VirtualAlloc_failed_with__d_n
mov r8d, eax
call fcn.1400b8218
mov r8d, 0x10000
mov rcx, r13
lea rdx, [rsp + 0x70]
call fcn.140186330
mov edx, 0x10000
mov rcx, r13
mov r8d, 0x20
lea r9, [rsp + 0x6c]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x14015a1c4
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 0xfffffffc
lea rdx, str.UnmapFiles:_VirtualProtect_failed_with__d_n
mov r8d, eax
call fcn.1400b8218
inc rbx
add r15, 0xfffffffffffff000
add r12, 0x1000
cmp rbx, rdi
mov rsi, rbp
jb 0x14015a0a3
mov rbp, qword [rsp + 0x30]
add rbp, rdi
mov r12, qword [rsp + 0x50]
sub r12, rdi
mov r14, qword [rsp + 0x48]
mov r15, qword [rsp + 0x40]
mov edi, dword [rsp + 0x2c]
mov rbx, qword [rsp + 0x38]
jmp 0x14015a20c
inc rbp
dec r12
test r12, r12
jne 0x14015a049
mov rcx, rbx
mov edx, edi
mov r8d, 8
call fcn.14015a235
mov ebp, eax
cmp eax, 0xffffffff
jne 0x140159f69
jmp 0x14015a00f