Function at 0x140012210
Capabilities:
Read file on windows

Disassembly:
push r12
mov eax, 0x1180
push rbp
push rdi
push rsi
push rbx
call fcn.140023c00
sub rsp, rax
movaps xmmword [rsp + 0x1170], xmm6
mov r9d, 2
lea r8, [0x1400284d0]
movdqu xmm1, xmmword [rdx]
lea rbp, [rsp + 0x20]
mov rbx, rcx
lea rcx, [rsp + 0xa0]
movaps xmmword [rsp + 0x20], xmm1
mov rdx, rbp
call sym.os__vfopen.constprop.0.isra.0
cmp byte [rsp + 0xa0], 0
jne 0x1400127e0
mov rsi, qword [rsp + 0xc8]
xor edx, edx
mov r8d, 2
mov rcx, rsi
call sub.ucrtbase.dll_fseek
mov rcx, rsi
mov r12d, eax
call sub.ucrtbase.dll_ftell
test r12d, r12d
mov edi, eax
cdqe
setne dl
test rax, rax
je 0x1400122a1
test dl, dl
jne 0x1400129c0
test rax, rax
jns 0x140012390
test dl, dl
je 0x140012390
lea rax, str.ftell_failed
mov ecx, 0x18
mov dword [rsp + 0x180], 0
mov qword [rsp + 0x170], rax
mov rax, qword [0x140028fc0]
mov qword [rsp + 0x178], rax
call sym._v_malloc
movdqa xmm1, xmmword [rsp + 0x170]
movups xmmword [rax], xmm1
mov rdx, qword [rsp + 0x180]
pxor xmm0, xmm0
mov rcx, rsi
mov qword [rax + 0x10], rdx
lea rdx, [rax + 0x10]
movaps xmmword [rsp + 0x70], xmm0
movaps xmmword [rsp + 0x80], xmm0
movaps xmmword [rsp + 0x90], xmm0
mov byte [rsp + 0x70], 1
mov qword [rsp + 0x78], rax
mov dword [rsp + 0x80], 2
mov qword [rsp + 0x88], rax
mov qword [rsp + 0x90], rdx
call sub.ucrtbase.dll_fclose
mov rax, qword [rsp + 0x90]
movdqa xmm1, xmmword [rsp + 0x70]
movdqa xmm2, xmmword [rsp + 0x80]
mov qword [rsp + 0x190], rax
mov rax, qword [rsp + 0x1a0]
movdqa xmm3, xmmword [rsp + 0x190]
movups xmmword [rbx], xmm1
mov qword [rbx + 0x30], rax
movups xmmword [rbx + 0x10], xmm2
movups xmmword [rbx + 0x20], xmm3
jmp 0x140012822
mov rcx, rsi
call sub.ucrtbase.dll_rewind
movdqa xmm2, xmmword [0x1400606c0]
movdqa xmm3, xmmword [0x1400606d0]
mov dword [rsp + 0x198], edi
mov byte [rsp + 0x170], 0
movups xmmword [rsp + 0x178], xmm2
movdqa xmm4, xmmword [rsp + 0x170]
movups xmmword [rsp + 0x188], xmm3
movdqa xmm2, xmmword [rsp + 0x190]
movdqa xmm5, xmmword [rsp + 0x180]
movaps xmmword [rsp + 0x70], xmm4
movaps xmmword [rsp + 0x90], xmm2
mov edi, dword [rsp + 0x98]
movaps xmmword [rsp + 0x80], xmm5
test edi, edi
jne 0x1400124a0
xor eax, eax
lea rdi, [rsp + 0x180]
mov ecx, 0x1fe
mov qword [rsp + 0x170], 0
mov qword [rsp + 0x178], 0
lea r12, [rsp + 0x30]
rep stosq qword [rdi], rax
mov ecx, 0x1000
lea rdi, [rsp + 0x170]
call sym.vcalloc_noscan
mov dword [rsp + 0x30], 1
mov qword [rsp + 0x38], rax
movabs rax, 0x100001000
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x48], rax
nop dword [rax]
mov r9, rsi
mov r8d, 0x1000
mov edx, 1
mov rcx, rdi
call sub.ucrtbase.dll_fread
test eax, eax
jle 0x140012678
mov r8d, eax
mov rdx, rdi
mov rcx, r12
call sym.array_push_many.part.0
jmp 0x140012470
lea ecx, [rdi + 1]
movsxd rcx, ecx
call sym.malloc_noscan
movsxd r8, edi
mov r9, rsi
mov edx, 1
mov rcx, rax
mov rbp, rax
call sub.ucrtbase.dll_fread
mov rcx, rsi
mov rdi, rax
call sub.ucrtbase.dll_feof
mov rcx, rsi
mov r12d, eax
call sub.ucrtbase.dll_ferror
test r12d, r12d
jne 0x1400125d0
test eax, eax
je 0x1400125d0
lea rax, str.fread_failed
pxor xmm0, xmm0
mov ecx, 0x18
mov qword [rsp + 0x1a0], 0
mov qword [rsp + 0x120], rax
mov rax, qword [0x140028fc0]
movaps xmmword [rsp + 0x170], xmm0
movaps xmmword [rsp + 0x180], xmm0
movaps xmmword [rsp + 0x190], xmm0
mov qword [rsp + 0x128], rax
mov dword [rsp + 0x130], 0
call sym._v_malloc
mov rcx, rsi
movdqa xmm1, xmmword [rsp + 0x120]
mov rdi, rax
movups xmmword [rax], xmm1
mov rax, qword [rsp + 0x130]
mov qword [rdi + 0x10], rax
call sub.ucrtbase.dll_fclose
mov qword [rsp + 0x178], rdi
mov rax, qword [rsp + 0x1a0]
mov qword [rsp + 0x188], rdi
add rdi, 0x10
mov byte [rsp + 0x170], 1
movdqa xmm2, xmmword [rsp + 0x170]
mov dword [rsp + 0x180], 2
movdqa xmm0, xmmword [rsp + 0x180]
mov qword [rsp + 0x190], rdi
movdqa xmm3, xmmword [rsp + 0x190]
mov qword [rbx + 0x30], rax
movups xmmword [rbx], xmm2
movups xmmword [rbx + 0x10], xmm0
movups xmmword [rbx + 0x20], xmm3
jmp 0x140012822
movsxd rax, edi
mov byte [rbp + rax], 0
test edi, edi
je 0x140012a08
movdqa xmm2, xmmword [0x1400606c0]
movdqa xmm3, xmmword [0x1400606d0]
mov rcx, rsi
mov qword [rsp + 0x120], rbp
mov dword [rsp + 0x128], edi
mov dword [rsp + 0x12c], 0
movdqa xmm6, xmmword [rsp + 0x120]
movups xmmword [rsp + 0x178], xmm2
movups xmmword [rsp + 0x188], xmm3
call sub.ucrtbase.dll_fclose
mov byte [rsp + 0x170], 0
movdqa xmm4, xmmword [rsp + 0x170]
movups xmmword [rsp + 0x198], xmm6
movups xmmword [rbx], xmm4
movdqa xmm5, xmmword [rsp + 0x180]
mov rax, qword [rsp + 0x1a0]
movdqa xmm6, xmmword [rsp + 0x190]
mov qword [rbx + 0x30], rax
movups xmmword [rbx + 0x10], xmm5
movups xmmword [rbx + 0x20], xmm6
jmp 0x140012822
mov rcx, rsi
call sub.ucrtbase.dll_feof
test eax, eax
jne 0x140012840
mov rcx, rsi
call sub.ucrtbase.dll_ferror
test eax, eax
je 0x140012470
lea rax, str.file_read_error
mov ecx, 0x18
pxor xmm6, xmm6
mov dword [rsp + 0x130], 0
mov qword [rsp + 0x120], rax
mov rax, qword [0x140028fc8]
mov qword [rsp + 0x128], rax
call sym._v_malloc
mov rdx, qword [rsp + 0x130]
mov ecx, 8
movdqa xmm4, xmmword [rsp + 0x120]
movaps xmmword [rsp + 0x130], xmm6
movups xmmword [rax], xmm4
mov qword [rax + 0x10], rdx
movaps xmmword [rsp + 0x120], xmm6
mov qword [rsp + 0x138], rax
mov qword [rsp + 0x128], rax
add rax, 0x10
movaps xmmword [rsp + 0x140], xmm6
mov dword [rsp + 0x130], 2
movdqu xmm5, xmmword [rsp + 0x128]
mov qword [rsp + 0x140], rax
movdqu xmm0, xmmword [rsp + 0x138]
movaps xmmword [rsp + 0x50], xmm5
movaps xmmword [rsp + 0x60], xmm0
call sym._v_malloc
movaps xmmword [rsp + 0xd0], xmm6
mov rcx, rsi
movdqa xmm1, xmmword [rsp + 0x60]
movaps xmmword [rsp + 0xf0], xmm6
movaps xmmword [rsp + 0x100], xmm6
movdqa xmm6, xmmword [rsp + 0x50]
mov qword [rsp + 0x110], 0
mov byte [rsp + 0xd0], 1
movups xmmword [rsp + 0xd8], xmm6
movups xmmword [rsp + 0xe8], xmm1
call sub.ucrtbase.dll_fclose
mov rax, qword [rsp + 0xf0]
movdqa xmm2, xmmword [rsp + 0xd0]
movdqa xmm3, xmmword [rsp + 0xe0]
mov qword [rsp + 0x190], rax
mov rax, qword [rsp + 0x1a0]
movdqa xmm4, xmmword [rsp + 0x190]
movups xmmword [rbx], xmm2
mov qword [rbx + 0x30], rax
movups xmmword [rbx + 0x10], xmm3
movups xmmword [rbx + 0x20], xmm4
jmp 0x140012822
mov rax, qword [rsp + 0xc0]
movdqa xmm3, xmmword [rsp + 0xa0]
movdqa xmm4, xmmword [rsp + 0xb0]
mov qword [rsp + 0x190], rax
mov rax, qword [rsp + 0x1a0]
movdqa xmm5, xmmword [rsp + 0x190]
movups xmmword [rbx], xmm3
mov qword [rbx + 0x30], rax
movups xmmword [rbx + 0x10], xmm4
movups xmmword [rbx + 0x20], xmm5
movaps xmm6, xmmword [rsp + 0x1170]
mov rax, rbx
add rsp, 0x1180
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov ecx, 8
call sym._v_malloc
mov ecx, 8
call sym._v_malloc
mov r8, qword [rsp + 0x30]
mov r9, qword [rsp + 0x38]
mov rcx, rbp
mov rax, qword [rsp + 0x40]
mov rdx, qword [rsp + 0x48]
mov byte [rsp + 0x120], 0
movdqa xmm0, xmmword [0x1400606c0]
movdqa xmm3, xmmword [0x1400606d0]
mov qword [rsp + 0x148], r8
mov qword [rsp + 0x150], r9
movups xmmword [rsp + 0x128], xmm0
movdqa xmm4, xmmword [rsp + 0x120]
movups xmmword [rsp + 0x138], xmm3
movdqa xmm6, xmmword [rsp + 0x140]
movdqa xmm5, xmmword [rsp + 0x130]
mov qword [rsp + 0x158], rax
movdqa xmm0, xmmword [rsp + 0x150]
mov qword [rsp + 0x160], rdx
mov qword [rsp + 0x60], rax
mov rax, qword [rsp + 0x160]
movaps xmmword [rsp + 0x100], xmm0
mov qword [rsp + 0x110], rax
movdqu xmm2, xmmword [rsp + 0x108]
movaps xmmword [rsp + 0xf0], xmm6
movdqu xmm1, xmmword [rsp + 0xf8]
mov qword [rsp + 0x68], rdx
lea rdx, [rsp + 0x120]
movaps xmmword [rsp + 0xe0], xmm5
mov qword [rsp + 0x50], r8
mov qword [rsp + 0x58], r9
movaps xmmword [rsp + 0xd0], xmm4
movaps xmmword [rsp + 0x120], xmm1
movaps xmmword [rsp + 0x130], xmm2
call sym.strings__Builder_str
movdqu xmm6, xmmword [rsp + 0x20]
movdqa xmm3, xmmword [0x1400606c0]
mov rcx, rsi
movdqa xmm4, xmmword [0x1400606d0]
movups xmmword [rsp + 0x178], xmm3
movups xmmword [rsp + 0x188], xmm4
call sub.ucrtbase.dll_fclose
movups xmmword [rsp + 0x198], xmm6
movdqa xmm6, xmmword [rsp + 0x180]
movdqa xmm0, xmmword [rsp + 0x190]
mov byte [rsp + 0x170], 0
mov rax, qword [rsp + 0x1a0]
movdqa xmm5, xmmword [rsp + 0x170]
movups xmmword [rbx + 0x10], xmm6
mov qword [rbx + 0x30], rax
movups xmmword [rbx], xmm5
movups xmmword [rbx + 0x20], xmm0
jmp 0x140012822
lea rax, str.fseek_failed
mov ecx, 0x18
mov dword [rsp + 0x180], 0
mov qword [rsp + 0x170], rax
mov rax, qword [0x140028fc0]
mov qword [rsp + 0x178], rax
call sym._v_malloc
movdqa xmm0, xmmword [rsp + 0x170]
movups xmmword [rax], xmm0
jmp 0x1400122f1
mov rcx, rbp
call sym.strlen
movdqa xmm6, xmmword [0x1400606d0]
mov rcx, rsi
movdqa xmm5, xmmword [0x1400606c0]
mov dword [rsp + 0x12c], 0
mov qword [rsp + 0x120], rbp
mov dword [rsp + 0x128], eax
movups xmmword [rsp + 0x188], xmm6
movdqa xmm6, xmmword [rsp + 0x120]
movups xmmword [rsp + 0x178], xmm5
call sub.ucrtbase.dll_fclose
mov byte [rsp + 0x170], 0
movdqa xmm0, xmmword [rsp + 0x170]
movups xmmword [rsp + 0x198], xmm6
movups xmmword [rbx], xmm0
jmp 0x140012647