Skip to content

Instantly share code, notes, and snippets.

@llinfeng
Created September 15, 2022 12:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save llinfeng/180ff97e00aedf87ce0c47a271656ba7 to your computer and use it in GitHub Desktop.
Save llinfeng/180ff97e00aedf87ce0c47a271656ba7 to your computer and use it in GitHub Desktop.
Profiling vimwiki link creation on a Linux machine
FUNCTION <SNR>167_update_hg_branch()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/branch.vim:148
Called 23 times
Total time: 0.002346
Self time: 0.002071
count total (s) self (s)
23 0.000465 0.000190 if airline#util#has_lawrencium()
let cmd='LC_ALL=C hg qtop'
let stl=lawrencium#statusline()
let file=expand('%:p')
if !empty(stl) && get(b:, 'airline_do_mq_check', 1)
if g:airline#init#vim_async
noa call airline#async#get_mq_async(cmd, file)
elseif has("nvim")
noa call airline#async#nvim_get_mq_async(cmd, file)
else
" remove \n at the end of the command
let output=system(cmd)[0:-2]
noa call airline#async#mq_output(output, file)
endif
endif
" do not do mq check anymore
let b:airline_do_mq_check = 0
if exists("b:mq") && !empty(b:mq)
if stl is# 'default'
" Shorten default a bit
let stl='def'
endif
let stl.=' ['.b:mq.']'
endif
let s:vcs_config['mercurial'].branch = stl
23 0.000027 else
23 0.000092 let s:vcs_config['mercurial'].branch = ''
23 0.000021 endif
FUNCTION <SNR>185_get_section()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/default.vim:20
Called 14 times
Total time: 0.001642
Self time: 0.001281
count total (s) self (s)
14 0.000101 if has_key(s:section_truncate_width, a:key)
8 0.000388 0.000149 if airline#util#winwidth(a:winnr) < s:section_truncate_width[a:key]
return ''
8 0.000013 endif
14 0.000020 endif
14 0.000066 let spc = g:airline_symbols.space
14 0.000131 if !exists('g:airline_section_{a:key}')
return ''
14 0.000024 endif
14 0.000402 0.000280 let text = airline#util#getwinvar(a:winnr, 'airline_section_'.a:key, g:airline_section_{a:key})
14 0.000210 let [prefix, suffix] = [get(a:000, 0, '%('.spc), get(a:000, 1, spc.'%)')]
14 0.000124 return empty(text) ? '' : prefix.text.suffix
FUNCTION <SNR>217_is_table()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/tbl.vim:59
Called 2 times
Total time: 0.001786
Self time: 0.000156
count total (s) self (s)
2 0.001783 0.000153 return s:is_separator(a:line) || (a:line !~# s:rxSep().s:rxSep() && a:line =~# '^\s*'.s:rxSep().'.\+'.s:rxSep().'\s*$')
FUNCTION airline#util#exec_funcrefs()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:95
Called 2 times
Total time: 0.005824
Self time: 0.000795
count total (s) self (s)
24 0.000075 for Fn in a:list
24 0.005532 0.000503 let code = call(Fn, a:000)
24 0.000076 if code != 0
2 0.000005 return code
22 0.000035 endif
22 0.000037 endfor
return 0
FUNCTION airline#extensions#unite#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/unite.vim:11
Called 2 times
Total time: 0.000095
Self time: 0.000095
count total (s) self (s)
2 0.000027 if &ft == 'unite'
call a:1.add_section('airline_a', ' Unite ')
call a:1.add_section('airline_b', ' %{get(unite#get_context(), "buffer_name", "")} ')
call a:1.add_section('airline_c', ' %{unite#get_status_string()} ')
call a:1.split()
call a:1.add_section('airline_y', ' %{get(unite#get_context(), "real_buffer_name", "")} ')
return 1
2 0.000002 endif
FUNCTION vimwiki#vars#get_wikilocal()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/vars.vim:949
Called 30 times
Total time: 0.001851
Self time: 0.000926
count total (s) self (s)
30 0.000078 if a:0
return g:vimwiki_wikilocal_vars[a:1][a:key]
30 0.000044 else
30 0.001554 0.000629 return g:vimwiki_wikilocal_vars[vimwiki#vars#get_bufferlocal('wiki_nr')][a:key]
endif
FUNCTION vimwiki#base#normalize_link_helper()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/base.vim:2171
Called 1 time
Total time: 0.000544
Self time: 0.000152
count total (s) self (s)
1 0.000025 let url = matchstr(a:str, a:rxUrl)
1 0.000086 0.000024 if vimwiki#vars#get_wikilocal('syntax') ==# 'markdown' && vimwiki#vars#get_global('markdown_link_ext')
" strip the extension if it exists so it doesn't get added multiple times
let url = substitute(url, '\'.vimwiki#vars#get_wikilocal('ext').'$', '', '')
1 0.000002 endif
1 0.000011 let descr = matchstr(a:str, a:rxDesc)
" Try to clean, do not work if bad link
1 0.000003 if descr ==# ''
1 0.000295 0.000019 let descr = s:clean_url(url)
1 0.000008 if descr ==# '' | return url | endif
1 0.000001 endif
1 0.000052 0.000022 let lnk = s:safesubstitute(a:template, '__LinkDescription__', descr, '')
1 0.000041 0.000017 let lnk = s:safesubstitute(lnk, '__LinkUrl__', url, '')
1 0.000003 return lnk
FUNCTION airline#check_mode()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline.vim:217
Called 23 times
Total time: 0.212087
Self time: 0.006074
count total (s) self (s)
23 0.000137 if !has_key(s:contexts, a:winnr)
return ''
23 0.000040 endif
23 0.000151 let context = s:contexts[a:winnr]
23 0.000139 if get(w:, 'airline_active', 1)
23 0.000135 let m = mode(1)
" Refer :help mode() to see the list of modes
" NB: 'let mode' here refers to the display colour _groups_,
" not the literal mode's code (i.e., m). E.g., Select modes
" v, S and ^V use 'visual' since they are of similar ilk.
" Some modes do not get recognised for status line purposes:
" no, nov, noV, no^V, !, cv, and ce.
" Mode name displayed is handled in init.vim (g:airline_mode_map).
"
23 0.000133 if m[0] ==# "i"
let mode = ['insert'] " Insert modes + submodes (i, ic, ix)
23 0.000109 elseif m[0] == "R"
let mode = ['replace'] " Replace modes + submodes (R, Rc, Rv, Rx) (NB: case sensitive as 'r' is a mode)
23 0.000345 elseif m[0] =~ '\v(v|V||s|S|)'
let mode = ['visual'] " Visual and Select modes (v, V, ^V, s, S, ^S))
23 0.000058 elseif m ==# "t"
let mode = ['terminal'] " Terminal mode (only has one mode (t))
23 0.000208 elseif m[0] =~ '\v(c|r|!)'
2 0.000012 let mode = ['commandline'] " c, cv, ce, r, rm, r? (NB: cv and ce stay showing as mode entered from)
21 0.000026 else
21 0.000077 let mode = ['normal'] " Normal mode + submodes (n, niI, niR, niV; plus operator pendings no, nov, noV, no^V)
23 0.000030 endif
23 0.000241 if exists("*VMInfos") && !empty(VMInfos())
" Vim plugin Multiple Cursors https://github.com/mg979/vim-visual-multi
let m = 'multi'
23 0.000028 endif
" Adjust to handle additional modes, which don't display correctly otherwise
23 0.000343 if index(['niI', 'niR', 'niV', 'ic', 'ix', 'Rc', 'Rv', 'Rx', 'multi'], m) == -1
23 0.000101 let m = m[0]
23 0.000030 endif
23 0.000194 let w:airline_current_mode = get(g:airline_mode_map, m, m)
else
let mode = ['inactive']
let w:airline_current_mode = get(g:airline_mode_map, '__')
23 0.000028 endif
23 0.000151 if g:airline_detect_modified && &modified
5 0.000028 call add(mode, 'modified')
23 0.000031 endif
23 0.000078 if g:airline_detect_paste && &paste
call add(mode, 'paste')
23 0.000030 endif
23 0.000179 if g:airline_detect_crypt && exists("+key") && !empty(&key)
call add(mode, 'crypt')
23 0.000025 endif
23 0.000084 if g:airline_detect_spell && &spell
23 0.000131 call add(mode, 'spell')
23 0.000029 endif
23 0.000081 if &readonly || ! &modifiable
call add(mode, 'readonly')
23 0.000023 endif
23 0.000162 let mode_string = join(mode)
23 0.000162 if get(w:, 'airline_lastmode', '') != mode_string
10 0.008265 0.000195 call airline#highlighter#highlight_modified_inactive(context.bufnr)
10 0.197323 0.000251 call airline#highlighter#highlight(mode, string(context.bufnr))
10 0.001000 0.000129 call airline#util#doautocmd('AirlineModeChanged')
10 0.000032 let w:airline_lastmode = mode_string
23 0.000023 endif
23 0.000039 return ''
FUNCTION airline#extensions#vimtex#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/vimtex.vim:44
Called 2 times
Total time: 0.000045
Self time: 0.000045
count total (s) self (s)
2 0.000013 if exists("b:vimtex")
let w:airline_section_x = get(w:, 'airline_section_x', g:airline_section_x)
let w:airline_section_x.=s:spc.g:airline_left_alt_sep.s:spc.'%{airline#extensions#vimtex#get_scope()}'
2 0.000004 endif
FUNCTION airline#util#try_focusgained()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:218
Called 2 times
Total time: 0.000052
Self time: 0.000052
count total (s) self (s)
" Ignore lasts for at most one second and is cleared on the first
" focusgained. We use ignore to prevent system() calls from triggering
" FocusGained (which occurs 100% on win32 and seem to sometimes occur under
" tmux).
2 0.000019 let dt = localtime() - s:focusgained_ignore_time
2 0.000010 let s:focusgained_ignore_time = 0
2 0.000007 return dt >= 1
FUNCTION airline#extensions#branch#update_untracked_config()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/branch.vim:193
Called 23 times
Total time: 0.000497
Self time: 0.000497
count total (s) self (s)
23 0.000126 if !has_key(s:vcs_config[a:vcs].untracked, a:file)
return
23 0.000147 elseif s:vcs_config[a:vcs].untracked[a:file] != b:buffer_vcs_config[a:vcs].untracked
let b:buffer_vcs_config[a:vcs].untracked = s:vcs_config[a:vcs].untracked[a:file]
unlet! b:airline_head
23 0.000023 endif
FUNCTION airline#themes#get_highlight()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/themes.vim:35
Called 244 times
Total time: 0.050189
Self time: 0.002675
count total (s) self (s)
244 0.050096 0.002582 return call('airline#highlighter#get_highlight', [a:group] + a:000)
FUNCTION airline#extensions#tabline#get_buffer_name()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline.vim:228
Called 12 times
Total time: 0.003262
Self time: 0.000665
count total (s) self (s)
12 0.000360 0.000225 let buffers = a:0 ? a:1 : airline#extensions#tabline#buflist#list()
12 0.000096 let formatter = get(g:, 'airline#extensions#tabline#formatter', 'default')
12 0.002786 0.000324 return airline#extensions#tabline#formatters#{formatter}#format(a:nr, buffers)
FUNCTION <SNR>166_CheckDefined()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:108
Called 348 times
Total time: 0.011101
Self time: 0.011101
count total (s) self (s)
" Checks, whether the definition of the colors is valid and is not empty or NONE
" e.g. if the colors would expand to this:
" hi airline_c ctermfg=NONE ctermbg=NONE
" that means to clear that highlighting group, therefore, fallback to Normal
" highlighting group for the cterm values
" This only works, if the Normal highlighting group is actually defined, so
" return early, if it has been cleared
348 0.001563 if !exists("g:airline#highlighter#normal_fg_hi")
let g:airline#highlighter#normal_fg_hi = synIDattr(synIDtrans(hlID('Normal')), 'fg', 'cterm')
348 0.000297 endif
348 0.001588 if empty(g:airline#highlighter#normal_fg_hi) || g:airline#highlighter#normal_fg_hi < 0
return a:colors
348 0.000272 endif
348 0.001009 for val in a:colors
348 0.001297 if !empty(val) && val !=# 'NONE'
348 0.000593 return a:colors
endif
endfor
" this adds the bold attribute to the term argument of the :hi command,
" but at least this makes sure, the group will be defined
let fg = g:airline#highlighter#normal_fg_hi
let bg = synIDattr(synIDtrans(hlID('Normal')), 'bg', 'cterm')
if empty(bg) || bg < 0
" in case there is no background color defined for Normal
let bg = a:colors[3]
endif
return a:colors[0:1] + [fg, bg] + [a:colors[4]]
FUNCTION <SNR>166_group_not_done()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:32
Called 240 times
Total time: 0.002679
Self time: 0.002679
count total (s) self (s)
240 0.001078 if index(a:list, a:name) == -1
216 0.000883 call add(a:list, a:name)
216 0.000361 return 1
24 0.000017 else
24 0.000039 if &vbs
echomsg printf("airline: group: %s already done, skipping", a:name)
24 0.000011 endif
24 0.000018 return 0
endif
FUNCTION airline#util#has_custom_scm()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:174
Called 23 times
Total time: 0.000153
Self time: 0.000153
count total (s) self (s)
23 0.000138 return !empty(get(g:, 'airline#extensions#branch#custom_head', ''))
FUNCTION <SNR>160_invoke_funcrefs()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline.vim:195
Called 2 times
Total time: 0.030236
Self time: 0.000205
count total (s) self (s)
2 0.000147 0.000031 let builder = airline#builder#new(a:context)
2 0.005889 0.000065 let err = airline#util#exec_funcrefs(a:funcrefs + s:core_funcrefs, builder, a:context)
2 0.000006 if err == 1
2 0.024121 0.000030 let a:context.line = builder.build()
2 0.000017 let s:contexts[a:context.winnr] = a:context
2 0.000013 let option = get(g:, 'airline_statusline_ontop', 0) ? '&tabline' : '&statusline'
2 0.000033 call setwinvar(a:context.winnr, option, '%!airline#statusline('.a:context.winnr.')')
2 0.000002 endif
FUNCTION airline#extensions#tabline#buffers#get()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:51
Called 8 times
Total time: 0.055221
Self time: 0.002117
count total (s) self (s)
8 0.000019 try
8 0.006584 0.000130 call <sid>map_keys()
catch
" no-op
8 0.000020 endtry
8 0.000073 let cur = bufnr('%')
8 0.000072 if cur == s:current_bufnr && &columns == s:column_width
8 0.000112 if !g:airline_detect_modified || getbufvar(cur, '&modified') == s:current_modified
4 0.000019 return s:current_tabline
4 0.000006 endif
4 0.000006 endif
4 0.000896 0.000076 let b = airline#extensions#tabline#new_builder()
4 0.000036 let tab_bufs = tabpagebuflist(tabpagenr())
4 0.000017 let show_buf_label_first = 0
4 0.000032 if get(g:, 'airline#extensions#tabline#buf_label_first', 0)
let show_buf_label_first = 1
4 0.000008 endif
4 0.000012 if show_buf_label_first
call airline#extensions#tabline#add_label(b, 'buffers', 0)
4 0.000007 endif
4 0.000031 let b.tab_bufs = tabpagebuflist(tabpagenr())
4 0.000016 let b.overflow_group = 'airline_tabhid'
4 0.000156 0.000101 let b.buffers = airline#extensions#tabline#buflist#list()
4 0.000028 if get(g:, 'airline#extensions#tabline#current_first', 0)
if index(b.buffers, cur) > -1
call remove(b.buffers, index(b.buffers, cur))
endif
let b.buffers = [cur] + b.buffers
4 0.000006 endif
4 0.000027 function! b.get_group(i) dict
let bufnum = get(self.buffers, a:i, -1)
if bufnum == -1
return ''
endif
let group = airline#extensions#tabline#group_of_bufnr(self.tab_bufs, bufnum)
if bufnum == bufnr('%')
let s:current_modified = (group == 'airline_tabmod') ? 1 : 0
endif
return group
endfunction
4 0.000057 if has("tablineat")
function! b.get_pretitle(i) dict
let bufnum = get(self.buffers, a:i, -1)
return '%'.bufnum.'@airline#extensions#tabline#buffers#clickbuf@'
endfunction
function! b.get_posttitle(i) dict
return '%X'
endfunction
4 0.000007 endif
4 0.000013 function! b.get_title(i) dict
let bufnum = get(self.buffers, a:i, -1)
let group = self.get_group(a:i)
let pgroup = self.get_group(a:i - 1)
" always add a space when powerline_fonts are used
" or for the very first item
if get(g:, 'airline_powerline_fonts', 0) || a:i == 0
let space = s:spc
else
let space= (pgroup == group ? s:spc : '')
endif
if get(g:, 'airline#extensions#tabline#buffer_idx_mode', 0)
if len(s:number_map) > 0
return space. s:get_number(a:i) . '%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)' . s:spc
else
return '['.(a:i+1).s:spc.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.']'
endif
else
return space.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.s:spc
endif
endfunction
4 0.000058 let current_buffer = max([index(b.buffers, cur), 0])
4 0.000042 let last_buffer = len(b.buffers) - 1
4 0.000245 0.000068 call b.insert_titles(current_buffer, 0, last_buffer)
4 0.000088 0.000041 call b.add_section('airline_tabfill', '')
4 0.000073 0.000030 call b.split()
4 0.000066 0.000033 call b.add_section('airline_tabfill', '')
4 0.000015 if !show_buf_label_first
4 0.000172 0.000075 call airline#extensions#tabline#add_label(b, 'buffers', 1)
4 0.000006 endif
4 0.000297 0.000118 call airline#extensions#tabline#add_tab_label(b)
4 0.000026 let s:current_bufnr = cur
4 0.000017 let s:column_width = &columns
4 0.045248 0.000049 let s:current_tabline = b.build()
4 0.000027 let s:current_visible_buffers = copy(b.buffers)
" Do not remove from s:current_visible_buffers, this breaks s:select_tab()
"if b._right_title <= last_buffer
" call remove(s:current_visible_buffers, b._right_title, last_buffer)
"endif
"if b._left_title > 0
" call remove(s:current_visible_buffers, 0, b._left_title)
"endif
4 0.000010 return s:current_tabline
FUNCTION airline#extensions#branch#head()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/branch.vim:249
Called 23 times
Total time: 0.018099
Self time: 0.004856
count total (s) self (s)
23 0.000125 if !exists('b:buffer_vcs_config')
call s:init_buffer()
23 0.000023 endif
23 0.009499 0.000275 call s:update_branch()
23 0.003810 0.000281 call s:update_untracked()
23 0.000148 if exists('b:airline_head') && !empty(b:airline_head)
return b:airline_head
23 0.000020 endif
23 0.000054 let b:airline_head = ''
23 0.000150 let vcs_priority = get(g:, "airline#extensions#branch#vcs_priority", ["git", "mercurial"])
23 0.000047 let heads = []
69 0.000133 for vcs in vcs_priority
46 0.000183 if !empty(b:buffer_vcs_config[vcs].branch)
let heads += [vcs]
46 0.000044 endif
69 0.000065 endfor
23 0.000049 for vcs in heads
if !empty(b:airline_head)
let b:airline_head .= ' | '
endif
if len(heads) > 1
let b:airline_head .= s:vcs_config[vcs].exe .':'
endif
let b:airline_head .= s:format_name({s:vcs_config[vcs].display_branch}())
let additional = b:buffer_vcs_config[vcs].untracked
if empty(additional) && has_key(b:buffer_vcs_config[vcs], 'dirty') && b:buffer_vcs_config[vcs].dirty
let additional = g:airline_symbols['dirty']
endif
let b:airline_head .= additional
23 0.000035 endfor
23 0.000063 if empty(heads)
23 0.000588 0.000251 if airline#util#has_vcscommand()
noa call VCSCommandEnableBufferSetup()
if exists('b:VCSCommandBufferInfo')
let b:airline_head = s:format_name(get(b:VCSCommandBufferInfo, 0, ''))
endif
23 0.000021 endif
23 0.000022 endif
23 0.000061 if empty(heads)
23 0.000367 0.000214 if airline#util#has_custom_scm()
try
let Fn = function(g:airline#extensions#branch#custom_head)
let b:airline_head = Fn()
endtry
23 0.000025 endif
23 0.000023 endif
23 0.000117 if exists("g:airline#extensions#branch#displayed_head_limit")
let w:displayed_head_limit = g:airline#extensions#branch#displayed_head_limit
if strwidth(b:airline_head) > w:displayed_head_limit - 1
let b:airline_head = airline#util#strcharpart(b:airline_head, 0, w:displayed_head_limit - 1) . (&encoding ==? 'utf-8' ? '…' : '.')
endif
23 0.000019 endif
23 0.000053 return b:airline_head
FUNCTION airline#util#has_fugitive()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:145
Called 23 times
Total time: 0.000256
Self time: 0.000256
count total (s) self (s)
23 0.000102 if !exists("s:has_fugitive")
let s:has_fugitive = exists('*FugitiveHead')
23 0.000017 endif
23 0.000049 return s:has_fugitive
FUNCTION <SNR>217_rxSep()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/tbl.vim:21
Called 12 times
Total time: 0.001533
Self time: 0.000191
count total (s) self (s)
12 0.001525 0.000183 return vimwiki#vars#get_syntaxlocal('rxTableSep')
FUNCTION fugitive#DidChange()
Defined: ~/vimfiles/plugged/vim-fugitive/autoload/fugitive.vim:4288
Called 2 times
Total time: 0.000232
Self time: 0.000152
count total (s) self (s)
2 0.000092 0.000040 call s:ExpireStatus(a:0 ? a:1 : -1)
2 0.000015 if a:0 > 1 ? a:2 : (!a:0 || a:1 isnot# 0)
let t = reltime()
let t:fugitive_reload_status = t
for tabnr in range(1, tabpagenr('$'))
call settabvar(tabnr, 'fugitive_reload_status', t)
endfor
call s:ReloadTabStatus()
2 0.000004 else
2 0.000056 0.000028 call s:ReloadWinStatus()
2 0.000004 return ''
endif
exe s:DoAutocmdChanged(a:0 ? a:1 : -1)
return ''
FUNCTION airline#extensions#netrw#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/netrw.vim:11
Called 2 times
Total time: 0.000110
Self time: 0.000110
count total (s) self (s)
2 0.000023 if &ft == 'netrw'
let spc = g:airline_symbols.space
call a:1.add_section('airline_a', spc.'netrw'.spc)
if exists('*airline#extensions#branch#get_head')
call a:1.add_section('airline_b', spc.'%{airline#extensions#branch#get_head()}'.spc)
endif
call a:1.add_section('airline_c', spc.'%f'.spc)
call a:1.split()
call a:1.add_section('airline_y', spc.'%{airline#extensions#netrw#sortstring()}'.spc)
return 1
2 0.000003 endif
FUNCTION airline#update_tabline()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline.vim:291
Called 25 times
Total time: 0.000438
Self time: 0.000438
count total (s) self (s)
25 0.000250 if get(g:, 'airline_statusline_ontop', 0)
call airline#extensions#tabline#redraw()
25 0.000033 endif
FUNCTION airline#extensions#term#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/term.vim:14
Called 2 times
Total time: 0.000111
Self time: 0.000111
count total (s) self (s)
2 0.000028 if &buftype ==? 'terminal' || bufname(a:2.bufnr)[0] ==? '!'
call a:1.add_section_spaced('airline_a', s:section_a)
call a:1.add_section_spaced('airline_b', s:neoterm_id(a:2.bufnr))
call a:1.add_section('airline_term', s:spc.s:termname(a:2.bufnr))
call a:1.split()
call a:1.add_section('airline_y', '')
call a:1.add_section_spaced('airline_z', s:section_z)
return 1
2 0.000004 endif
FUNCTION <SNR>185_add_section()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/default.vim:47
Called 12 times
Total time: 0.002497
Self time: 0.000923
count total (s) self (s)
12 0.000148 let condition = (a:key is# "warning" || a:key is# "error") && (v:version == 704 && !has("patch1511"))
" i have no idea why the warning section needs special treatment, but it's
" needed to prevent separators from showing up
12 0.000148 if ((a:key == 'error' || a:key == 'warning') && empty(s:get_section(a:context.winnr, a:key)))
return
12 0.000019 endif
12 0.000029 if condition
call a:builder.add_raw('%(')
12 0.000018 endif
12 0.001887 0.000313 call a:builder.add_section('airline_'.a:key, s:get_section(a:context.winnr, a:key))
12 0.000034 if condition
call a:builder.add_raw('%)')
12 0.000021 endif
FUNCTION <SNR>90_on_focus_gained()
Defined: ~/vimfiles/plugged/vim-airline/plugin/airline.vim:77
Called 2 times
Total time: 0.032019
Self time: 0.000105
count total (s) self (s)
2 0.000019 if &eventignore =~? 'focusgained'
return
2 0.000004 endif
2 0.000080 0.000028 if airline#util#try_focusgained()
2 0.031904 0.000042 unlet! w:airline_lastmode | :call <sid>airline_refresh(1)
2 0.000002 endif
FUNCTION <SNR>211_evaluate_tabline()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/builder.vim:209
Called 20 times
Total time: 0.003245
Self time: 0.002138
count total (s) self (s)
20 0.000088 let tabline = a:tabline
20 0.001589 0.000482 let tabline = substitute(tabline, '%{\([^}]\+\)}', '\=eval(submatch(1))', 'g')
20 0.000299 let tabline = substitute(tabline, '%#[^#]\+#', '', 'g')
20 0.000240 let tabline = substitute(tabline, '%(\([^)]\+\)%)', '\1', 'g')
20 0.000233 let tabline = substitute(tabline, '%\d\+[TX]', '', 'g')
20 0.000174 let tabline = substitute(tabline, '%=', '', 'g')
20 0.000185 let tabline = substitute(tabline, '%\d*\*', '', 'g')
20 0.000198 if has('tablineat')
let tabline = substitute(tabline, '%@[^@]\+@', '', 'g')
20 0.000032 endif
20 0.000055 return tabline
FUNCTION <SNR>175_map_keys()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:195
Called 8 times
Total time: 0.006454
Self time: 0.006454
count total (s) self (s)
8 0.000077 let bidx_mode = get(g:, 'airline#extensions#tabline#buffer_idx_mode', 1)
8 0.000030 if bidx_mode > 0
8 0.000025 if bidx_mode == 1
88 0.000273 for i in range(1, 10)
80 0.004848 exe printf('noremap <silent> <Plug>AirlineSelectTab%d :call <SID>select_tab(%d)<CR>', i%10, i-1)
88 0.000149 endfor
else
let start_idx = bidx_mode == 2 ? 11 : 1
for i in range(start_idx, 99)
exe printf('noremap <silent> <Plug>AirlineSelectTab%02d :call <SID>select_tab(%d)<CR>', i, i-start_idx)
endfor
8 0.000014 endif
8 0.000364 noremap <silent> <Plug>AirlineSelectPrevTab :<C-u>call <SID>jump_to_tab(-v:count1)<CR>
8 0.000335 noremap <silent> <Plug>AirlineSelectNextTab :<C-u>call <SID>jump_to_tab(v:count1)<CR>
" Enable this for debugging
" com! AirlineBufferList :echo map(copy(s:current_visible_buffers), {i,k -> k.": ".bufname(k)})
8 0.000015 endif
FUNCTION <SNR>90_airline_refresh()
Defined: ~/vimfiles/plugged/vim-airline/plugin/airline.vim:224
Called 2 times
Total time: 0.031862
Self time: 0.000285
count total (s) self (s)
" a:1, fast refresh, do not reload the theme
2 0.000023 let fast=!empty(get(a:000, 0, 0))
2 0.000018 if !exists("#airline")
" disabled
return
2 0.000003 endif
2 0.000321 0.000047 call airline#util#doautocmd('AirlineBeforeRefresh')
2 0.000188 0.000032 call airline#highlighter#reset_hlcache()
2 0.000006 if !fast
call airline#load_theme()
2 0.000003 endif
2 0.031222 0.000095 call airline#update_statusline()
2 0.000052 0.000032 call airline#update_tabline()
FUNCTION airline#extensions#tabline#buflist#list()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buflist.vim:39
Called 16 times
Total time: 0.000190
Self time: 0.000190
count total (s) self (s)
16 0.000113 if exists('s:current_buffer_list')
16 0.000053 return s:current_buffer_list
endif
let exclude_buffers = get(g:, 'airline#extensions#tabline#exclude_buffers', [])
let exclude_paths = get(g:, 'airline#extensions#tabline#excludes', [])
let exclude_preview = get(g:, 'airline#extensions#tabline#exclude_preview', 1)
let list = (exists('g:did_bufmru') && g:did_bufmru) ? BufMRUList() : range(1, bufnr("$"))
let buffers = []
" If this is too slow, we can switch to a different algorithm.
" Basically branch 535 already does it, but since it relies on
" BufAdd autocommand, I'd like to avoid this if possible.
for nr in list
if buflisted(nr)
" Do not add to the bufferlist, if either
" 1) bufnr is exclude_buffers list
" 2) buffername matches one of exclude_paths patterns
" 3) buffer is a quickfix buffer
" 4) when excluding preview windows:
" 'bufhidden' == wipe
" 'buftype' == nofile
" 5) ignore buffers matching airline#extensions#tabline#ignore_bufadd_pat
" check buffer numbers first
if index(exclude_buffers, nr) >= 0
continue
" check paths second
elseif !empty(exclude_paths) && s:ExcludePaths(nr, exclude_paths)
continue
" ignore buffers matching airline#extensions#tabline#ignore_bufadd_pat
elseif airline#util#ignore_buf(bufname(nr))
continue
" check other types last
elseif s:ExcludeOther(nr, exclude_preview)
continue
endif
call add(buffers, nr)
endif
endfor
let s:current_buffer_list = buffers
return buffers
FUNCTION 17()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:8
Called 6 times
Total time: 0.000066
Self time: 0.000066
count total (s) self (s)
6 0.000059 call add(self._sections, ['|', a:0 ? a:1 : '%='])
FUNCTION 19()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:17
Called 20 times
Total time: 0.000195
Self time: 0.000195
count total (s) self (s)
20 0.000185 call add(self._sections, [a:group, a:contents])
FUNCTION vimwiki#tbl#format()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/tbl.vim:673
Called 1 time
Total time: 0.000916
Self time: 0.000042
count total (s) self (s)
1 0.000046 0.000011 if !vimwiki#u#ft_is_vw()
return
1 0.000001 endif
1 0.000008 let line = getline(a:lnum)
1 0.000853 0.000014 if !s:is_table(line)
1 0.000002 return
endif
let depth = a:0 == 1 ? a:1 : 0
if a:0 == 2
let col1 = a:1
let col2 = a:2
else
let col1 = 0
let col2 = 0
endif
let indent = s:get_indent(a:lnum, depth)
if &expandtab
let indentstring = repeat(' ', indent)
else
execute "let indentstring = repeat('\<TAB>', indent / &tabstop) . repeat(' ', indent % &tabstop)"
endif
" getting N = depth last rows is enough for having been formatted tables
for [lnum, row] in s:get_aligned_rows(a:lnum, col1, col2, depth)
let row = indentstring.row
if getline(lnum) != row
call setline(lnum, row)
endif
endfor
let &textwidth = s:textwidth
FUNCTION airline#highlighter#add_separator()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:184
Called 22 times
Total time: 0.030979
Self time: 0.000683
count total (s) self (s)
22 0.000251 let s:separators[a:from.a:to] = [a:from, a:to, a:inverse]
22 0.030715 0.000419 call <sid>exec_separator({}, a:from, a:to, a:inverse, '')
FUNCTION airline#extensions#po#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/po.vim:64
Called 2 times
Total time: 0.000053
Self time: 0.000053
count total (s) self (s)
2 0.000023 if &ft ==# 'po'
call airline#extensions#prepend_to_section('z', '%{airline#extensions#po#stats()}')
" Also reset the cache variable, if a window has been split, e.g. the winwidth changed
autocmd airline BufWritePost * call s:autocmd_handler()
autocmd airline WinEnter * call airline#extensions#po#on_winenter()
2 0.000004 endif
FUNCTION 24()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:62
Called 10 times
Total time: 0.056428
Self time: 0.009341
count total (s) self (s)
10 0.000036 let side = 1
10 0.000030 let line = ''
10 0.000028 let i = 0
10 0.000059 let length = len(self._sections)
10 0.000029 let split = 0
10 0.000032 let is_empty = 0
10 0.000036 let prev_group = ''
52 0.000169 while i < length
42 0.000253 let section = self._sections[i]
42 0.000192 let group = section[0]
42 0.000182 let contents = section[1]
42 0.000135 let pgroup = prev_group
42 0.001942 0.000704 let prev_group = airline#builder#get_prev_group(self._sections, i)
42 0.000249 if group ==# 'airline_c' && &buftype ==# 'terminal' && self._context.active
let group = 'airline_term'
42 0.000312 elseif group ==# 'airline_c' && !self._context.active && has_key(self._context, 'bufnr')
let group = 'airline_c'. self._context.bufnr
42 0.000289 elseif prev_group ==# 'airline_c' && !self._context.active && has_key(self._context, 'bufnr')
let prev_group = 'airline_c'. self._context.bufnr
42 0.000057 endif
42 0.000088 if is_empty
let prev_group = pgroup
42 0.000046 endif
42 0.001705 0.000677 let is_empty = s:section_is_empty(self, contents)
42 0.000083 if is_empty
" need to fix highlighting groups, since we
" have skipped a section, we actually need
" the previous previous group and so the
" seperator goes from the previous previous group
" to the current group
let pgroup = group
42 0.000052 endif
42 0.000119 if group == ''
let line .= contents
42 0.000112 elseif group == '|'
10 0.000024 let side = 0
10 0.000039 let line .= contents
10 0.000024 let split = 1
32 0.000044 else
32 0.000089 if prev_group == ''
10 0.000073 let line .= '%#'.group.'#'
22 0.000042 elseif split
10 0.000025 if !is_empty
10 0.015514 0.000215 let line .= s:get_transitioned_seperator(self, prev_group, group, side)
10 0.000013 endif
10 0.000026 let split = 0
12 0.000016 else
12 0.000023 if !is_empty
12 0.027231 0.000207 let line .= s:get_seperator(self, prev_group, group, side)
12 0.000016 endif
32 0.000053 endif
32 0.003153 0.000655 let line .= is_empty ? '' : s:get_accented_line(self, group, contents)
42 0.000056 endif
42 0.000141 let i = i + 1
52 0.000106 endwhile
10 0.000032 if !self._context.active
"let line = substitute(line, '%#airline_c#', '%#airline_c'.self._context.bufnr.'#', '')
let line = substitute(line, '%#.\{-}\ze#', '\0_inactive', 'g')
10 0.000012 endif
10 0.000021 return line
FUNCTION <SNR>69_GetLastHeartbeat()
Defined: ~/vimfiles/plugged/vim-wakatime/plugin/wakatime.vim:638
Called 5 times
Total time: 0.000407
Self time: 0.000407
count total (s) self (s)
5 0.000075 if !s:last_heartbeat.last_activity_at || localtime() - s:last_heartbeat.last_activity_at > s:local_cache_expire
1 0.000036 if !filereadable(s:shared_state_file)
return {'last_activity_at': 0, 'last_heartbeat_at': 0, 'file': ''}
1 0.000003 endif
1 0.000053 let last = readfile(s:shared_state_file, '', 3)
1 0.000008 if len(last) == 3
1 0.000014 let s:last_heartbeat.last_heartbeat_at = last[1]
1 0.000006 let s:last_heartbeat.file = last[2]
1 0.000002 endif
5 0.000008 endif
5 0.000019 return s:last_heartbeat
FUNCTION airline#util#winwidth()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:19
Called 8 times
Total time: 0.000239
Self time: 0.000239
count total (s) self (s)
8 0.000059 let nr = get(a:000, 0, 0)
" When statusline is on top, or using global statusline for Neovim
" always return the number of columns
8 0.000066 if get(g:, 'airline_statusline_ontop', 0) || &laststatus > 2
return &columns
8 0.000014 else
8 0.000041 return winwidth(nr)
endif
FUNCTION <SNR>183_section_is_empty()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:182
Called 42 times
Total time: 0.001028
Self time: 0.001028
count total (s) self (s)
42 0.000139 let start=1
" do not check for inactive windows or the tabline
42 0.000163 if a:self._context.active == 0
return 0
42 0.000256 elseif get(a:self._context, 'tabline', 0)
28 0.000070 return 0
14 0.000019 endif
" only check, if airline#skip_empty_sections == 1
14 0.000076 if get(g:, 'airline_skip_empty_sections', 0) == 0
14 0.000028 return 0
endif
" only check, if airline#skip_empty_sections == 1
if get(w:, 'airline_skip_empty_sections', -1) == 0
return 0
endif
if empty(a:content)
return 1
endif
let stripped = substitute(a:content, '\(%{.*}\|%#__accent_[^#]*#\|%#__restore__#\|%( \| %)\)', '', 'g')
if !empty(stripped)
return 0 " There is content in the statusline
endif
let exprlist = []
call substitute(a:content, '%{\([^}]*\)}', '\=add(exprlist, submatch(1))', 'g')
for expr in exprlist
try
" catch all exceptions, just in case
if !empty(eval(expr))
return 0
endif
catch
return 0
endtry
endfor
return 1
FUNCTION airline#util#doautocmd()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:178
Called 12 times
Total time: 0.001145
Self time: 0.000320
count total (s) self (s)
12 0.000073 if !exists('#airline') && a:event !=? 'AirlineToggledOff'
" airline disabled
return
12 0.000012 endif
12 0.001026 0.000201 exe printf("silent doautocmd %s User %s", s:nomodeline, a:event)
FUNCTION airline#util#has_lawrencium()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:160
Called 23 times
Total time: 0.000275
Self time: 0.000275
count total (s) self (s)
23 0.000115 if !exists("s:has_lawrencium")
let s:has_lawrencium = exists('*lawrencium#statusline')
23 0.000023 endif
23 0.000049 return s:has_lawrencium
FUNCTION 45()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/builder.vim:41
Called 4 times
Total time: 0.003458
Self time: 0.000447
count total (s) self (s)
4 0.001180 0.000041 let title = self.get_title(a:index)
4 0.001910 0.000086 let title_size = s:tabline_evaluated_length(title) + a:sep_size
4 0.000022 if a:force || self._remaining_space >= title_size
4 0.000013 let pos = a:pos
4 0.000022 if has_key(self, "get_pretitle")
call self.insert_raw(self.get_pretitle(a:index), pos)
let self._right_position += 1
let pos += 1
4 0.000006 endif
4 0.000101 0.000053 call self.insert_section(a:group, title, pos)
4 0.000018 let self._right_position += 1
4 0.000013 let pos += 1
4 0.000019 if has_key(self, "get_posttitle")
call self.insert_raw(self.get_posttitle(a:index), pos)
let self._right_position += 1
let pos += 1
4 0.000005 endif
4 0.000018 let self._remaining_space -= title_size
4 0.000009 return 1
endif
return 0
FUNCTION 46()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/builder.vim:96
Called 4 times
Total time: 0.045199
Self time: 0.002336
count total (s) self (s)
4 0.000038 if has_key(self, '_left_position') && self._first_title <= self._last_title
4 0.013239 0.000124 let self._remaining_space = &columns - s:tabline_evaluated_length(self._build())
4 0.000039 let center_active = get(g:, 'airline#extensions#tabline#center_active', 0)
4 0.000582 0.000109 let sep_size = s:tabline_evaluated_length(self._context.left_sep)
4 0.000515 0.000073 let alt_sep_size = s:tabline_evaluated_length(self._context.left_alt_sep)
4 0.000267 0.000078 let outer_left_group = airline#builder#get_prev_group(self._sections, self._left_position)
4 0.000338 0.000095 let outer_right_group = airline#builder#get_next_group(self._sections, self._right_position)
4 0.000050 let overflow_marker = get(g:, 'airline#extensions#tabline#overflow_marker', g:airline_symbols.ellipsis)
4 0.000534 0.000073 let overflow_marker_size = s:tabline_evaluated_length(overflow_marker)
" Allow space for the markers before we begin filling in titles.
4 0.000018 if self._left_title > self._first_title
let self._remaining_space -= overflow_marker_size + s:get_separator_change(self.overflow_group, "", outer_left_group, sep_size, alt_sep_size)
4 0.000007 endif
4 0.000014 if self._left_title < self._last_title
let self._remaining_space -= overflow_marker_size + s:get_separator_change(self.overflow_group, "", outer_right_group, sep_size, alt_sep_size)
4 0.000005 endif
" Add the current title
4 0.000570 0.000048 let group = self.get_group(self._left_title)
4 0.000014 if self._left_title == self._first_title
4 0.000373 0.000081 let sep_change = s:get_separator_change(group, "", outer_left_group, sep_size, alt_sep_size)
else
let sep_change = s:get_separator_change(group, "", self.overflow_group, sep_size, alt_sep_size)
4 0.000006 endif
4 0.000014 if self._left_title == self._last_title
4 0.003751 0.000072 let sep_change += s:get_separator_change(group, "", outer_right_group, sep_size, alt_sep_size)
else
let sep_change += s:get_separator_change(group, "", self.overflow_group, sep_size, alt_sep_size)
4 0.000006 endif
4 0.000014 let left_group = group
4 0.000014 let right_group = group
4 0.003529 0.000071 let self._left_title -= self.try_insert_title(self._left_title, group, self._left_position, sep_change, 1)
4 0.000025 if get(g:, 'airline#extensions#tabline#current_first', 0)
" always have current title first
let self._left_position += 1
4 0.000005 endif
4 0.000034 if !center_active && self._right_title <= self._last_title
" Add the title to the right
let group = self.get_group(self._right_title)
if self._right_title == self._last_title
let sep_change = s:get_separator_change_with_end(group, right_group, outer_right_group, self.overflow_group, sep_size, alt_sep_size) - overflow_marker_size
else
let sep_change = s:get_separator_change(group, right_group, self.overflow_group, sep_size, alt_sep_size)
endif
let right_group = group
let self._right_title += self.try_insert_title(self._right_title, group, self._right_position, sep_change, 1)
4 0.000006 endif
4 0.000021 while self._remaining_space > 0
4 0.000016 let done = 0
4 0.000016 if self._left_title >= self._first_title
" Insert next title to the left
let group = self.get_group(self._left_title)
if self._left_title == self._first_title
let sep_change = s:get_separator_change_with_end(group, left_group, outer_left_group, self.overflow_group, sep_size, alt_sep_size) - overflow_marker_size
else
let sep_change = s:get_separator_change(group, left_group, self.overflow_group, sep_size, alt_sep_size)
endif
let left_group = group
let done = self.try_insert_title(self._left_title, group, self._left_position, sep_change, 0)
let self._left_title -= done
4 0.000005 endif
" If center_active is set, this |if| operates as an independent |if|,
" otherwise as an |elif|.
4 0.000025 if self._right_title <= self._last_title && (center_active || !done)
" Insert next title to the right
let group = self.get_group(self._right_title)
if self._right_title == self._last_title
let sep_change = s:get_separator_change_with_end(group, right_group, outer_right_group, self.overflow_group, sep_size, alt_sep_size) - overflow_marker_size
else
let sep_change = s:get_separator_change(group, right_group, self.overflow_group, sep_size, alt_sep_size)
endif
let right_group = group
let done = self.try_insert_title(self._right_title, group, self._right_position, sep_change, 0)
let self._right_title += done
4 0.000006 endif
4 0.000010 if !done
4 0.000009 break
endif
4 0.000015 endwhile
4 0.000015 if self._left_title >= self._first_title
if get(g:, 'airline#extensions#tabline#current_first', 0)
let self._left_position -= 1
endif
call self.insert_section(self.overflow_group, overflow_marker, self._left_position)
let self._right_position += 1
4 0.000006 endif
4 0.000014 if self._right_title <= self._last_title
call self.insert_section(self.overflow_group, overflow_marker, self._right_position)
4 0.000005 endif
4 0.000004 endif
4 0.020035 0.000046 return self._build()
FUNCTION airline#highlighter#get_highlight()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:68
Called 624 times
Total time: 0.139506
Self time: 0.056408
count total (s) self (s)
" only check for the cterm reverse attribute
" TODO: do we need to check all modes (gui, term, as well)?
624 0.006070 let reverse = synIDattr(synIDtrans(hlID(a:group)), 'reverse', 'cterm')
624 0.003246 if get(g:, 'airline_highlighting_cache', 0) && has_key(s:hl_groups, a:group)
let res = s:hl_groups[a:group]
return reverse ? [ res[1], res[0], res[3], res[2], res[4] ] : res
624 0.000579 else
624 0.026353 0.005364 let ctermfg = s:get_syn(a:group, 'fg', 'cterm')
624 0.024543 0.005069 let ctermbg = s:get_syn(a:group, 'bg', 'cterm')
624 0.023573 0.004658 let guifg = s:get_syn(a:group, 'fg', 'gui')
624 0.023416 0.004790 let guibg = s:get_syn(a:group, 'bg', 'gui')
624 0.004800 let bold = synIDattr(synIDtrans(hlID(a:group)), 'bold')
624 0.000926 if reverse
let res = s:get_array(guibg, guifg, ctermbg, ctermfg, bold ? ['bold'] : a:000)
624 0.000586 else
624 0.011587 0.006493 let res = s:get_array(guifg, guibg, ctermfg, ctermbg, bold ? ['bold'] : a:000)
624 0.000568 endif
624 0.000474 endif
624 0.002482 let s:hl_groups[a:group] = res
624 0.000870 return res
FUNCTION airline#mode_changed()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline.vim:297
Called 10 times
Total time: 0.000284
Self time: 0.000198
count total (s) self (s)
" airline#visual_active
" Boolean: for when to get visual wordcount
" needed for the wordcount extension
10 0.000098 let g:airline#visual_active = (mode() =~? '[vs]')
10 0.000159 0.000073 call airline#update_tabline()
FUNCTION <SNR>69_EnoughTimePassed()
Defined: ~/vimfiles/plugged/vim-wakatime/plugin/wakatime.vim:668
Called 5 times
Total time: 0.000119
Self time: 0.000119
count total (s) self (s)
5 0.000031 let prev = a:last.last_heartbeat_at
5 0.000041 if a:now - prev > g:wakatime_HeartbeatFrequency * 60
return s:true
5 0.000009 endif
5 0.000015 return s:false
FUNCTION vimwiki#vars#get_syntaxlocal()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/vars.vim:888
Called 22 times
Total time: 0.002515
Self time: 0.001128
count total (s) self (s)
22 0.000056 if a:0
let syntax = a:1
22 0.000038 else
22 0.001736 0.000349 let syntax = vimwiki#vars#get_wikilocal('syntax')
22 0.000035 endif
22 0.000250 if !exists('g:vimwiki_syntax_variables') || !has_key(g:vimwiki_syntax_variables, syntax)
call vimwiki#vars#populate_syntax_vars(syntax)
22 0.000035 endif
22 0.000141 return g:vimwiki_syntax_variables[syntax][a:key]
FUNCTION airline#extensions#tabline#new_builder()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline.vim:234
Called 4 times
Total time: 0.000820
Self time: 0.000398
count total (s) self (s)
4 0.000125 let builder_context = { 'active' : 1, 'tabline' : 1, 'right_sep' : get(g:, 'airline#extensions#tabline#right_sep' , g:airline_right_sep), 'right_alt_sep' : get(g:, 'airline#extensions#tabline#right_alt_sep', g:airline_right_alt_sep), }
4 0.000030 if get(g:, 'airline_powerline_fonts', 0)
let builder_context.left_sep = get(g:, 'airline#extensions#tabline#left_sep' , g:airline_left_sep)
let builder_context.left_alt_sep = get(g:, 'airline#extensions#tabline#left_alt_sep' , g:airline_left_alt_sep)
4 0.000006 else
4 0.000042 let builder_context.left_sep = get(g:, 'airline#extensions#tabline#left_sep' , ' ')
4 0.000035 let builder_context.left_alt_sep = get(g:, 'airline#extensions#tabline#left_alt_sep' , '|')
4 0.000006 endif
4 0.000498 0.000076 return airline#extensions#tabline#builder#new(builder_context)
FUNCTION airline#extensions#default#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/default.vim:79
Called 2 times
Total time: 0.003533
Self time: 0.000306
count total (s) self (s)
2 0.000012 let winnr = a:context.winnr
2 0.000010 let active = a:context.active
2 0.000056 0.000037 if airline#util#getwinvar(winnr, 'airline_render_left', active || (!active && !g:airline_inactive_collapse))
2 0.001486 0.000046 call s:build_sections(a:builder, a:context, s:layout[0])
else
let text = !empty(s:get_section(winnr, 'c')) ? s:get_section(winnr, 'c') : ' %f%m '
call a:builder.add_section('airline_c'.(a:context.bufnr), text)
2 0.000003 endif
2 0.000257 0.000051 call a:builder.split(s:get_section(winnr, 'gutter', '', ''))
2 0.000061 0.000045 if airline#util#getwinvar(winnr, 'airline_render_right', 1)
2 0.001585 0.000039 call s:build_sections(a:builder, a:context, s:layout[1])
2 0.000004 endif
2 0.000004 return 1
FUNCTION airline#util#stl_disabled()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:191
Called 4 times
Total time: 0.000333
Self time: 0.000230
count total (s) self (s)
" setting the statusline is disabled,
" either globally, per window, or per buffer
" w:airline_disabled is deprecated!
4 0.000315 0.000212 return get(g:, 'airline_disable_statusline', 0) || airline#util#getwinvar(a:winnr, 'airline_disable_statusline', 0) || airline#util#getwinvar(a:winnr, 'airline_disabled', 0) || airline#util#getbufvar(winbufnr(a:winnr), 'airline_disable_statusline', 0)
FUNCTION <SNR>166_hl_group_exists()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:99
Called 336 times
Total time: 0.006611
Self time: 0.006611
count total (s) self (s)
336 0.001825 if !hlexists(a:group)
return 0
336 0.002961 elseif empty(synIDattr(synIDtrans(hlID(a:group)), 'fg'))
return 0
336 0.000270 endif
336 0.000403 return 1
FUNCTION vimwiki#vars#get_global()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/vars.vim:942
Called 7 times
Total time: 0.000045
Self time: 0.000045
count total (s) self (s)
7 0.000039 return g:vimwiki_global_vars[a:key]
FUNCTION 87()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:109
Called 1 time
Total time: 0.000323
Self time: 0.000107
count total (s) self (s)
1 0.000008 let bufnum = get(self.buffers, a:i, -1)
1 0.000122 0.000010 let group = self.get_group(a:i)
1 0.000125 0.000021 let pgroup = self.get_group(a:i - 1)
" always add a space when powerline_fonts are used
" or for the very first item
1 0.000008 if get(g:, 'airline_powerline_fonts', 0) || a:i == 0
1 0.000005 let space = s:spc
else
let space= (pgroup == group ? s:spc : '')
1 0.000002 endif
1 0.000006 if get(g:, 'airline#extensions#tabline#buffer_idx_mode', 0)
if len(s:number_map) > 0
return space. s:get_number(a:i) . '%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)' . s:spc
else
return '['.(a:i+1).s:spc.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.']'
endif
1 0.000001 else
1 0.000010 return space.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.s:spc
endif
FUNCTION <SNR>166_get_array()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:60
Called 624 times
Total time: 0.005094
Self time: 0.005094
count total (s) self (s)
624 0.004862 return [ a:guifg, a:guibg, a:ctermfg, a:ctermbg, empty(a:opts) ? '' : join(a:opts, ',') ]
FUNCTION vimwiki#diary#get_diary_files()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/diary.vim:160
Called 1 time
Total time: 0.000683
Self time: 0.000517
count total (s) self (s)
1 0.000005 let rx = '^\d\{4}-\d\d-\d\d'
1 0.000630 0.000464 let s_files = glob(vimwiki#vars#get_wikilocal('path'). vimwiki#vars#get_wikilocal('diary_rel_path').'*'.vimwiki#vars#get_wikilocal('ext'))
1 0.000014 let files = split(s_files, '\n')
1 0.000018 call filter(files, 'fnamemodify(v:val, ":t") =~# "'.escape(rx, '\').'"')
" remove backup files (.wiki~)
1 0.000006 call filter(files, 'v:val !~# ''.*\~$''')
1 0.000004 return files
FUNCTION airline#extensions#tabline#formatters#unique_tail_improved#format()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/formatters/unique_tail_improved.vim:8
Called 12 times
Total time: 0.002462
Self time: 0.000336
count total (s) self (s)
12 0.000066 if len(a:buffers) <= 1 " don't need to compare bufnames if has less than one buffer opened
12 0.002379 0.000253 return airline#extensions#tabline#formatters#default#format(a:bufnr, a:buffers)
endif
let curbuf_tail = fnamemodify(bufname(a:bufnr), ':t')
let do_deduplicate = 0
let path_tokens = {}
for nr in a:buffers
let name = bufname(nr)
if !empty(name) && nr != a:bufnr && fnamemodify(name, ':t') == curbuf_tail " only perform actions if curbuf_tail isn't unique
let do_deduplicate = 1
let tokens = reverse(split(substitute(fnamemodify(name, ':p:h'), '\\', '/', 'g'), '/'))
let token_index = 0
for token in tokens
if token == '' | continue | endif
if token == '.' | break | endif
if !has_key(path_tokens, token_index)
let path_tokens[token_index] = {}
endif
let path_tokens[token_index][token] = 1
let token_index += 1
endfor
endif
endfor
if do_deduplicate == 1
let path = []
let token_index = 0
for token in reverse(split(substitute(fnamemodify(bufname(a:bufnr), ':p:h'), '\\', '/', 'g'), '/'))
if token == '.' | break | endif
let duplicated = 0
let uniq = 1
let single = 1
if has_key(path_tokens, token_index)
let duplicated = 1
if len(keys(path_tokens[token_index])) > 1 | let single = 0 | endif
if has_key(path_tokens[token_index], token) | let uniq = 0 | endif
endif
call insert(path, {'token': token, 'duplicated': duplicated, 'uniq': uniq, 'single': single})
let token_index += 1
endfor
let buf_name = [curbuf_tail]
let has_uniq = 0
let has_skipped = 0
for token1 in reverse(path)
if !token1['duplicated'] && len(buf_name) > 1
call insert(buf_name, s:skip_symbol)
let has_skipped = 0
break
endif
if has_uniq == 1
call insert(buf_name, s:skip_symbol)
let has_skipped = 0
break
endif
if token1['uniq'] == 0 && token1['single'] == 1
let has_skipped = 1
else
if has_skipped == 1
call insert(buf_name, s:skip_symbol)
let has_skipped = 0
endif
call insert(buf_name, token1['token'])
endif
if token1['uniq'] == 1
let has_uniq = 1
endif
endfor
if has_skipped == 1
call insert(buf_name, s:skip_symbol)
endif
return airline#extensions#tabline#formatters#default#wrap_name(a:bufnr, join(buf_name, '/'))
else
return airline#extensions#tabline#formatters#default#format(a:bufnr, a:buffers)
endif
FUNCTION FugitiveGitDir()
Defined: ~/vimfiles/plugged/vim-fugitive/plugin/fugitive.vim:18
Called 23 times
Total time: 0.001762
Self time: 0.001762
count total (s) self (s)
23 0.000069 if v:version < 704
return ''
23 0.000180 elseif !a:0 || type(a:1) == type(0) && a:1 < 0 || a:1 is# get(v:, 'true', -1)
23 0.000089 if exists('g:fugitive_event')
return g:fugitive_event
23 0.000027 endif
23 0.000115 let dir = get(b:, 'git_dir', '')
23 0.000475 if empty(dir) && (empty(bufname('')) || &buftype =~# '^\%(nofile\|acwrite\|quickfix\|terminal\|prompt\)$')
return FugitiveExtractGitDir(getcwd())
23 0.000271 elseif (!exists('b:git_dir') || b:git_dir =~# s:bad_git_dir) && &buftype =~# '^\%(nowrite\)\=$'
let b:git_dir = FugitiveExtractGitDir(bufnr(''))
return b:git_dir
23 0.000022 endif
23 0.000152 return dir =~# s:bad_git_dir ? '' : dir
elseif type(a:1) == type(0) && a:1 isnot# 0
if a:1 == bufnr('') && (!exists('b:git_dir') || b:git_dir =~# s:bad_git_dir) && &buftype =~# '^\%(nowrite\)\=$'
let b:git_dir = FugitiveExtractGitDir(a:1)
endif
let dir = getbufvar(a:1, 'git_dir')
return dir =~# s:bad_git_dir ? '' : dir
elseif type(a:1) == type('')
return substitute(s:Slash(a:1), '/$', '', '')
elseif type(a:1) == type({})
return get(a:1, 'fugitive_dir', get(a:1, 'git_dir', ''))
else
return ''
endif
FUNCTION <SNR>167_config_fugitive_branch()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/branch.vim:99
Called 23 times
Total time: 0.003404
Self time: 0.000570
count total (s) self (s)
23 0.003133 0.000299 let s:vcs_config['git'].branch = FugitiveHead(s:sha1size)
23 0.000146 if s:vcs_config['git'].branch is# 'master' && airline#util#winwidth() < 81
" Shorten default a bit
let s:vcs_config['git'].branch='mas'
23 0.000016 endif
FUNCTION 86()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:86
Called 3 times
Total time: 0.000357
Self time: 0.000176
count total (s) self (s)
3 0.000024 let bufnum = get(self.buffers, a:i, -1)
3 0.000009 if bufnum == -1
return ''
3 0.000006 endif
3 0.000254 0.000073 let group = airline#extensions#tabline#group_of_bufnr(self.tab_bufs, bufnum)
3 0.000016 if bufnum == bufnr('%')
3 0.000024 let s:current_modified = (group == 'airline_tabmod') ? 1 : 0
3 0.000004 endif
3 0.000009 return group
FUNCTION 88()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:86
Called 3 times
Total time: 0.000352
Self time: 0.000172
count total (s) self (s)
3 0.000021 let bufnum = get(self.buffers, a:i, -1)
3 0.000010 if bufnum == -1
return ''
3 0.000005 endif
3 0.000251 0.000071 let group = airline#extensions#tabline#group_of_bufnr(self.tab_bufs, bufnum)
3 0.000018 if bufnum == bufnr('%')
3 0.000024 let s:current_modified = (group == 'airline_tabmod') ? 1 : 0
3 0.000005 endif
3 0.000007 return group
FUNCTION 89()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:109
Called 1 time
Total time: 0.000309
Self time: 0.000094
count total (s) self (s)
1 0.000008 let bufnum = get(self.buffers, a:i, -1)
1 0.000121 0.000009 let group = self.get_group(a:i)
1 0.000113 0.000010 let pgroup = self.get_group(a:i - 1)
" always add a space when powerline_fonts are used
" or for the very first item
1 0.000008 if get(g:, 'airline_powerline_fonts', 0) || a:i == 0
1 0.000004 let space = s:spc
else
let space= (pgroup == group ? s:spc : '')
1 0.000002 endif
1 0.000007 if get(g:, 'airline#extensions#tabline#buffer_idx_mode', 0)
if len(s:number_map) > 0
return space. s:get_number(a:i) . '%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)' . s:spc
else
return '['.(a:i+1).s:spc.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.']'
endif
1 0.000002 else
1 0.000010 return space.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.s:spc
endif
FUNCTION airline#extensions#tabline#get()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline.vim:169
Called 8 times
Total time: 0.056355
Self time: 0.001134
count total (s) self (s)
8 0.000124 let show_buffers = get(g:, 'airline#extensions#tabline#show_buffers', 1)
8 0.000069 let show_tabs = get(g:, 'airline#extensions#tabline#show_tabs', 1)
8 0.000059 let curtabcnt = tabpagenr('$')
8 0.000047 if curtabcnt != s:current_tabcnt
let s:current_tabcnt = curtabcnt
call airline#extensions#tabline#tabs#invalidate()
call airline#extensions#tabline#buffers#invalidate()
call airline#extensions#tabline#ctrlspace#invalidate()
call airline#extensions#tabline#tabws#invalidate()
8 0.000015 endif
8 0.000085 if !exists('#airline#BufAdd#*')
autocmd airline BufAdd * call <sid>update_tabline(0)
8 0.000008 endif
8 0.000083 if !exists('#airline#SessionLoadPost')
autocmd airline SessionLoadPost * call <sid>update_tabline(1)
8 0.000014 endif
8 0.000024 if s:ctrlspace
return airline#extensions#tabline#ctrlspace#get()
8 0.000027 elseif s:tabws
return airline#extensions#tabline#tabws#get()
8 0.000050 elseif show_buffers && curtabcnt == 1 || !show_tabs
8 0.055392 0.000171 return airline#extensions#tabline#buffers#get()
else
return airline#extensions#tabline#tabs#get()
endif
FUNCTION 93()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:109
Called 1 time
Total time: 0.000309
Self time: 0.000094
count total (s) self (s)
1 0.000008 let bufnum = get(self.buffers, a:i, -1)
1 0.000122 0.000010 let group = self.get_group(a:i)
1 0.000113 0.000010 let pgroup = self.get_group(a:i - 1)
" always add a space when powerline_fonts are used
" or for the very first item
1 0.000008 if get(g:, 'airline_powerline_fonts', 0) || a:i == 0
1 0.000004 let space = s:spc
else
let space= (pgroup == group ? s:spc : '')
1 0.000001 endif
1 0.000007 if get(g:, 'airline#extensions#tabline#buffer_idx_mode', 0)
if len(s:number_map) > 0
return space. s:get_number(a:i) . '%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)' . s:spc
else
return '['.(a:i+1).s:spc.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.']'
endif
1 0.000002 else
1 0.000010 return space.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.s:spc
endif
FUNCTION airline#builder#get_prev_group()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:37
Called 46 times
Total time: 0.001427
Self time: 0.001427
count total (s) self (s)
46 0.000192 let x = a:i - 1
56 0.000170 while x >= 0
42 0.000248 let group = a:sections[x][0]
42 0.000201 if group != '' && group != '|'
32 0.000077 return group
10 0.000015 endif
10 0.000029 let x = x - 1
24 0.000052 endwhile
14 0.000035 return ''
FUNCTION airline#util#getwinvar()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:84
Called 26 times
Total time: 0.000223
Self time: 0.000223
count total (s) self (s)
26 0.000205 return getwinvar(a:winnr, a:key, a:def)
FUNCTION <SNR>167_sh_autocmd_handler()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/branch.vim:356
Called 2 times
Total time: 0.000033
Self time: 0.000033
count total (s) self (s)
2 0.000014 if exists('#airline')
2 0.000010 unlet! b:airline_head b:airline_do_mq_check
2 0.000003 endif
FUNCTION <SNR>211_tabline_evaluated_length()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/builder.vim:223
Called 20 times
Total time: 0.003967
Self time: 0.000526
count total (s) self (s)
20 0.003951 0.000510 return airline#util#strchars(s:evaluate_tabline(a:tabline))
FUNCTION <SNR>50_SetDefaultCompletionType()
Defined: ~/vimfiles/plugged/supertab/plugin/supertab.vim:380
Called 1 time
Total time: 0.000024
Self time: 0.000024
count total (s) self (s)
1 0.000015 if exists('b:SuperTabDefaultCompletionType') && (!exists('b:complCommandLine') || !b:complCommandLine)
call SuperTabSetCompletionType(b:SuperTabDefaultCompletionType)
1 0.000002 endif
FUNCTION <SNR>183_get_seperator()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:155
Called 12 times
Total time: 0.027024
Self time: 0.000467
count total (s) self (s)
12 0.009476 0.000212 if airline#builder#should_change_group(a:prev_group, a:group)
12 0.017535 0.000242 return s:get_transitioned_seperator(a:self, a:prev_group, a:group, a:side)
else
return a:side ? a:self._context.left_alt_sep : a:self._context.right_alt_sep
endif
FUNCTION <SNR>186_safesubstitute()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/base.vim:15
Called 2 times
Total time: 0.000054
Self time: 0.000054
count total (s) self (s)
" Substitute regexp but do not interpret replace
2 0.000016 let escaped = escape(a:replace, '\&')
2 0.000033 return substitute(a:text, a:search, escaped, a:mode)
FUNCTION 21()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:25
Called 4 times
Total time: 0.000048
Self time: 0.000048
count total (s) self (s)
4 0.000044 call insert(self._sections, [a:group, a:contents], a:position)
FUNCTION 23()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:33
Called 4 times
Total time: 0.000027
Self time: 0.000027
count total (s) self (s)
4 0.000023 return len(self._sections)
FUNCTION airline#update_statusline_focuslost()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline.vim:164
Called 2 times
Total time: 0.000129
Self time: 0.000129
count total (s) self (s)
2 0.000054 if get(g:, 'airline_focuslost_inactive', 0)
let bufnr=bufnr('%')
call airline#highlighter#highlight_modified_inactive(bufnr)
call airline#highlighter#highlight(['inactive'], bufnr)
call airline#update_statusline_inactive(range(1, winnr('$')))
2 0.000006 endif
FUNCTION <SNR>133_Remove_Matches()
Defined: /usr/share/vim/vim90/plugin/matchparen.vim:197
Called 9 times
Total time: 0.000212
Self time: 0.000212
count total (s) self (s)
9 0.000084 if exists('w:paren_hl_on') && w:paren_hl_on
2 0.000016 silent! call matchdelete(3)
2 0.000009 let w:paren_hl_on = 0
9 0.000013 endif
FUNCTION airline#extensions#tabline#group_of_bufnr()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline.vim:252
Called 12 times
Total time: 0.000659
Self time: 0.000659
count total (s) self (s)
12 0.000072 let cur = bufnr('%')
12 0.000041 if cur == a:bufnr
12 0.000111 if g:airline_detect_modified && getbufvar(a:bufnr, '&modified')
6 0.000021 let group = 'airline_tabmod'
6 0.000011 else
6 0.000021 let group = 'airline_tabsel'
12 0.000017 endif
else
if g:airline_detect_modified && getbufvar(a:bufnr, '&modified')
let group = 'airline_tabmod_unsel'
elseif index(a:tab_bufs, a:bufnr) > -1
let group = 'airline_tab'
else
let group = 'airline_tabhid'
endif
12 0.000018 endif
12 0.000031 return group
FUNCTION 90()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:86
Called 3 times
Total time: 0.000255
Self time: 0.000138
count total (s) self (s)
3 0.000017 let bufnum = get(self.buffers, a:i, -1)
3 0.000008 if bufnum == -1
return ''
3 0.000003 endif
3 0.000168 0.000051 let group = airline#extensions#tabline#group_of_bufnr(self.tab_bufs, bufnum)
3 0.000011 if bufnum == bufnr('%')
3 0.000016 let s:current_modified = (group == 'airline_tabmod') ? 1 : 0
3 0.000004 endif
3 0.000005 return group
FUNCTION vimwiki#tbl#reset_tw()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/tbl.vim:756
Called 1 time
Total time: 0.001079
Self time: 0.000069
count total (s) self (s)
1 0.000081 0.000018 if !vimwiki#u#ft_is_vw()
return
1 0.000001 endif
1 0.000015 let line = getline(a:lnum)
1 0.000971 0.000024 if !s:is_table(line)
1 0.000002 return
endif
let s:textwidth = &textwidth
let &textwidth = 0
FUNCTION FugitiveHead()
Defined: ~/vimfiles/plugged/vim-fugitive/plugin/fugitive.vim:236
Called 23 times
Total time: 0.002834
Self time: 0.001072
count total (s) self (s)
23 0.000275 if a:0 && (type(a:1) ==# type({}) || type(a:1) ==# type('') && a:1 !~# '^\d\+$')
let dir = FugitiveGitDir(a:1)
let arg = get(a:, 2, 0)
23 0.000050 elseif a:0 > 1
let dir = FugitiveGitDir(a:2)
let arg = a:1
23 0.000028 else
23 0.001948 0.000186 let dir = FugitiveGitDir()
23 0.000116 let arg = get(a:, 1, 0)
23 0.000025 endif
23 0.000060 if empty(dir)
23 0.000037 return ''
endif
return fugitive#Head(arg, dir)
FUNCTION airline#highlighter#highlight()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:255
Called 10 times
Total time: 0.197072
Self time: 0.030380
count total (s) self (s)
10 0.000050 let bufnr = a:0 ? a:1 : ''
10 0.000065 let p = g:airline#themes#{g:airline_theme}#palette
" draw the base mode, followed by any overrides
10 0.000228 let mapped = map(a:modes, 'v:val == a:modes[0] ? v:val : a:modes[0]."_".v:val')
10 0.000054 let suffix = a:modes[0] == 'inactive' ? '_inactive' : ''
10 0.000032 let airline_grouplist = []
10 0.000068 let buffers_in_tabpage = sort(tabpagebuflist())
10 0.000058 if exists("*uniq")
10 0.000051 let buffers_in_tabpage = uniq(buffers_in_tabpage)
10 0.000012 endif
" mapped might be something like ['normal', 'normal_modified']
" if a group is in both modes available, only define the second
" that is how this was done previously overwrite the previous definition
32 0.000100 for mode in reverse(mapped)
22 0.000205 if exists('g:airline#themes#{g:airline_theme}#palette[mode]')
10 0.000049 let dict = g:airline#themes#{g:airline_theme}#palette[mode]
190 0.000459 for kvp in items(dict)
180 0.000564 let mode_colors = kvp[1]
180 0.000469 let name = kvp[0]
180 0.000723 if name is# 'airline_c' && !empty(bufnr) && suffix is# '_inactive'
let name = 'airline_c'.bufnr
180 0.000135 endif
" do not re-create highlighting for buffers that are no longer visible
" in the current tabpage
180 0.001266 if name =~# 'airline_c\d\+'
let bnr = matchstr(name, 'airline_c\zs\d\+') + 0
if bnr > 0 && index(buffers_in_tabpage, bnr) == -1
continue
endif
180 0.001277 elseif (name =~# '_to_') || (name[0:10] is# 'airline_tab' && !empty(suffix))
" group will be redefined below at exec_separator
" or is not needed for tabline with '_inactive' suffix
" since active flag is 1 for builder)
100 0.000115 continue
80 0.000064 endif
80 0.001700 0.000808 if s:group_not_done(airline_grouplist, name.suffix)
72 0.034658 0.000810 call airline#highlighter#exec(name.suffix, mode_colors)
80 0.000073 endif
80 0.000293 if !has_key(p, 'accents')
" work around a broken installation
" shouldn't actually happen, p should always contain accents
continue
80 0.000066 endif
240 0.000606 for accent in keys(s:accents)
160 0.000567 if !has_key(p.accents, accent)
continue
160 0.000127 endif
160 0.000645 let colors = copy(mode_colors)
160 0.000632 if p.accents[accent][0] != ''
80 0.000339 let colors[0] = p.accents[accent][0]
160 0.000135 endif
160 0.000496 if p.accents[accent][2] != ''
80 0.000294 let colors[2] = p.accents[accent][2]
160 0.000130 endif
160 0.000462 if len(colors) >= 5
160 0.000830 let colors[4] = get(p.accents[accent], 4, '')
else
call add(colors, get(p.accents[accent], 4, ''))
160 0.000126 endif
160 0.003745 0.001958 if s:group_not_done(airline_grouplist, name.suffix.'_'.accent)
144 0.065862 0.001790 call airline#highlighter#exec(name.suffix.'_'.accent, colors)
160 0.000139 endif
240 0.000252 endfor
90 0.000075 endfor
10 0.000025 if empty(s:separators)
" nothing to be done
continue
10 0.000006 endif
" TODO: optimize this
110 0.000193 for sep in items(s:separators)
" we cannot check, that the group already exists, else the separators
" might not be correctly defined. But perhaps we can skip above groups
" that match the '_to_' name, because they would be redefined here...
100 0.067372 0.001279 call <sid>exec_separator(dict, sep[1][0], sep[1][1], sep[1][2], suffix)
110 0.000090 endfor
22 0.000025 endif
32 0.000050 endfor
FUNCTION airline#builder#get_next_group()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:49
Called 4 times
Total time: 0.000243
Self time: 0.000243
count total (s) self (s)
4 0.000018 let x = a:i + 1
4 0.000022 let l = len(a:sections)
8 0.000029 while x < l
8 0.000065 let group = a:sections[x][0]
8 0.000039 if group != '' && group != '|'
4 0.000011 return group
4 0.000008 endif
4 0.000013 let x = x + 1
4 0.000010 endwhile
return ''
FUNCTION <SNR>167_update_branch()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/branch.vim:183
Called 23 times
Total time: 0.009224
Self time: 0.001965
count total (s) self (s)
69 0.000237 for vcs in keys(s:vcs_config)
46 0.007946 0.000687 call {s:vcs_config[vcs].update_branch}()
46 0.000264 if b:buffer_vcs_config[vcs].branch != s:vcs_config[vcs].branch
let b:buffer_vcs_config[vcs].branch = s:vcs_config[vcs].branch
unlet! b:airline_head
46 0.000037 endif
69 0.000115 endfor
FUNCTION airline#extensions#wordcount#formatters#default#update_fmt()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/wordcount/formatters/default.vim:6
Called 2 times
Total time: 0.000055
Self time: 0.000055
count total (s) self (s)
2 0.000023 let s:fmt = get(g:, 'airline#extensions#wordcount#formatter#default#fmt', '%s words')
2 0.000030 let s:fmt_short = get(g:, 'airline#extensions#wordcount#formatter#default#fmt_short', s:fmt == '%s words' ? '%sW' : s:fmt)
FUNCTION airline#util#ignore_next_focusgain()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:201
Called 23 times
Total time: 0.000265
Self time: 0.000265
count total (s) self (s)
23 0.000112 if has('win32')
" Setup an ignore for platforms that trigger FocusLost on calls to
" system(). macvim (gui and terminal) and Linux terminal vim do not.
let s:focusgained_ignore_time = localtime()
23 0.000019 endif
FUNCTION 91()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:109
Called 1 time
Total time: 0.000198
Self time: 0.000061
count total (s) self (s)
1 0.000006 let bufnum = get(self.buffers, a:i, -1)
1 0.000078 0.000006 let group = self.get_group(a:i)
1 0.000071 0.000006 let pgroup = self.get_group(a:i - 1)
" always add a space when powerline_fonts are used
" or for the very first item
1 0.000005 if get(g:, 'airline_powerline_fonts', 0) || a:i == 0
1 0.000003 let space = s:spc
else
let space= (pgroup == group ? s:spc : '')
1 0.000001 endif
1 0.000004 if get(g:, 'airline#extensions#tabline#buffer_idx_mode', 0)
if len(s:number_map) > 0
return space. s:get_number(a:i) . '%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)' . s:spc
else
return '['.(a:i+1).s:spc.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.']'
endif
1 0.000001 else
1 0.000006 return space.'%(%{airline#extensions#tabline#get_buffer_name('.bufnum.')}%)'.s:spc
endif
FUNCTION airline#update_statusline()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline.vim:144
Called 2 times
Total time: 0.031127
Self time: 0.000346
count total (s) self (s)
2 0.000293 0.000084 if airline#util#stl_disabled(winnr()) || airline#util#is_popup_window(winnr())
return
2 0.000004 endif
" TODO: need to ignore popup windows here as well?
2 0.000038 let range = filter(range(1, winnr('$')), 'v:val != winnr()')
" create inactive statusline
2 0.000370 0.000034 call airline#update_statusline_inactive(range)
2 0.000010 unlet! w:airline_render_left w:airline_render_right
2 0.000060 exe 'unlet! ' 'w:airline_section_'. join(s:sections, ' w:airline_section_')
" Now create the active statusline
2 0.000008 let w:airline_active = 1
2 0.000029 let context = { 'winnr': winnr(), 'active': 1, 'bufnr': winbufnr(winnr()) }
2 0.030290 0.000054 call s:invoke_funcrefs(context, g:airline_statusline_funcrefs)
FUNCTION 92()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim:86
Called 3 times
Total time: 0.000341
Self time: 0.000160
count total (s) self (s)
3 0.000022 let bufnum = get(self.buffers, a:i, -1)
3 0.000009 if bufnum == -1
return ''
3 0.000005 endif
3 0.000237 0.000056 let group = airline#extensions#tabline#group_of_bufnr(self.tab_bufs, bufnum)
3 0.000017 if bufnum == bufnr('%')
3 0.000023 let s:current_modified = (group == 'airline_tabmod') ? 1 : 0
3 0.000004 endif
3 0.000007 return group
FUNCTION <SNR>166_exec_separator()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:189
Called 122 times
Total time: 0.096389
Self time: 0.006313
count total (s) self (s)
122 0.000276 if pumvisible()
return
122 0.000090 endif
122 0.000449 let group = a:from.'_to_'.a:to.a:suffix
122 0.026930 0.001053 let l:from = airline#themes#get_highlight(a:from.a:suffix)
122 0.025386 0.001074 let l:to = airline#themes#get_highlight(a:to.a:suffix)
122 0.000162 if a:inverse
68 0.000399 let colors = [ l:from[1], l:to[1], l:from[3], l:to[3] ]
54 0.000042 else
54 0.000349 let colors = [ l:to[1], l:from[1], l:to[3], l:from[3] ]
122 0.000090 endif
122 0.000423 let a:dict[group] = colors
122 0.041028 0.001141 call airline#highlighter#exec(group, colors)
FUNCTION airline#highlighter#exec()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:219
Called 348 times
Total time: 0.145228
Self time: 0.045299
count total (s) self (s)
348 0.000799 if pumvisible()
return
348 0.000291 endif
348 0.000803 let colors = a:colors
348 0.000923 if len(colors) == 4
122 0.000342 call add(colors, '')
348 0.000280 endif
" colors should always be string values
348 0.009831 let colors = map(copy(colors), 'type(v:val) != type("") ? string(v:val) : v:val')
348 0.000688 if s:is_win32term
let colors[2] = s:gui2cui(get(colors, 0, ''), get(colors, 2, ''))
let colors[3] = s:gui2cui(get(colors, 1, ''), get(colors, 3, ''))
348 0.000275 endif
348 0.084063 0.003734 let old_hi = airline#highlighter#get_highlight(a:group)
348 0.003834 let new_hi = [colors[0], colors[1], printf('%s', colors[2]), printf('%s', colors[3]), colors[4]]
348 0.014151 0.003050 let colors = s:CheckDefined(colors)
348 0.010231 0.003620 if old_hi != new_hi || !s:hl_group_exists(a:group)
12 0.002023 0.000135 let cmd = printf('hi %s%s', a:group, s:GetHiCmd(colors))
12 0.000012 try
12 0.000203 exe cmd
catch /^Vim\%((\a\+)\)\=:E421:/ " color definition not found
let group=matchstr(v:exception, '\w\+\ze=')
let color=matchstr(v:exception, '=\zs\w\+')
let cmd=substitute(cmd, color, 'grey', 'g')
exe cmd
call airline#util#warning('color definition for group ' . a:group . ' not found, using grey as fallback')
catch
call airline#util#warning('Error when running command: '. cmd)
12 0.000018 endtry
12 0.000043 if has_key(s:hl_groups, a:group)
12 0.000039 let s:hl_groups[a:group] = colors
12 0.000009 endif
348 0.000272 endif
FUNCTION <SNR>167_update_git_branch()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/branch.vim:87
Called 23 times
Total time: 0.004913
Self time: 0.000988
count total (s) self (s)
23 0.000513 0.000248 call airline#util#ignore_next_focusgain()
23 0.000475 0.000219 if airline#util#has_fugitive()
23 0.003637 0.000233 call s:config_fugitive_branch()
elseif airline#util#has_gina()
call s:config_gina_branch()
else
let s:vcs_config['git'].branch = ''
return
23 0.000024 endif
FUNCTION airline#builder#should_change_group()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:130
Called 16 times
Total time: 0.012615
Self time: 0.000952
count total (s) self (s)
16 0.000072 if a:group1 == a:group2
return 0
16 0.000022 endif
16 0.006302 0.000253 let color1 = airline#highlighter#get_highlight(a:group1)
16 0.005946 0.000332 let color2 = airline#highlighter#get_highlight(a:group2)
16 0.000199 return color1[1] != color2[1] || color1[0] != color2[0] || color1[2] != color2[2] || color1[3] != color2[3]
FUNCTION airline#extensions#append_to_section()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions.vim:54
Called 2 times
Total time: 0.000129
Self time: 0.000077
count total (s) self (s)
2 0.000106 0.000054 call <sid>check_defined_section(a:name)
2 0.000021 let w:airline_section_{a:name} .= a:value
FUNCTION <SNR>217_is_separator()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/tbl.vim:65
Called 2 times
Total time: 0.000695
Self time: 0.000097
count total (s) self (s)
2 0.000694 0.000096 return a:line =~# '^\s*'.s:rxSep().'\(:\=--\+:\='.s:rxSep().'\)\+\s*$'
FUNCTION airline#util#is_popup_window()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:209
Called 2 times
Total time: 0.000041
Self time: 0.000041
count total (s) self (s)
" Keep the statusline active if it's a popup window
2 0.000014 if exists('*win_gettype')
2 0.000022 return win_gettype(a:winnr) ==# 'popup' || win_gettype(a:winnr) ==# 'autocmd'
else
return getwinvar(a:winnr, '&buftype', '') ==# 'popup'
endif
FUNCTION airline#extensions#searchcount#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/searchcount.vim:15
Called 2 times
Total time: 0.000173
Self time: 0.000044
count total (s) self (s)
2 0.000171 0.000042 call airline#extensions#append_to_section('y', '%{v:hlsearch ? airline#extensions#searchcount#status() : ""}')
FUNCTION <SNR>187_normalize_link_syntax_n()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/markdown_base.vim:52
Called 1 time
Total time: 0.002782
Self time: 0.000384
count total (s) self (s)
1 0.000006 let lnum = line('.')
" try WikiIncl
1 0.000116 0.000025 let lnk = vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_global('rxWikiIncl'))
1 0.000005 if !empty(lnk)
" NO-OP !!
return
1 0.000001 endif
" try WikiLink0: replace with WikiLink1
1 0.000231 0.000028 let lnk = vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_syntaxlocal('rxWikiLink0'))
1 0.000005 if !empty(lnk)
let sub = vimwiki#base#normalize_link_helper(lnk, vimwiki#vars#get_syntaxlocal('rxWikiLinkMatchUrl'), vimwiki#vars#get_syntaxlocal('rxWikiLinkMatchDescr'), vimwiki#vars#get_syntaxlocal('WikiLink1Template2'))
call vimwiki#base#replacestr_at_cursor(vimwiki#vars#get_syntaxlocal('rxWikiLink0'), sub)
return
1 0.000002 endif
" try WikiLink1: replace with WikiLink0
1 0.000232 0.000025 let lnk = vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_syntaxlocal('rxWikiLink1'))
1 0.000004 if !empty(lnk)
let sub = vimwiki#base#normalize_link_helper(lnk, vimwiki#vars#get_syntaxlocal('rxWikiLinkMatchUrl'), vimwiki#vars#get_syntaxlocal('rxWikiLinkMatchDescr'), vimwiki#vars#get_global('WikiLinkTemplate2'))
call vimwiki#base#replacestr_at_cursor(vimwiki#vars#get_syntaxlocal('rxWikiLink1'), sub)
return
1 0.000001 endif
" try Weblink
1 0.000272 0.000026 let lnk = vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_syntaxlocal('rxWeblink'))
1 0.000004 if !empty(lnk)
let sub = vimwiki#base#normalize_link_helper(lnk, vimwiki#vars#get_syntaxlocal('rxWeblinkMatchUrl'), vimwiki#vars#get_syntaxlocal('rxWeblinkMatchDescr'), vimwiki#vars#get_syntaxlocal('Weblink1Template'))
call vimwiki#base#replacestr_at_cursor(vimwiki#vars#get_syntaxlocal('rxWeblink'), sub)
return
1 0.000002 endif
" try Word (any characters except separators)
" rxWord is less permissive than rxWikiLinkUrl which is used in
" normalize_link_syntax_v
1 0.000157 0.000026 let lnk = vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_global('rxWord'))
1 0.000004 if !empty(lnk)
1 0.000778 0.000045 if vimwiki#base#is_diary_file(expand('%:p'))
let sub = vimwiki#base#normalize_link_in_diary(lnk)
1 0.000002 else
1 0.000710 0.000049 let sub = vimwiki#base#normalize_link_helper(lnk, vimwiki#vars#get_global('rxWord'), '', vimwiki#vars#get_syntaxlocal('Weblink1Template'))
1 0.000002 endif
1 0.000147 0.000021 call vimwiki#base#replacestr_at_cursor('\V'.lnk, sub)
1 0.000002 return
endif
FUNCTION vimwiki#vars#get_bufferlocal()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/vars.vim:904
Called 30 times
Total time: 0.000925
Self time: 0.000925
count total (s) self (s)
30 0.000156 let buffer = a:0 ? a:1 : '%'
" 'get(getbufvar(...' handles vim < v7.3.831 that didn't allow a default value for getbufvar
30 0.000391 let value = get(getbufvar(buffer, ''), 'vimwiki_'.a:key, '/\/\')
30 0.000185 if type(value) != 1 || value !=# '/\/\'
30 0.000085 return value
elseif a:key ==# 'wiki_nr'
call setbufvar(buffer, 'vimwiki_wiki_nr', vimwiki#base#find_wiki(expand('%:p')))
elseif a:key ==# 'subdir'
call setbufvar(buffer, 'vimwiki_subdir', vimwiki#base#current_subdir())
elseif a:key ==# 'invsubdir'
let subdir = vimwiki#vars#get_bufferlocal('subdir')
call setbufvar(buffer, 'vimwiki_invsubdir', vimwiki#base#invsubdir(subdir))
elseif a:key ==# 'existing_wikifiles'
call setbufvar(buffer, 'vimwiki_existing_wikifiles', vimwiki#base#get_wikilinks(vimwiki#vars#get_bufferlocal('wiki_nr'), 1, ''))
elseif a:key ==# 'existing_wikidirs'
call setbufvar(buffer, 'vimwiki_existing_wikidirs', vimwiki#base#get_wiki_directories(vimwiki#vars#get_bufferlocal('wiki_nr')))
elseif a:key ==# 'prev_links'
call setbufvar(buffer, 'vimwiki_prev_links', [])
elseif a:key ==# 'markdown_refs'
call setbufvar(buffer, 'vimwiki_markdown_refs', vimwiki#markdown_base#scan_reflinks())
else
echoerr 'Vimwiki Error: unknown buffer variable ' . string(a:key)
endif
return getbufvar(buffer, 'vimwiki_'.a:key)
FUNCTION vimwiki#base#is_diary_file()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/base.vim:2161
Called 1 time
Total time: 0.000733
Self time: 0.000050
count total (s) self (s)
1 0.000704 0.000021 let l:diary_file_paths = a:0 > 0 ? a:1 : vimwiki#diary#get_diary_files()
1 0.000011 let l:normalised_file_paths = map(l:diary_file_paths, 'vimwiki#path#normalize(v:val)')
1 0.000009 let l:matching_files = filter(l:normalised_file_paths, 'v:val =~# a:filename')
1 0.000007 return len(l:matching_files) > 0 " filename is a diary file if match is found
FUNCTION <SNR>186_clean_url()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/base.vim:2131
Called 1 time
Total time: 0.000276
Self time: 0.000203
count total (s) self (s)
" don't use an extension as part of the description
1 0.000098 0.000025 let url = substitute(a:url, '\'.vimwiki#vars#get_wikilocal('ext').'$', '', '')
" remove protocol and tld
1 0.000015 let url = substitute(url, '^\a\+\d*:', '', '')
" remove absolute path prefix
1 0.000009 let url = substitute(url, '^//', '', '')
1 0.000026 let url = substitute(url, '^\([^/]\+\)\.\a\{2,4}/', '\1/', '')
1 0.000016 let url_l = split(url, '/\|=\|-\|&\|?\|\.')
" case only a '-'
1 0.000004 if url_l == []
return ''
1 0.000002 endif
1 0.000012 let url_l = filter(url_l, 'v:val !=# ""')
1 0.000006 if url_l[0] ==# 'www'
let url_l = url_l[1:]
1 0.000001 endif
1 0.000014 if url_l[-1] =~# '^\(htm\|html\|php\)$'
let url_l = url_l[0:-2]
1 0.000001 endif
" remove words with black listed codepoints
" TODO mutualize blacklist in a variable
1 0.000021 let url_l = filter(url_l, 'v:val !~? "[!\"$%&''()*+,:;<=>?\[\]\\^`{}]"')
" remove words consisting of only hexadecimal digits
1 0.000018 let url_l = filter(url_l, 'v:val !~? "^\\x\\{4,}$" || v:val !~? "\\d"')
1 0.000008 return join(url_l, ' ')
FUNCTION <SNR>168_sh_autocmd_handler()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/fugitiveline.vim:45
Called 2 times
Total time: 0.000025
Self time: 0.000025
count total (s) self (s)
2 0.000012 if exists('#airline')
2 0.000007 unlet! b:fugitive_name
2 0.000003 endif
FUNCTION airline#extensions#tabline#formatters#default#wrap_name()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/formatters/default.vim:34
Called 12 times
Total time: 0.000703
Self time: 0.000703
count total (s) self (s)
12 0.000104 let buf_nr_format = get(g:, 'airline#extensions#tabline#buffer_nr_format', '%s: ')
12 0.000084 let buf_nr_show = get(g:, 'airline#extensions#tabline#buffer_nr_show', 0)
12 0.000132 let _ = buf_nr_show ? printf(buf_nr_format, a:bufnr) : ''
12 0.000148 let _ .= substitute(a:buffer_name, '\\', '/', 'g')
12 0.000090 if getbufvar(a:bufnr, '&modified') == 1
4 0.000017 let _ .= g:airline_symbols.modified
12 0.000018 endif
12 0.000030 return _
FUNCTION <SNR>211_get_separator_change()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/builder.vim:68
Called 8 times
Total time: 0.003971
Self time: 0.000187
count total (s) self (s)
8 0.003961 0.000177 return s:get_separator_change_with_end(a:new_group, a:old_group, a:end_group, a:end_group, a:sep_size, a:alt_sep_size)
FUNCTION <SNR>69_GetCurrentFile()
Defined: ~/vimfiles/plugged/vim-wakatime/plugin/wakatime.vim:415
Called 5 times
Total time: 0.000177
Self time: 0.000177
count total (s) self (s)
5 0.000169 return expand("%:p")
FUNCTION airline#extensions#tabline#add_label()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline.vim:30
Called 4 times
Total time: 0.000097
Self time: 0.000097
count total (s) self (s)
4 0.000032 if get(g:, 'airline#extensions#tabline#show_tab_type', 1)
call a:dict.add_section_spaced('airline_tablabel'. (a:right ? '_right' : ''), get(g:, 'airline#extensions#tabline#'.a:type.'_label', a:type))
4 0.000008 endif
FUNCTION airline#extensions#tabline#formatters#default#format()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/formatters/default.vim:7
Called 12 times
Total time: 0.002126
Self time: 0.001423
count total (s) self (s)
12 0.000105 let fnametruncate = get(g:, 'airline#extensions#tabline#fnametruncate', 0)
12 0.000080 let fmod = get(g:, 'airline#extensions#tabline#fnamemod', ':~:.')
12 0.000032 let _ = ''
12 0.000077 let name = bufname(a:bufnr)
12 0.000052 if empty(name)
let _ = '[No Name]'
12 0.000102 elseif name =~ 'term://'
" Neovim Terminal
let _ = substitute(name, '\(term:\)//.*:\(.*\)', '\1 \2', '')
12 0.000018 else
12 0.000070 if get(g:, 'airline#extensions#tabline#fnamecollapse', 1)
" Does not handle non-ascii characters like Cyrillic: 'D/Учёба/t.c'
"let _ .= substitute(fnamemodify(name, fmod), '\v\w\zs.{-}\ze(\\|/)', '', 'g')
12 0.000116 let _ = pathshorten(fnamemodify(name, fmod))
else
let _ = fnamemodify(name, fmod)
12 0.000017 endif
12 0.000107 if a:bufnr != bufnr('%') && fnametruncate && strlen(_) > fnametruncate
let _ = airline#util#strcharpart(_, 0, fnametruncate)
12 0.000016 endif
12 0.000016 endif
12 0.000974 0.000271 return airline#extensions#tabline#formatters#default#wrap_name(a:bufnr, _)
FUNCTION 44()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/builder.vim:18
Called 4 times
Total time: 0.000177
Self time: 0.000150
count total (s) self (s)
4 0.000024 let self._first_title = a:first " lowest index
4 0.000018 let self._last_title = a:last " highest index
4 0.000016 let self._left_title = a:current " next index to add on the left
4 0.000020 let self._right_title = a:current + 1 " next index to add on the right
4 0.000072 0.000045 let self._left_position = self.get_position() " left end of titles
4 0.000018 let self._right_position = self._left_position " right end of the titles
FUNCTION <SNR>90_on_cursor_moved()
Defined: ~/vimfiles/plugged/vim-airline/plugin/airline.vim:87
Called 5 times
Total time: 0.000267
Self time: 0.000187
count total (s) self (s)
5 0.000075 if winnr() != s:active_winnr || !exists('w:airline_active')
call s:on_window_changed('CursorMoved')
5 0.000008 endif
5 0.000142 0.000062 call airline#update_tabline()
FUNCTION airline#extensions#quickfix#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/quickfix.vim:14
Called 2 times
Total time: 0.000047
Self time: 0.000047
count total (s) self (s)
2 0.000010 if &buftype == 'quickfix'
let w:airline_section_a = airline#extensions#quickfix#get_type()
let w:airline_section_b = '%{get(w:, "quickfix_title", "")}'
let w:airline_section_c = ''
let w:airline_section_x = ''
2 0.000003 endif
FUNCTION airline#util#strchars()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:121
Called 20 times
Total time: 0.000196
Self time: 0.000196
count total (s) self (s)
20 0.000068 if s:has_strchars
20 0.000110 return strchars(a:str)
else
return strlen(substitute(a:str, '.', 'a', 'g'))
endif
FUNCTION vimwiki#base#replacestr_at_cursor()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/base.vim:923
Called 1 time
Total time: 0.000126
Self time: 0.000126
count total (s) self (s)
1 0.000006 let col = col('.') - 1
1 0.000005 let line = getline('.')
1 0.000004 let ebeg = -1
1 0.000011 let cont = match(line, a:wikiRX, 0)
1 0.000009 while (ebeg >= 0 || (0 <= cont) && (cont <= col))
1 0.000010 let contn = matchend(line, a:wikiRX, cont)
1 0.000006 if (cont <= col) && (col < contn)
1 0.000008 let ebeg = match(line, a:wikiRX, cont)
1 0.000004 let elen = contn - ebeg
1 0.000002 break
else
let cont = match(line, a:wikiRX, contn)
endif
1 0.000003 endwh
1 0.000004 if ebeg >= 0
" TODO: There might be problems with Unicode chars...
1 0.000013 let newline = strpart(line, 0, ebeg).a:sub.strpart(line, ebeg+elen)
1 0.000023 call setline(line('.'), newline)
1 0.000001 endif
FUNCTION <SNR>183_get_accented_line()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:163
Called 32 times
Total time: 0.002498
Self time: 0.002498
count total (s) self (s)
32 0.000100 if a:self._context.active
" active window
32 0.000105 let contents = []
32 0.000367 let content_parts = split(a:contents, '__accent')
48 0.000152 for cpart in content_parts
16 0.000196 let accent = matchstr(cpart, '_\zs[^#]*\ze')
16 0.000088 call add(contents, cpart)
48 0.000088 endfor
32 0.000201 let line = join(contents, a:group)
32 0.000359 let line = substitute(line, '__restore__', a:group, 'g')
else
" inactive window
let line = substitute(a:contents, '%#__accent[^#]*#', '', 'g')
let line = substitute(line, '%#__restore__#', '', 'g')
32 0.000043 endif
32 0.000078 return line
FUNCTION airline#extensions#wordcount#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/wordcount.vim:93
Called 2 times
Total time: 0.000216
Self time: 0.000216
count total (s) self (s)
2 0.000037 let filetypes = get(g:, 'airline#extensions#wordcount#filetypes', ['asciidoc', 'help', 'mail', 'markdown', 'nroff', 'org', 'rst', 'plaintex', 'tex', 'text'])
" export current filetypes settings to global namespace
2 0.000011 let g:airline#extensions#wordcount#filetypes = filetypes
" Check if filetype needs testing
2 0.000010 if did_filetype()
" correctly test for compound filetypes (e.g. markdown.pandoc)
let ft = substitute(&filetype, '\.', '\\|', 'g')
" Select test based on type of "filetypes": new=list, old=string
if type(filetypes) == get(v:, 't_list', type([])) ? match(filetypes, '\<'. ft. '\>') > -1 || index(filetypes, 'all') > -1 : match(&filetype, filetypes) > -1
let b:airline_changedtick = -1
call s:update_wordcount(1) " force update: ensures initial worcount exists
elseif exists('b:airline_wordcount') " cleanup when filetype is removed
unlet b:airline_wordcount
endif
2 0.000004 endif
2 0.000014 if exists('b:airline_wordcount')
call airline#extensions#prepend_to_section( 'z', '%{airline#extensions#wordcount#get()}')
2 0.000003 endif
FUNCTION <SNR>216_ReloadWinStatus()
Defined: ~/vimfiles/plugged/vim-fugitive/autoload/fugitive.vim:4247
Called 2 times
Total time: 0.000028
Self time: 0.000028
count total (s) self (s)
2 0.000020 if get(b:, 'fugitive_type', '') !=# 'index' || &modified
2 0.000004 return
endif
if !exists('b:fugitive_reltime')
exe s:ReloadStatusBuffer()
return
endif
let t = b:fugitive_reltime
if reltimestr(reltime(s:last_time, t)) =~# '-\|\d\{10\}\.' || reltimestr(reltime(get(s:last_times, s:Tree() . '/', t), t)) =~# '-\|\d\{10\}\.'
exe s:ReloadStatusBuffer()
endif
FUNCTION vimwiki#markdown_base#normalize_link()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/markdown_base.vim:150
Called 1 time
Total time: 0.002835
Self time: 0.000053
count total (s) self (s)
1 0.000002 if 0
" Syntax-specific links
1 0.000001 else
1 0.000004 if !a:is_visual_mode
1 0.002807 0.000025 call s:normalize_link_syntax_n()
elseif line("'<") == line("'>")
" action undefined for multi-line visual mode selections
call s:normalize_link_syntax_v()
1 0.000002 endif
1 0.000002 endif
FUNCTION airline#extensions#tabline#builder#new()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/builder.vim:227
Called 4 times
Total time: 0.000422
Self time: 0.000165
count total (s) self (s)
4 0.000321 0.000064 let builder = airline#builder#new(a:context)
4 0.000025 let builder._build = builder.build
4 0.000056 call extend(builder, s:prototype, 'force')
4 0.000013 return builder
FUNCTION airline#extensions#searchcount#status()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/searchcount.vim:27
Called 23 times
Total time: 0.001595
Self time: 0.001595
count total (s) self (s)
23 0.000033 try
23 0.000429 let result = searchcount(#{recompute: 1, maxcount: -1})
23 0.000112 if empty(result) || result.total ==# 0
23 0.000046 return ''
endif
if result.incomplete ==# 1 " timed out
return printf('%s [?/??]', s:search_term())
elseif result.incomplete ==# 2 " max count exceeded
if result.total > result.maxcount && result.current > result.maxcount
return printf('%s[>%d/>%d]', s:search_term(), result.current, result.total)
elseif result.total > result.maxcount
return printf('%s[%d/>%d]', s:search_term(), result.current, result.total)
endif
endif
return printf('%s[%d/%d]', s:search_term(), result.current, result.total)
catch
return ''
23 0.000033 endtry
FUNCTION <SNR>166_get_syn()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:44
Called 2496 times
Total time: 0.078004
Self time: 0.078004
count total (s) self (s)
2496 0.004378 let color = ''
2496 0.012570 if hlexists(a:group)
2496 0.020523 let color = synIDattr(synIDtrans(hlID(a:group)), a:what, a:mode)
2496 0.002125 endif
2496 0.007795 if empty(color) || color == -1
" should always exist
let color = synIDattr(synIDtrans(hlID('Normal')), a:what, a:mode)
" however, just in case
if empty(color) || color == -1
let color = 'NONE'
endif
2496 0.001900 endif
2496 0.003479 return color
FUNCTION airline#statusline()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline.vim:208
Called 23 times
Total time: 0.000680
Self time: 0.000680
count total (s) self (s)
23 0.000331 if has_key(s:contexts, a:winnr)
23 0.000292 return '%{airline#check_mode('.a:winnr.')}'.s:contexts[a:winnr].line
endif
" in rare circumstances this happens...see #276
return ''
FUNCTION <SNR>183_get_transitioned_seperator()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:140
Called 22 times
Total time: 0.032592
Self time: 0.001613
count total (s) self (s)
22 0.000068 let line = ''
22 0.000250 if get(a:self._context, 'tabline', 0) && get(g:, 'airline#extensions#tabline#alt_sep', 0) && a:group ==# 'airline_tabsel' && a:side
call airline#highlighter#add_separator(a:prev_group, a:group, 0)
let line .= '%#'.a:prev_group.'_to_'.a:group.'#'
let line .= a:self._context.right_sep.'%#'.a:group.'#'
22 0.000031 else
22 0.031366 0.000387 call airline#highlighter#add_separator(a:prev_group, a:group, a:side)
22 0.000167 let line .= '%#'.a:prev_group.'_to_'.a:group.'#'
22 0.000163 let line .= a:side ? a:self._context.left_sep : a:self._context.right_sep
22 0.000094 let line .= '%#'.a:group.'#'
22 0.000030 endif
22 0.000050 return line
FUNCTION <SNR>69_HandleActivity()
Defined: ~/vimfiles/plugged/vim-wakatime/plugin/wakatime.vim:718
Called 5 times
Total time: 0.001667
Self time: 0.000944
count total (s) self (s)
5 0.000290 0.000113 let file = s:GetCurrentFile()
5 0.000186 if !empty(file) && file !~ "-MiniBufExplorer-" && file !~ "--NO NAME--" && file !~ "^term:"
5 0.000520 0.000113 let last = s:GetLastHeartbeat()
5 0.000027 let now = localtime()
" Create a heartbeat when saving a file, when the current file
" changes, and when still editing the same file but enough time
" has passed since the last heartbeat.
5 0.000283 0.000164 if a:is_write || s:EnoughTimePassed(now, last) || file != last.file
call s:AppendHeartbeat(file, now, a:is_write, last)
5 0.000011 else
5 0.000033 if now - s:last_heartbeat.last_activity_at > s:local_cache_expire
1 0.000043 0.000023 call s:SetLastHeartbeatInMemory(now, last.last_heartbeat_at, last.file)
5 0.000009 endif
5 0.000006 endif
" When buffering heartbeats disabled, no need to re-check the
" heartbeats buffer.
5 0.000021 if s:buffering_heartbeats_enabled
" Only send buffered heartbeats every s:send_buffer_seconds
5 0.000027 if now - s:last_sent > s:send_buffer_seconds
call s:SendHeartbeats()
5 0.000008 endif
5 0.000006 endif
5 0.000007 endif
FUNCTION <SNR>133_Highlight_Matching_Pair()
Defined: /usr/share/vim/vim90/plugin/matchparen.vim:40
Called 9 times
Total time: 0.004711
Self time: 0.004499
count total (s) self (s)
" Remove any previous match.
9 0.000368 0.000156 call s:Remove_Matches()
" Avoid that we remove the popup menu.
" Return when there are no colors (looks like the cursor jumps).
9 0.000096 if pumvisible() || (&t_Co < 8 && !has("gui_running"))
return
9 0.000012 endif
" Get the character under the cursor and check if it's in 'matchpairs'.
9 0.000059 let c_lnum = line('.')
9 0.000054 let c_col = col('.')
9 0.000030 let before = 0
9 0.000088 let text = getline(c_lnum)
9 0.000308 let matches = matchlist(text, '\(.\)\=\%'.c_col.'c\(.\=\)')
9 0.000048 if empty(matches)
let [c_before, c] = ['', '']
9 0.000016 else
9 0.000092 let [c_before, c] = matches[1:2]
9 0.000012 endif
9 0.000248 let plist = split(&matchpairs, '.\zs[:,]')
9 0.000069 let i = index(plist, c)
9 0.000033 if i < 0
" not found, in Insert mode try character before the cursor
7 0.000064 if c_col > 1 && (mode() == 'i' || mode() == 'R')
let before = strlen(c_before)
let c = c_before
let i = index(plist, c)
7 0.000013 endif
7 0.000019 if i < 0
" not found, nothing to do
7 0.000018 return
endif
2 0.000003 endif
" Figure out the arguments for searchpairpos().
2 0.000007 if i % 2 == 0
2 0.000008 let s_flags = 'nW'
2 0.000014 let c2 = plist[i + 1]
else
let s_flags = 'nbW'
let c2 = c
let c = plist[i - 1]
2 0.000003 endif
2 0.000008 if c == '['
2 0.000006 let c = '\['
2 0.000005 let c2 = '\]'
2 0.000003 endif
" Find the match. When it was just before the cursor move it there for a
" moment.
2 0.000006 if before > 0
let has_getcurpos = exists("*getcurpos")
if has_getcurpos
" getcurpos() is more efficient but doesn't exist before 7.4.313.
let save_cursor = getcurpos()
else
let save_cursor = winsaveview()
endif
call cursor(c_lnum, c_col - before)
2 0.000003 endif
2 0.000031 if !has("syntax") || !exists("g:syntax_on")
let s_skip = "0"
2 0.000004 else
" Build an expression that detects whether the current cursor position is
" in certain syntax types (string, comment, etc.), for use as
" searchpairpos()'s skip argument.
" We match "escape" for special items, such as lispEscapeSpecial, and
" match "symbol" for lispBarSymbol.
2 0.000021 let s_skip = '!empty(filter(map(synstack(line("."), col(".")), ''synIDattr(v:val, "name")''), ' . '''v:val =~? "string\\|character\\|singlequote\\|escape\\|symbol\\|comment"''))'
" If executing the expression determines that the cursor is currently in
" one of the syntax types, then we want searchpairpos() to find the pair
" within those syntax types (i.e., not skip). Otherwise, the cursor is
" outside of the syntax types and s_skip should keep its value so we skip
" any matching pair inside the syntax types.
" Catch if this throws E363: pattern uses more memory than 'maxmempattern'.
2 0.000005 try
2 0.000949 execute 'if ' . s_skip . ' | let s_skip = "0" | endif'
catch /^Vim\%((\a\+)\)\=:E363/
" We won't find anything, so skip searching, should keep Vim responsive.
return
2 0.000005 endtry
2 0.000003 endif
" Limit the search to lines visible in the window.
2 0.000017 let stoplinebottom = line('w$')
2 0.000014 let stoplinetop = line('w0')
2 0.000009 if i % 2 == 0
2 0.000011 let stopline = stoplinebottom
else
let stopline = stoplinetop
2 0.000003 endif
" Limit the search time to 300 msec to avoid a hang on very long lines.
" This fails when a timeout is not supported.
2 0.000019 if mode() == 'i' || mode() == 'R'
let timeout = exists("b:matchparen_insert_timeout") ? b:matchparen_insert_timeout : g:matchparen_insert_timeout
2 0.000002 else
2 0.000023 let timeout = exists("b:matchparen_timeout") ? b:matchparen_timeout : g:matchparen_timeout
2 0.000003 endif
2 0.000004 try
2 0.000813 let [m_lnum, m_col] = searchpairpos(c, '', c2, s_flags, s_skip, stopline, timeout)
catch /E118/
" Can't use the timeout, restrict the stopline a bit more to avoid taking
" a long time on closed folds and long lines.
" The "viewable" variables give a range in which we can scroll while
" keeping the cursor at the same position.
" adjustedScrolloff accounts for very large numbers of scrolloff.
let adjustedScrolloff = min([&scrolloff, (line('w$') - line('w0')) / 2])
let bottom_viewable = min([line('$'), c_lnum + &lines - adjustedScrolloff - 2])
let top_viewable = max([1, c_lnum-&lines+adjustedScrolloff + 2])
" one of these stoplines will be adjusted below, but the current values are
" minimal boundaries within the current window
if i % 2 == 0
if has("byte_offset") && has("syntax_items") && &smc > 0
let stopbyte = min([line2byte("$"), line2byte(".") + col(".") + &smc * 2])
let stopline = min([bottom_viewable, byte2line(stopbyte)])
else
let stopline = min([bottom_viewable, c_lnum + 100])
endif
let stoplinebottom = stopline
else
if has("byte_offset") && has("syntax_items") && &smc > 0
let stopbyte = max([1, line2byte(".") + col(".") - &smc * 2])
let stopline = max([top_viewable, byte2line(stopbyte)])
else
let stopline = max([top_viewable, c_lnum - 100])
endif
let stoplinetop = stopline
endif
let [m_lnum, m_col] = searchpairpos(c, '', c2, s_flags, s_skip, stopline)
2 0.000005 endtry
2 0.000007 if before > 0
if has_getcurpos
call setpos('.', save_cursor)
else
call winrestview(save_cursor)
endif
2 0.000003 endif
" If a match is found setup match highlighting.
2 0.000015 if m_lnum > 0 && m_lnum >= stoplinetop && m_lnum <= stoplinebottom
2 0.000016 if exists('*matchaddpos')
2 0.000165 call matchaddpos('MatchParen', [[c_lnum, c_col - before], [m_lnum, m_col]], 10, 3)
else
exe '3match MatchParen /\(\%' . c_lnum . 'l\%' . (c_col - before) . 'c\)\|\(\%' . m_lnum . 'l\%' . m_col . 'c\)/'
2 0.000004 endif
2 0.000010 let w:paren_hl_on = 1
2 0.000004 endif
FUNCTION <SNR>167_update_untracked()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/branch.vim:202
Called 23 times
Total time: 0.003529
Self time: 0.003032
count total (s) self (s)
23 0.000439 let file = expand("%:p")
23 0.000241 if empty(file) || isdirectory(file) || !empty(&buftype)
return
23 0.000018 endif
23 0.000055 let needs_update = 1
23 0.000180 let vcs_checks = get(g:, "airline#extensions#branch#vcs_checks", ["untracked", "dirty"])
69 0.000202 for vcs in keys(s:vcs_config)
46 0.000311 if file =~ s:vcs_config[vcs].exclude
" Skip check for files that live in the exclude directory
let needs_update = 0
46 0.000049 endif
46 0.000212 if has_key(s:vcs_config[vcs].untracked, file)
23 0.000077 let needs_update = 0
23 0.000828 0.000331 call airline#extensions#branch#update_untracked_config(file, vcs)
46 0.000048 endif
69 0.000076 endfor
23 0.000044 if !needs_update
23 0.000034 return
endif
for vcs in keys(s:vcs_config)
" only check, for git, if fugitive is installed
" and for 'hg' if lawrencium is installed, else skip
if vcs is# 'git' && (!airline#util#has_fugitive() && !airline#util#has_gina())
continue
elseif vcs is# 'mercurial' && !airline#util#has_lawrencium()
continue
endif
let config = s:vcs_config[vcs]
" Note that asynchronous update updates s:vcs_config only, and only
" s:update_untracked updates b:buffer_vcs_config. If s:vcs_config is
" invalidated again before s:update_untracked is called, then we lose the
" result of the previous call, i.e. the head string is not updated. It
" doesn't happen often in practice, so we let it be.
if index(vcs_checks, 'untracked') > -1
call airline#async#vcs_untracked(config, file, vcs)
endif
" Check clean state of repo
if index(vcs_checks, 'dirty') > -1
call airline#async#vcs_clean(config.dirty, file, vcs)
endif
endfor
FUNCTION airline#extensions#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions.vim:72
Called 2 times
Total time: 0.000544
Self time: 0.000305
count total (s) self (s)
2 0.000020 let filetype_overrides = get(s:, 'filetype_overrides', {})
2 0.000025 call extend(filetype_overrides, get(g:, 'airline_filetype_overrides', {}), 'force')
2 0.000269 0.000030 if s:is_excluded_window()
return -1
2 0.000004 endif
2 0.000008 if &buftype == 'terminal'
let w:airline_section_x = ''
let w:airline_section_y = ''
2 0.000003 endif
2 0.000015 if &previewwindow && empty(get(w:, 'airline_section_a', ''))
let w:airline_section_a = 'Preview'
let w:airline_section_b = ''
let w:airline_section_c = bufname(winbufnr(winnr()))
2 0.000003 endif
2 0.000032 if has_key(filetype_overrides, &ft) && ((&filetype == 'help' && &buftype == 'help') || &filetype !~ 'help')
" for help files only override it, if the buftype is also of type 'help',
" else it would trigger when editing Vim help files
let args = filetype_overrides[&ft]
call airline#extensions#apply_left_override(args[0], args[1])
2 0.000003 endif
2 0.000007 if &buftype == 'help'
let w:airline_section_x = ''
let w:airline_section_y = ''
let w:airline_render_right = 1
2 0.000003 endif
2 0.000015 for item in items(s:filetype_regex_overrides)
if match(&ft, item[0]) >= 0
call airline#extensions#apply_left_override(item[1][0], item[1][1])
endif
2 0.000004 endfor
FUNCTION <SNR>158_is_excluded_window()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions.vim:112
Called 2 times
Total time: 0.000239
Self time: 0.000239
count total (s) self (s)
2 0.000011 for matchft in g:airline_exclude_filetypes
if matchft ==# &ft
return 1
endif
2 0.000004 endfor
8 0.000027 for matchw in g:airline_exclude_filenames
6 0.000092 if matchstr(expand('%'), matchw) ==# matchw
return 1
6 0.000008 endif
8 0.000013 endfor
2 0.000009 if g:airline_exclude_preview && &previewwindow
return 1
2 0.000004 endif
2 0.000005 return 0
FUNCTION <SNR>158_check_defined_section()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions.vim:48
Called 2 times
Total time: 0.000052
Self time: 0.000052
count total (s) self (s)
2 0.000023 if !exists('w:airline_section_{a:name}')
2 0.000024 let w:airline_section_{a:name} = g:airline_section_{a:name}
2 0.000003 endif
FUNCTION <SNR>216_ExpireStatus()
Defined: ~/vimfiles/plugged/vim-fugitive/autoload/fugitive.vim:4231
Called 2 times
Total time: 0.000052
Self time: 0.000052
count total (s) self (s)
2 0.000013 if a:bufnr is# -2 || a:bufnr is# 0
2 0.000012 let s:head_cache = {}
2 0.000015 let s:last_time = reltime()
2 0.000005 return ''
endif
let head_file = fugitive#Find('.git/HEAD', a:bufnr)
if !empty(head_file)
let s:last_times[s:Tree(a:bufnr) . '/'] = reltime()
if has_key(s:head_cache, head_file)
call remove(s:head_cache, head_file)
endif
endif
return ''
FUNCTION vimwiki#u#ft_is_vw()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/u.vim:149
Called 2 times
Total time: 0.000098
Self time: 0.000098
count total (s) self (s)
" Clause: is filetype defined
2 0.000028 if &filetype ==# '' | return 0 | endif
2 0.000051 if split(&filetype, '\.')[0] ==? 'vimwiki'
2 0.000007 return 1
else
return 0
endif
FUNCTION vimwiki#base#follow_link()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/base.vim:1302
Called 1 time
Total time: 0.004917
Self time: 0.000604
count total (s) self (s)
1 0.000015 let reuse_other_split_window = a:0 >= 1 ? a:1 : 0
1 0.000007 let move_cursor_to_new_window = a:0 >= 2 ? a:2 : 1
" Parse link at cursor and pass to VimwikiLinkHandler, or failing that, the
" default open_link handler
" try WikiLink
1 0.000517 0.000085 let lnk = matchstr(vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_syntaxlocal('rxWikiLink')), vimwiki#vars#get_syntaxlocal('rxWikiLinkMatchUrl'))
" try WikiIncl
1 0.000004 if lnk ==? ''
1 0.000157 0.000050 let lnk = matchstr(vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_global('rxWikiIncl')), vimwiki#vars#get_global('rxWikiInclMatchUrl'))
1 0.000002 endif
" try Weblink
1 0.000004 if lnk ==? ''
1 0.000474 0.000086 let lnk = matchstr(vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_syntaxlocal('rxWeblink')), vimwiki#vars#get_syntaxlocal('rxWeblinkMatchUrl'))
1 0.000001 endif
1 0.000070 0.000014 if vimwiki#vars#get_wikilocal('syntax') ==# 'markdown'
" markdown image ![]()
1 0.000003 if lnk ==# ''
1 0.000370 0.000079 let lnk = matchstr(vimwiki#base#matchstr_at_cursor(vimwiki#vars#get_syntaxlocal('rxImage')), vimwiki#vars#get_syntaxlocal('rxWeblinkMatchUrl'))
1 0.000004 if lnk !=# ''
if lnk !~# '\%(\%('.vimwiki#vars#get_global('web_schemes1').'\):\%(\/\/\)\?\)\S\{-1,}'
" prepend file: scheme so link is opened by sytem handler if it isn't a web url
let lnk = 'file:'.lnk
endif
1 0.000001 endif
1 0.000001 endif
1 0.000002 endif
1 0.000003 if lnk !=? '' " cursor is indeed on a link
let processed_by_user_defined_handler = VimwikiLinkHandler(lnk)
if processed_by_user_defined_handler
return
endif
if a:split ==# 'hsplit'
let cmd = ':split '
elseif a:split ==# 'vsplit'
let cmd = ':vsplit '
elseif a:split ==# 'tab'
let cmd = ':tabnew '
else
let cmd = ':e '
endif
" if we want to and can reuse a split window, jump to that window and open
" the new file there
if (a:split ==# 'hsplit' || a:split ==# 'vsplit') && reuse_other_split_window
let previous_window_nr = winnr('#')
if previous_window_nr > 0 && previous_window_nr != winnr()
execute previous_window_nr . 'wincmd w'
let cmd = ':e'
endif
endif
if vimwiki#vars#get_wikilocal('syntax') ==# 'markdown'
let processed_by_markdown_reflink = vimwiki#markdown_base#open_reflink(lnk)
if processed_by_markdown_reflink
return
endif
" remove the extension from the filename if exists, because non-vimwiki
" markdown files usually include the extension in links
let lnk = substitute(lnk, '\'.vimwiki#vars#get_wikilocal('ext').'$', '', '')
endif
let current_tab_page = tabpagenr()
call vimwiki#base#open_link(cmd, lnk)
if !move_cursor_to_new_window
if (a:split ==# 'hsplit' || a:split ==# 'vsplit')
execute 'wincmd p'
elseif a:split ==# 'tab'
execute 'tabnext ' . current_tab_page
endif
endif
1 0.000002 else " cursor is not on a link
1 0.000004 if a:0 >= 3
execute 'normal! '.a:3
1 0.000019 0.000013 elseif vimwiki#vars#get_global('create_link')
1 0.003092 0.000059 call vimwiki#base#normalize_link(0)
1 0.000002 endif
1 0.000001 endif
FUNCTION <SNR>185_build_sections()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/default.vim:35
Called 4 times
Total time: 0.002986
Self time: 0.000489
count total (s) self (s)
16 0.000052 for key in a:keys
12 0.000090 if (key == 'warning' || key == 'error') && !a:context.active
continue
12 0.000015 endif
12 0.002695 0.000198 call s:add_section(a:builder, a:context, key)
16 0.000031 endfor
FUNCTION airline#highlighter#highlight_modified_inactive()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:205
Called 10 times
Total time: 0.008070
Self time: 0.000649
count total (s) self (s)
10 0.000083 if getbufvar(a:bufnr, '&modified')
2 0.000032 let colors = exists('g:airline#themes#{g:airline_theme}#palette.inactive_modified.airline_c') ? g:airline#themes#{g:airline_theme}#palette.inactive_modified.airline_c : []
8 0.000010 else
8 0.000154 let colors = exists('g:airline#themes#{g:airline_theme}#palette.inactive.airline_c') ? g:airline#themes#{g:airline_theme}#palette.inactive.airline_c : []
10 0.000014 endif
10 0.000036 if !empty(colors)
10 0.007604 0.000183 call airline#highlighter#exec('airline_c'.(a:bufnr).'_inactive', colors)
10 0.000011 endif
FUNCTION airline#extensions#fzf#apply()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/fzf.vim:28
Called 2 times
Total time: 0.000047
Self time: 0.000047
count total (s) self (s)
2 0.000008 if &filetype ==# 'fzf'
let spc = g:airline_symbols.space
call a:1.add_section('airline_a', spc.'FZF'.spc)
call a:1.add_section('airline_c', '')
return 1
2 0.000003 endif
FUNCTION vimwiki#base#matchstr_at_cursor()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/base.vim:900
Called 9 times
Total time: 0.001007
Self time: 0.001007
count total (s) self (s)
9 0.000057 let col = col('.') - 1
9 0.000049 let line = getline('.')
9 0.000026 let ebeg = -1
9 0.000361 let cont = match(line, a:wikiRX, 0)
9 0.000073 while (ebeg >= 0 || (0 <= cont) && (cont <= col))
1 0.000020 let contn = matchend(line, a:wikiRX, cont)
1 0.000006 if (cont <= col) && (col < contn)
1 0.000018 let ebeg = match(line, a:wikiRX, cont)
1 0.000004 let elen = contn - ebeg
1 0.000002 break
else
let cont = match(line, a:wikiRX, contn)
endif
9 0.000021 endwh
9 0.000028 if ebeg >= 0
1 0.000007 return strpart(line, ebeg, elen)
8 0.000014 else
8 0.000020 return ''
endif
FUNCTION airline#highlighter#reset_hlcache()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:64
Called 2 times
Total time: 0.000156
Self time: 0.000156
count total (s) self (s)
2 0.000154 let s:hl_groups = {}
FUNCTION airline#update_statusline_inactive()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline.vim:174
Called 2 times
Total time: 0.000336
Self time: 0.000171
count total (s) self (s)
2 0.000210 0.000045 if airline#util#stl_disabled(winnr())
return
2 0.000003 endif
2 0.000008 for nr in a:range
if airline#util#stl_disabled(nr)
continue
endif
call setwinvar(nr, 'airline_active', 0)
let context = { 'winnr': nr, 'active': 0, 'bufnr': winbufnr(nr) }
if get(g:, 'airline_inactive_alt_sep', 0)
call extend(context, { 'left_sep': g:airline_left_alt_sep, 'right_sep': g:airline_right_alt_sep }, 'keep')
endif
call s:invoke_funcrefs(context, g:airline_inactive_funcrefs)
2 0.000008 endfor
FUNCTION <SNR>166_GetHiCmd()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/highlighter.vim:140
Called 12 times
Total time: 0.001888
Self time: 0.001888
count total (s) self (s)
" a:list needs to have 5 items!
12 0.000023 let res = ''
12 0.000019 let i = -1
72 0.000101 while i < 4
60 0.000105 let i += 1
60 0.000216 let item = get(a:list, i, '')
60 0.000119 if item is ''
12 0.000013 continue
48 0.000038 endif
48 0.000065 if i == 0
12 0.000039 let res .= ' guifg='.item
36 0.000045 elseif i == 1
10 0.000026 let res .= ' guibg='.item
26 0.000032 elseif i == 2
12 0.000031 let res .= ' ctermfg='.item
14 0.000015 elseif i == 3
10 0.000021 let res .= ' ctermbg='.item
4 0.000004 elseif i == 4
4 0.000018 let res .= printf(' gui=%s cterm=%s term=%s', item, item, item)
48 0.000034 endif
60 0.000057 endwhile
12 0.000020 return res
FUNCTION airline#util#has_vcscommand()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:167
Called 23 times
Total time: 0.000337
Self time: 0.000337
count total (s) self (s)
23 0.000101 if !exists("s:has_vcscommand")
let s:has_vcscommand = exists('*VCSCommandGetStatusLine')
23 0.000021 endif
23 0.000122 return get(g:, 'airline#extensions#branch#use_vcscommand', 0) && s:has_vcscommand
FUNCTION airline#extensions#tabline#add_tab_label()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline.vim:37
Called 4 times
Total time: 0.000179
Self time: 0.000179
count total (s) self (s)
4 0.000037 let show_tab_count = get(g:, 'airline#extensions#tabline#show_tab_count', 1)
4 0.000014 if show_tab_count == 2
call a:dict.add_section_spaced('airline_tabmod', printf('%s %d/%d', "tab", tabpagenr(), tabpagenr('$')))
4 0.000031 elseif show_tab_count == 1 && tabpagenr('$') > 1
call a:dict.add_section_spaced('airline_tabmod', printf('%s %d/%d', "tab", tabpagenr(), tabpagenr('$')))
4 0.000008 endif
FUNCTION airline#util#getbufvar()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/util.vim:73
Called 4 times
Total time: 0.000037
Self time: 0.000037
count total (s) self (s)
4 0.000035 return getbufvar(a:bufnr, a:key, a:def)
FUNCTION vimwiki#base#normalize_link()
Defined: ~/vimfiles/plugged/vimwiki/autoload/vimwiki/base.vim:2308
Called 1 time
Total time: 0.003033
Self time: 0.000085
count total (s) self (s)
1 0.000081 0.000021 if exists('*vimwiki#'.vimwiki#vars#get_wikilocal('syntax').'_base#normalize_link')
" Syntax-specific links
1 0.002925 0.000037 call vimwiki#{vimwiki#vars#get_wikilocal('syntax')}_base#normalize_link(a:is_visual_mode)
else
if !a:is_visual_mode
call s:normalize_link_syntax_n()
elseif line("'<") == line("'>")
" action undefined for multi-line visual mode selections
call s:normalize_link_syntax_v()
endif
1 0.000002 endif
FUNCTION <SNR>69_SetLastHeartbeatInMemory()
Defined: ~/vimfiles/plugged/vim-wakatime/plugin/wakatime.vim:652
Called 1 time
Total time: 0.000020
Self time: 0.000020
count total (s) self (s)
1 0.000018 let s:last_heartbeat = {'last_activity_at': a:last_activity_at, 'last_heartbeat_at': a:last_heartbeat_at, 'file': a:file}
FUNCTION <SNR>211_get_separator_change_with_end()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/extensions/tabline/builder.vim:76
Called 8 times
Total time: 0.003784
Self time: 0.000433
count total (s) self (s)
8 0.000026 let sep_change = 0
8 0.000037 if !empty(a:new_end_group) " Separator between title and the end
4 0.003434 0.000083 let sep_change += airline#builder#should_change_group(a:new_group, a:new_end_group) ? a:sep_size : a:alt_sep_size
8 0.000011 endif
8 0.000037 if !empty(a:old_group) " Separator between the title and the one adjacent
let sep_change += airline#builder#should_change_group(a:new_group, a:old_group) ? a:sep_size : a:alt_sep_size
if !empty(a:old_end_group) " Remove mis-predicted separator
let sep_change -= airline#builder#should_change_group(a:old_group, a:old_end_group) ? a:sep_size : a:alt_sep_size
endif
8 0.000011 endif
8 0.000022 return sep_change
FUNCTION airline#builder#new()
Defined: ~/vimfiles/plugged/vim-airline/autoload/airline/builder.vim:229
Called 6 times
Total time: 0.000373
Self time: 0.000373
count total (s) self (s)
6 0.000108 let builder = copy(s:prototype)
6 0.000031 let builder._context = a:context
6 0.000028 let builder._sections = []
6 0.000159 call extend(builder._context, { 'left_sep': g:airline_left_sep, 'left_alt_sep': g:airline_left_alt_sep, 'right_sep': g:airline_right_sep, 'right_alt_sep': g:airline_right_alt_sep, }, 'keep')
6 0.000020 return builder
FUNCTIONS SORTED ON TOTAL TIME
count total (s) self (s) function
23 0.212087 0.006074 airline#check_mode()
10 0.197072 0.030380 airline#highlighter#highlight()
348 0.145228 0.045299 airline#highlighter#exec()
624 0.139506 0.056408 airline#highlighter#get_highlight()
122 0.096389 0.006313 <SNR>166_exec_separator()
2496 0.078004 <SNR>166_get_syn()
10 0.056428 0.009341 24()
8 0.056355 0.001134 airline#extensions#tabline#get()
8 0.055221 0.002117 airline#extensions#tabline#buffers#get()
244 0.050189 0.002675 airline#themes#get_highlight()
4 0.045199 0.002336 46()
22 0.032592 0.001613 <SNR>183_get_transitioned_seperator()
2 0.032019 0.000105 <SNR>90_on_focus_gained()
2 0.031862 0.000285 <SNR>90_airline_refresh()
2 0.031127 0.000346 airline#update_statusline()
22 0.030979 0.000683 airline#highlighter#add_separator()
2 0.030236 0.000205 <SNR>160_invoke_funcrefs()
12 0.027024 0.000467 <SNR>183_get_seperator()
23 0.018099 0.004856 airline#extensions#branch#head()
16 0.012615 0.000952 airline#builder#should_change_group()
FUNCTIONS SORTED ON SELF TIME
count total (s) self (s) function
2496 0.078004 <SNR>166_get_syn()
624 0.139506 0.056408 airline#highlighter#get_highlight()
348 0.145228 0.045299 airline#highlighter#exec()
10 0.197072 0.030380 airline#highlighter#highlight()
348 0.011101 <SNR>166_CheckDefined()
10 0.056428 0.009341 24()
336 0.006611 <SNR>166_hl_group_exists()
8 0.006454 <SNR>175_map_keys()
122 0.096389 0.006313 <SNR>166_exec_separator()
23 0.212087 0.006074 airline#check_mode()
624 0.005094 <SNR>166_get_array()
23 0.018099 0.004856 airline#extensions#branch#head()
9 0.004711 0.004499 <SNR>133_Highlight_Matching_Pair()
23 0.003529 0.003032 <SNR>167_update_untracked()
240 0.002679 <SNR>166_group_not_done()
244 0.050189 0.002675 airline#themes#get_highlight()
32 0.002498 <SNR>183_get_accented_line()
4 0.045199 0.002336 46()
20 0.003245 0.002138 <SNR>211_evaluate_tabline()
8 0.055221 0.002117 airline#extensions#tabline#buffers#get()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment