Function at 0x100676bb0
Capabilities:
Write file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x108
mov rax, qword [sym.vim.exe_NameBuff]
mov esi, 0x2a2a
mov qword [rsp + 0x150], rcx
mov dword [rsp + 0x158], edx
mov rdx, rcx
mov rcx, qword [rax]
mov dword [rsp + 0x160], r8d
call sub.msys_2.0.dll_strcpy
mov rax, qword [sym.vim.exe_NameBuff]
mov rcx, qword [rax]
call sym.vim.exe_add_pathsep
mov rax, qword [sym.vim.exe_NameBuff]
mov rbx, qword [rax]
mov rcx, rbx
call sub.msys_2.0.dll_strlen
mov rdx, qword [sym.vim.exe_NameBuff]
mov ecx, 1
lea r9, [rsp + 0xa8]
add rbx, rax
lea r8, [rsp + 0x98]
mov word [rbx], si
mov byte [rbx + 2], 0
mov dword [rsp + 0x20], 0x22
call sym.vim.exe_gen_expand_wildcards
test eax, eax
je 0x100676c05
mov ebx, dword [rsp + 0x98]
test ebx, ebx
je 0x100676c05
lea rax, [rsp + 0xc0]
mov r8d, 0xa
mov edx, 1
mov rcx, rax
mov qword [rsp + 0x70], rax
call sym.vim.exe_ga_init2
mov r11d, dword [rsp + 0x98]
mov ebx, dword [rsp + 0xc0]
test r11d, r11d
jle 0x1004b2e1c
xor esi, esi
lea rbp, [0x1006c1a40]
lea rdi, [rsp + 0x96]
jmp 0x1004b2d1f
cmp byte [r13], 0x2e
jne 0x1004b2d0e
movzx r14d, byte [r15 + r12 - 3]
mov eax, r14d
and eax, 0xffffffdf
sub eax, 0x41
cmp al, 0x19
ja 0x1004b2d0e
movzx r13d, byte [r15 + r12 - 2]
mov eax, r13d
and eax, 0xffffffdf
sub eax, 0x41
cmp al, 0x19
ja 0x1004b2d0e
movzx eax, byte [r15 + r12 - 1]
lea edx, [rax - 0x41]
cmp dl, 0x19
jbe 0x1004b3643
cmp al, 0x78
je 0x1004b364b
add rsi, 1
cmp dword [rsp + 0x98], esi
jle 0x1004b2e1c
mov rax, qword [rsp + 0xa8]
mov r15, qword [rax + rsi*8]
mov rcx, r15
call sub.msys_2.0.dll_strlen
cmp eax, 4
jle 0x1004b2d0e
movsxd r12, eax
mov rdx, rbp
lea r13, [r15 + r12 - 4]
mov rcx, r13
call sub.msys_2.0.dll_strcasecmp
test eax, eax
jne 0x1004b2cc7
mov r14d, 0x65
mov r13d, 0x6e
mov byte [rsp + 0x96], r14b
mov byte [rsp + 0x97], r13b
test ebx, ebx
jle 0x1004b36ca
mov r15, qword [rsp + 0xd0]
xor r12d, r12d
mov r8d, 2
mov rdx, r15
mov rcx, rdi
call sub.msys_2.0.dll_strncmp
test eax, eax
je 0x1004b2d0e
add r12d, 2
add r15, 2
cmp r12d, ebx
jl 0x1004b2d82
cmp r12d, ebx
jne 0x1004b2d0e
mov rcx, qword [rsp + 0x70]
mov edx, 2
call sym.vim.exe_ga_grow
test eax, eax
je 0x1004b3703
movsxd rax, dword [rsp + 0xc0]
add rsi, 1
lea edx, [rax + 1]
mov dword [rsp + 0xc0], edx
mov rdx, qword [rsp + 0xd0]
mov byte [rdx + rax], r14b
movsxd rax, dword [rsp + 0xc0]
lea edx, [rax + 1]
mov dword [rsp + 0xc0], edx
mov rdx, qword [rsp + 0xd0]
mov byte [rdx + rax], r13b
mov ebx, dword [rsp + 0xc0]
cmp dword [rsp + 0x98], esi
jg 0x1004b2d1f
test ebx, ebx
jle 0x1004b3545
lea rax, [rsp + 0xa3]
mov qword [rsp + 0x50], 0
mov qword [rsp + 0x80], rax
lea rax, [rsp + 0xb0]
mov qword [rsp + 0x88], rax
lea rax, [rsp + 0x9c]
mov qword [rsp + 0x78], rax
movabs rax, 0x78782d73676174
mov rbx, qword [rsp + 0x50]
mov qword [rsp + 0xb8], rax
mov rax, qword [rsp + 0xd0]
movzx edx, byte [rax + rbx]
mov byte [rsp + 0xbd], dl
movzx eax, byte [rax + rbx + 1]
mov byte [rsp + 0xbe], al
cmp al, 0x6e
jne 0x1004b2e9d
cmp dl, 0x65
je 0x1004b366e
mov dword [rsp + 0xa3], 0x7878782e
mov byte [rsp + 0xa7], 0
mov byte [rsp + 0xa4], dl
mov byte [rsp + 0xa5], al
mov rcx, qword [rsp + 0x150]
call sub.msys_2.0.dll_strlen
mov rdx, qword [rsp + 0x150]
mov rbx, rax
mov rax, qword [sym.vim.exe_NameBuff]
lea r8, [rbx + 1]
mov rcx, qword [rax]
call sub.msys_2.0.dll_memcpy
mov rax, qword [sym.vim.exe_NameBuff]
mov rsi, qword [rax]
mov rcx, rsi
call sub.msys_2.0.dll_strlen
mov r10d, 0x2a
mov rdx, qword [rsp + 0x80]
add rsi, rax
mov rax, qword [sym.vim.exe_NameBuff]
mov dword [rsi], 0x2f2a2a2f
mov word [rsi + 4], r10w
mov rcx, qword [rax]
call fcn.100673240
mov r8, qword [rsp + 0x78]
mov dword [rsp + 0x20], 0x22
mov ecx, 1
mov r9, qword [rsp + 0x88]
mov rdx, qword [sym.vim.exe_NameBuff]
call sym.vim.exe_gen_expand_wildcards
test eax, eax
je 0x1004b351c
mov ecx, dword [rsp + 0x9c]
test ecx, ecx
je 0x1004b3578
mov rax, qword [sym.vim.exe_NameBuff]
mov rdx, qword [rsp + 0x150]
lea rdi, [rsp + 0xb8]
mov rcx, qword [rax]
call sub.msys_2.0.dll_strcpy
mov rax, qword [sym.vim.exe_NameBuff]
mov rcx, qword [rax]
call sym.vim.exe_add_pathsep
mov rax, qword [sym.vim.exe_NameBuff]
mov rdx, rdi
mov rcx, qword [rax]
call fcn.100673240
mov rax, qword [sym.vim.exe_NameBuff]
lea rdx, [0x1006c1a45]
mov rcx, qword [rax]
call sub.msys_2.0.dll_fopen
mov qword [rsp + 0x58], rax
test rax, rax
je 0x1004b35c9
lea rax, [rsp + 0xe0]
mov r8d, 0x64
mov edx, 8
mov rcx, rax
mov qword [rsp + 0x38], rax
call sym.vim.exe_ga_init2
mov r8d, dword [rsp + 0x158]
test r8d, r8d
jne 0x1004b35a4
xor r8d, r8d
mov rdx, qword [rsp + 0x150]
mov r9d, 1
lea rcx, str._VIMRUNTIME_doc
call sym.vim.exe_fullpathcmp
cmp eax, 1
je 0x1004b35a4
mov rdi, qword [sym.vim.exe_got_int]
mov ecx, dword [rsp + 0x9c]
mov rdx, qword [rsp + 0xb0]
test ecx, ecx
jle 0x1004b36db
mov dword [rsp + 0x6c], ebx
mov qword [rsp + 0x40], 0
mov dword [rsp + 0x68], 0
mov dword [rsp + 0x4c], 2
mov eax, dword [rdi]
test eax, eax
jne 0x1004b32ee
mov rax, qword [rsp + 0x40]
mov rcx, qword [rdx + rax*8]
lea rbx, [rax*8]
lea rdx, [0x1006c1a67]
mov qword [rsp + 0x60], rbx
call sub.msys_2.0.dll_fopen
mov r12, rax
test rax, rax
je 0x100676bb0
mov rbx, qword [rsp + 0x40]
movsxd rax, dword [rsp + 0x6c]
mov esi, 1
mov rdx, qword [rsp + 0xb0]
mov rdx, qword [rdx + rbx*8]
mov rbx, qword [sym.vim.exe_IObuff]
lea rbp, [rdx + rax + 1]
nop dword [rax + rax]
mov rcx, qword [rbx]
mov r8, r12
mov edx, 0x401
call sym.vim.exe_vim_fgets
test eax, eax
jne 0x1004b32c4
mov eax, dword [rdi]
test eax, eax
jne 0x1004b32c4
test esi, esi
jne 0x1004b3243
mov rcx, qword [rbx]
mov edx, 0x2a
call sym.vim.exe_vim_strchr
mov r15, rax
test rax, rax
je 0x1004b3228
lea r13, str._s_t_s
nop word [rax + rax]
lea r14, [r15 + 1]
mov edx, 0x2a
mov rcx, r14
call sym.vim.exe_vim_strbyte
mov rsi, rax
test rax, rax
je 0x1004b3228
cmp r14, rax
jb 0x1004b3140
mov r15, rsi
jmp 0x1004b3110
mov rax, r14
jmp 0x1004b3156
cmp dl, 0x7c
je 0x1004b316b
add rax, 1
cmp rsi, rax
je 0x1004b3170
movzx edx, byte [rax]
cmp dl, 0x20
sete cl
cmp dl, 9
sete r8b
or cl, r8b
je 0x1004b3148
cmp rsi, rax
jne 0x1004b3132
cmp qword [rbx], r15
je 0x1004b3182
movzx eax, byte [r15 - 1]
cmp al, 0x20
je 0x1004b3182
cmp al, 9
jne 0x1004b3132
movzx edx, byte [rsi + 1]
lea rcx, str.__t_n_r
call sym.vim.exe_vim_strchr
test rax, rax
je 0x1004b3234
mov byte [rsi], 0
mov rcx, qword [rsp + 0x38]
mov edx, 1
call sym.vim.exe_ga_grow
test eax, eax
je 0x1004b3499
mov rcx, rbp
call sub.msys_2.0.dll_strlen
mov rdx, rsi
sub rdx, r14
lea rcx, [rdx + rax + 2]
call sym.vim.exe_alloc
mov rcx, rax
test rax, rax
je 0x1004b3499
movsxd r8, dword [rsp + 0xe0]
mov rdx, qword [rsp + 0xf0]
mov r9, rbp
mov qword [rdx + r8*8], rcx
mov rax, r8
mov rdx, r13
mov r8, r14
add eax, 1
mov dword [rsp + 0xe0], eax
call sub.msys_2.0.dll_sprintf
lea rcx, [rsi + 1]
mov edx, 0x2a
call sym.vim.exe_vim_strchr
mov r15, rax
test rax, rax
jne 0x1004b3110
nop word [rax + rax]
call sym.vim.exe_line_breakcheck
xor esi, esi
jmp 0x1004b30c0
cmp byte [rsi + 1], 0
jne 0x1004b3132
jmp 0x1004b319b
mov rdx, qword [rbx]
movzx eax, byte [rdx]
test al, al
je 0x1004b32b0
mov ecx, 2
jmp 0x1004b3265
movzx eax, byte [r13 + 1]
lea rdx, [r13 + 1]
test al, al
je 0x1004b328f
mov r13, rdx
test al, al
jns 0x1004b3258
mov rcx, rdx
call sym.vim.exe_utf_ptr2len
cmp eax, 1
je 0x1004b32b0
cdqe
mov ecx, esi
lea r13, [r13 + rax - 1]
movzx eax, byte [r13 + 1]
lea rdx, [r13 + 1]
test al, al
jne 0x1004b3265
cmp ecx, 2
je 0x1004b32b0
mov eax, dword [rsp + 0x4c]
cmp eax, 2
je 0x1004b32bb
cmp eax, esi
je 0x1004b30ea
jmp 0x100676c59
mov eax, dword [rsp + 0x4c]
xor esi, esi
cmp eax, 2
jne 0x1004b329d
mov dword [rsp + 0x4c], esi
jmp 0x1004b30ea
mov rcx, r12
call fcn.100672bf0
add qword [rsp + 0x40], 1
mov ecx, dword [rsp + 0x9c]
mov rax, qword [rsp + 0x40]
mov rdx, qword [rsp + 0xb0]
cmp ecx, eax
jg 0x1004b3059
call sym.vim.exe_FreeWild
mov eax, dword [rdi]
test eax, eax
jne 0x1004b3598
mov rcx, qword [rsp + 0xf0]
test rcx, rcx
je 0x1004b3316
mov edx, dword [rsp + 0xe0]
call sym.vim.exe_sort_strings
xor esi, esi
cmp dword [rsp + 0xe0], 1
mov ebp, 1
jle 0x1004b33d3
mov rax, qword [rsp + 0xf0]
mov rdx, rsi
add rsi, 8
mov rdx, qword [rax + rdx]
mov rbx, qword [rax + rsi]
movzx eax, byte [rbx]
cmp al, byte [rdx]
je 0x1004b335b
jmp 0x1004b33c3
add rdx, 1
movzx eax, byte [rbx]
cmp al, byte [rdx]
jne 0x1004b33c3
mov r12, rbx
add rbx, 1
cmp al, 9
jne 0x1004b3350
mov byte [r12], 0
mov rcx, qword [sym.vim.exe_e_duplicate_tag_str_in_file_str_str]
mov rax, qword [rsp + 0xf0]
mov r13, qword [rax + rsi]
call sub.msys_intl_8.dll_libintl_gettext
mov qword [rsp + 0x28], rbx
mov edx, 0x1000
mov r8, rax
mov rax, qword [rsp + 0x150]
mov r9, r13
mov qword [rsp + 0x20], rax
mov rax, qword [sym.vim.exe_NameBuff]
mov rcx, qword [rax]
call sym.vim.exe_vim_snprintf
mov rax, qword [sym.vim.exe_NameBuff]
mov rcx, qword [rax]
call sym.vim.exe_emsg
mov byte [r12], 9
add ebp, 1
cmp ebp, dword [rsp + 0xe0]
jl 0x1004b332b
cmp dword [rsp + 0x4c], 1
je 0x1004b368e
mov eax, dword [rsp + 0xe0]
test eax, eax
jle 0x1004b36b9
mov r14, qword [rsp + 0x58]
xor ebx, ebx
lea rbp, str.help_tags_t
lea rsi, str._s_t_
lea r12, [0x1006c1aa3]
jmp 0x1004b3429
mov rdx, r14
mov rcx, r13
add rbx, 1
call sub.msys_2.0.dll_fputs
mov eax, dword [rsp + 0xe0]
cmp eax, ebx
jle 0x1004b34d4
mov rax, qword [rsp + 0xf0]
mov r8d, 0xa
mov rdx, rbp
mov r13, qword [rax + rbx*8]
mov rcx, r13
call sub.msys_2.0.dll_strncmp
test eax, eax
je 0x1004b340b
mov r8, r13
mov rdx, rsi
mov rcx, r14
call sub.msys_2.0.dll_fprintf
movzx eax, byte [r13]
cmp al, 9
jne 0x1004b3482
jmp 0x1004b34ab
movzx ecx, byte [r13]
mov rdx, r14
add r13, 1
call sub.msys_2.0.dll_putc
movzx eax, byte [r13]
cmp al, 9
je 0x1004b34ab
cmp al, 0x5c
je 0x1004b348a
cmp al, 0x2f
jne 0x1004b3468
mov rdx, r14
mov ecx, 0x5c
call sub.msys_2.0.dll_putc
jmp 0x1004b3468
mov dword [rdi], 1
xor esi, esi
call sym.vim.exe_line_breakcheck
jmp 0x1004b30c0
mov r9, r14
mov r8d, 2
mov rcx, r12
add rbx, 1
mov edx, 1
call sub.msys_2.0.dll_fwrite
mov eax, dword [rsp + 0xe0]
cmp eax, ebx
jg 0x1004b3429
mov ecx, dword [rsp + 0x68]
test ecx, ecx
je 0x1004b34e2
mov dword [rdi], 0
xor ebx, ebx
test eax, eax
jle 0x1004b3506
mov rax, qword [rsp + 0xf0]
mov rcx, qword [rax + rbx*8]
add rbx, 1
call sym.vim.exe_vim_free
cmp dword [rsp + 0xe0], ebx
jg 0x1004b34e8
mov rcx, qword [rsp + 0x38]
call sym.vim.exe_ga_clear
mov rcx, qword [rsp + 0x58]
call fcn.100672bf0
jmp 0x1004b352d
mov rdi, qword [sym.vim.exe_got_int]
mov eax, dword [rdi]
test eax, eax
je 0x100676c9a
add qword [rsp + 0x50], 2
mov rax, qword [rsp + 0x50]
cmp dword [rsp + 0xc0], eax
jg 0x1004b2e5a
mov rcx, qword [rsp + 0x70]
call sym.vim.exe_ga_clear
mov rdx, qword [rsp + 0xa8]
mov ecx, dword [rsp + 0x98]
call sym.vim.exe_FreeWild
nop
add rsp, 0x108
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rdi, qword [sym.vim.exe_got_int]
mov eax, dword [rdi]
test eax, eax
je 0x1004b370f
mov rdx, qword [rsp + 0xb0]
call sym.vim.exe_FreeWild
jmp 0x1004b352d
mov eax, dword [rsp + 0xe0]
jmp 0x1004b34d4
mov rcx, qword [rsp + 0x38]
mov edx, 1
call sym.vim.exe_ga_grow
test eax, eax
jne 0x1004b35f3
mov rdi, qword [sym.vim.exe_got_int]
mov dword [rdi], 1
jmp 0x1004b3025
mov r9d, dword [rsp + 0x160]
test r9d, r9d
je 0x100676bde
mov rdx, qword [rsp + 0xb0]
mov ecx, dword [rsp + 0x9c]
call sym.vim.exe_FreeWild
jmp 0x1004b352d
mov rcx, rdi
call sub.msys_2.0.dll_strlen
lea ecx, [rax + 0x12]
call sym.vim.exe_alloc
mov rsi, rax
test rax, rax
je 0x1004b35b7
lea rdx, str.help_tags_t_s_t1_n
mov rcx, rax
mov r8, rdi
call sub.msys_2.0.dll_sprintf
movsxd rcx, dword [rsp + 0xe0]
mov rdx, qword [rsp + 0xf0]
mov rax, rcx
mov qword [rdx + rcx*8], rsi
add eax, 1
mov dword [rsp + 0xe0], eax
jmp 0x1004b301e
cmp al, 0x58
jne 0x1004b2d0e
lea edx, [r14 - 0x41]
lea eax, [r14 + 0x20]
cmp dl, 0x1a
lea edx, [r13 - 0x41]
cmovb r14d, eax
lea eax, [r13 + 0x20]
cmp dl, 0x1a
cmovb r13d, eax
jmp 0x1004b2d5f
mov byte [rsp + 0xbc], 0
mov dword [rsp + 0xa3], 0x7478742e
mov byte [rsp + 0xa7], 0
jmp 0x1004b2ebe
mov r9, qword [rsp + 0x58]
mov r8d, 0x1d
mov edx, 1
lea rcx, str.__TAG_FILE_ENCODING_tutf_8_t___n
call sub.msys_2.0.dll_fwrite
mov eax, dword [rsp + 0xe0]
test eax, eax
jg 0x1004b33ed
mov edx, dword [rsp + 0x68]
test edx, edx
je 0x1004b3506
jmp 0x1004b34dc
xor r12d, r12d
cmp r12d, ebx
jne 0x1004b2d0e
jmp 0x1004b2db1
call sym.vim.exe_FreeWild
mov eax, dword [rdi]
mov dword [rsp + 0x68], eax
test eax, eax
je 0x1004b36f6
mov eax, dword [rsp + 0xe0]
jmp 0x1004b34e2
mov dword [rsp + 0x4c], 2
jmp 0x1004b32fd
mov ebx, dword [rsp + 0xc0]
jmp 0x1004b2e1c
jmp 0x100676c2c
mov rax, qword [rsp + 0xb0]
mov rbx, qword [rsp + 0x40]
mov rcx, qword [sym.vim.exe_e_unable_to_open_str_for_reading]
mov r12, qword [rax + rbx*8]
call sub.msys_intl_8.dll_libintl_gettext
mov rcx, rax
mov rdx, r12
call sym.vim.exe_semsg
nop
jmp 0x1004b32cc
mov rax, qword [sym.vim.exe_NameBuff]
mov rcx, qword [sym.vim.exe_e_cannot_open_str_for_writing_1]
mov r12, qword [rax]
call sub.msys_intl_8.dll_libintl_gettext
mov rcx, rax
mov rdx, r12
call sym.vim.exe_semsg
nop
jmp 0x1004b35da
mov rax, qword [sym.vim.exe_NameBuff]
mov rcx, qword [sym.vim.exe_e_no_match_str_1]
mov r12, qword [rax]
call sub.msys_intl_8.dll_libintl_gettext
mov rcx, rax
mov rdx, r12
call sym.vim.exe_semsg
nop
jmp 0x1004b3564
mov rax, qword [sym.vim.exe_NameBuff]
mov rcx, qword [sym.vim.exe_e_no_match_str_1]
mov r12, qword [rax]
call sub.msys_intl_8.dll_libintl_gettext
mov rcx, rax
mov rdx, r12
call sym.vim.exe_semsg
mov ecx, dword [rsp + 0x9c]
jmp 0x1004b3589
mov rcx, qword [rsp + 0x60]
mov rax, qword [rsp + 0xb0]
mov r13, qword [rax + rcx]
mov rcx, qword [sym.vim.exe_e_mix_of_help_file_encodings_within_language_str]
call sub.msys_intl_8.dll_libintl_gettext
mov rdx, r13
mov rcx, rax
call sym.vim.exe_semsg
mov eax, dword [rdi]
mov dword [rdi], 1
test eax, eax
sete al
movzx eax, al
mov dword [rsp + 0x68], eax
jmp 0x1004b30ea
mov rax, qword [sym.vim.exe_NameBuff]
mov rcx, qword [sym.vim.exe_e_no_match_str_1]
mov r12, qword [rax]
call sub.msys_intl_8.dll_libintl_gettext
mov rcx, rax
mov rdx, r12
call sym.vim.exe_semsg
nop
jmp 0x1004b352d