SCRIPT /root/.vim/plugged/coc.nvim/autoload/coc/list.vim Sourced 1 time Total time: 0.000725 Self time: 0.000725 count total (s) self (s) 1 0.000019 let s:activated = 0 1 0.000070 let s:is_vim = !has('nvim') 1 0.000101 let s:saved_ve = &t_ve 1 0.000013 let s:saved_cursor = &guicursor 1 0.000012 let s:gui = has('gui_running') || has('nvim') 1 0.000011 function! coc#list#get_chars() return { \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '' : "\", \ '' : "\", \ '' : "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '<2-LeftMouse>': "\<2-LeftMouse>", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \ '': "\", \} endfunction 1 0.000004 function! coc#list#getc() abort let c = getchar() return type(c) == type(0) ? nr2char(c) : c endfunction 1 0.000002 function! coc#list#getchar() abort let input = coc#list#getc() if 1 != &iminsert return input endif "a language keymap is activated, so input must be resolved to the mapped values. let partial_keymap = mapcheck(input, "l") while partial_keymap !=# "" let full_keymap = maparg(input, "l") if full_keymap ==# "" && len(input) >= 3 "HACK: assume there are no keymaps longer than 3. return input elseif full_keymap ==# partial_keymap return full_keymap endif let c = coc#list#getc() if c ==# "\" || c ==# "\" "if the short sequence has a valid mapping, return that. if !empty(full_keymap) return full_keymap endif return input endif let input .= c let partial_keymap = mapcheck(input, "l") endwhile return input endfunction 1 0.000003 function! coc#list#prompt_start() abort call timer_start(100, {-> coc#list#start_prompt()}) endfunction 1 0.000001 function! coc#list#start_prompt() if s:activated | return | endif if s:gui && !empty(s:saved_cursor) set guicursor+=a:ver1-CocCursorTransparent/lCursor elseif s:is_vim set t_ve= endif let s:activated = 1 try while s:activated let ch = coc#list#getchar() if ch ==# "\u26d4" break endif if ch ==# "\" || ch ==# "\" || ch ==# "\" continue else call coc#rpc#notify('InputChar', [ch, getcharmod()]) endif endwhile catch /^Vim:Interrupt$/ let s:activated = 0 call coc#rpc#notify('InputChar', ["\"]) return endtry let s:activated = 0 endfunction 1 0.000004 function! coc#list#setlines(lines, append) let total = line('$') if a:append silent call append(line('$'), a:lines) else silent call append(0, a:lines) let n = len(a:lines) + 1 let saved_reg = @" silent execute n.',$d' let @" = saved_reg endif endfunction 1 0.000002 function! coc#list#options(...) let list = ['--top', '--tab', '--normal', '--no-sort', '--input', '--strict', \ '--regex', '--interactive', '--number-select', '--auto-preview'] if get(g:, 'coc_enabled', 0) let names = coc#rpc#request('listNames', []) call extend(list, names) endif return join(list, "\n") endfunction 1 0.000001 function! coc#list#stop_prompt(...) if get(a:, 1, 0) == 0 if s:gui set guicursor+=a:ver1-Cursor/lCursor let &guicursor = s:saved_cursor elseif s:is_vim let &t_ve = s:saved_ve endif endif if s:activated let s:activated = 0 call feedkeys("\u26d4", 'int') endif endfunction 1 0.000003 function! coc#list#status(name) if !exists('b:list_status') | return '' | endif return get(b:list_status, a:name, '') endfunction 1 0.000003 function! coc#list#create(position, height, name, numberSelect) nohlsearch if a:position ==# 'tab' execute 'silent tabe list:///'.a:name else execute 'silent keepalt '.(a:position ==# 'top' ? '' : 'botright').a:height.'sp list:///'.a:name execute 'resize '.a:height endif if a:numberSelect setl number else setl nonumber setl foldcolumn=2 endif return [bufnr('%'), win_getid()] endfunction 1 0.000004 function! coc#list#setup(source) let b:list_status = {} let statusParts = [ \ '%#CocListMode#-- %{get(b:list_status, "mode")} --%*', \ '%{get(g:, "coc_list_loading_status", "")}', \ '%{get(b:list_status, "args", "")}', \ '(%L/%{get(b:list_status, "total", "")})', \ '%=', \ '%#CocListPath# %{get(b:list_status, "cwd", "")} %l/%L%*' \ ] call setwinvar(winnr(), '&statusline', join(statusParts, ' ')) setl buftype=nofile nobuflisted nofen nowrap setl norelativenumber bufhidden=wipe cursorline winfixheight setl tabstop=1 nolist nocursorcolumn setl signcolumn=auto setl filetype=list syntax case ignore let source = a:source[8:] let name = toupper(source[0]).source[1:] execute 'syntax match Coc'.name.'Line /\v^.*$/' nnoremap c endfunction 1 0.000001 function! coc#list#has_preview() for i in range(1, winnr('$')) let preview = getwinvar(i, '&previewwindow') if preview return 1 endif endfor return 0 endfunction 1 0.000039 function! coc#list#restore(winid, height) let res = win_gotoid(a:winid) if res == 0 | return | endif if winnr('$') == 1 return endif execute 'resize '.a:height if s:is_vim redraw endif endfunction 1 0.000004 function! coc#list#set_height(height) abort if winnr('$') == 1| return | endif execute 'resize '.a:height endfunction FUNCTION coc#util#close() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/util.vim line 113 Called 1 time Total time: 0.019781 Self time: 0.003848 count total (s) self (s) 1 0.000011 if exists('*nvim_win_close') if nvim_win_is_valid(a:id) call nvim_win_close(a:id, 1) endif 1 0.000001 else 1 0.000007 let winnr = win_id2win(a:id) 1 0.000003 if winnr > 0 1 0.019744 0.003811 execute winnr.'close!' 1 0.000002 endif 1 0.000001 endif FUNCTION 11_Autocmd() Defined: ~/.vim/plugged/coc.nvim/plugin/coc.vim line 163 Called 8 times Total time: 0.002022 Self time: 0.000312 count total (s) self (s) 8 0.000128 if !get(g:,'coc_workspace_initialized', 0) | return | endif 8 0.001870 0.000160 call coc#rpc#notify('CocAutocmd', a:000) FUNCTION 2() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 43 Called 1 time Total time: 0.000009 Self time: 0.000009 count total (s) self (s) 1 0.000008 execute 'let g:'.a:name.'= a:value' FUNCTION 9() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 75 Called 5 times Total time: 0.023334 Self time: 0.001099 count total (s) self (s) 5 0.000021 let res = [] 30 0.000141 for [key, arglist] in a:calls 25 0.000118 let name = key[5:] 25 0.000029 try 25 0.022727 0.000492 call add(res, call(s:funcs[name], arglist)) catch /.*/ return [res, v:exception] 25 0.000032 endtry 30 0.000042 endfor 5 0.000018 return [res, v:null] FUNCTION coc#rpc#ready() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/rpc.vim line 30 Called 12 times Total time: 0.000303 Self time: 0.000303 count total (s) self (s) 12 0.000192 if empty(s:client) || s:client['running'] == 0 return 0 12 0.000013 endif 12 0.000020 return 1 FUNCTION coc#list#get_chars() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 7 Called 1 time Total time: 0.000188 Self time: 0.000188 count total (s) self (s) 1 0.000185 return { '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '' : "\", '' : "\", '' : "\", '': "\", '': "\", '': "\", '': "\", '': "\", '<2-LeftMouse>': "\<2-LeftMouse>", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\", '': "\",} FUNCTION coc#list#create() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 193 Called 1 time Total time: 0.003668 Self time: 0.000512 count total (s) self (s) 1 0.000002 nohlsearch 1 0.000004 if a:position ==# 'tab' execute 'silent tabe list:///'.a:name 1 0.000001 else 1 0.003604 0.000461 execute 'silent keepalt '.(a:position ==# 'top' ? '' : 'botright').a:height.'sp list:///'.a:name 1 0.000006 execute 'resize '.a:height 1 0.000001 endif 1 0.000001 if a:numberSelect setl number 1 0.000001 else 1 0.000019 0.000007 setl nonumber 1 0.000008 0.000007 setl foldcolumn=2 1 0.000001 endif 1 0.000014 return [bufnr('%'), win_getid()] FUNCTION coc#list#setup() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 210 Called 1 time Total time: 0.001894 Self time: 0.000273 count total (s) self (s) 1 0.000007 let b:list_status = {} 1 0.000006 let statusParts = [ '%#CocListMode#-- %{get(b:list_status, "mode")} --%*', '%{get(g:, "coc_list_loading_status", "")}', '%{get(b:list_status, "args", "")}', '(%L/%{get(b:list_status, "total", "")})', '%=', '%#CocListPath# %{get(b:list_status, "cwd", "")} %l/%L%*' ] 1 0.000070 call setwinvar(winnr(), '&statusline', join(statusParts, ' ')) 1 0.000055 setl buftype=nofile nobuflisted nofen nowrap 1 0.000015 setl norelativenumber bufhidden=wipe cursorline winfixheight 1 0.000013 setl tabstop=1 nolist nocursorcolumn 1 0.000003 setl signcolumn=auto 1 0.001627 0.000006 setl filetype=list 1 0.000009 syntax case ignore 1 0.000004 let source = a:source[8:] 1 0.000013 let name = toupper(source[0]).source[1:] 1 0.000031 execute 'syntax match Coc'.name.'Line /\v^.*$/' 1 0.000035 nnoremap c FUNCTION coc#list#prompt_start() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 118 Called 2 times Total time: 0.000038 Self time: 0.000038 count total (s) self (s) 2 0.000037 call timer_start(100, {-> coc#list#start_prompt()}) FUNCTION 47() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 324 Called 1 time Total time: 0.000036 Self time: 0.000036 count total (s) self (s) 1 0.000012 let lines = getbufline(a:bufnr, 1, '$') 1 0.000004 let start = a:start < 0 ? a:start + 1 : a:start 1 0.000005 let end = a:end < 0 ? a:end + 1 : a:end 1 0.000004 if a:strict && end > len(lines) throw 'line number out of range: '. end 1 0.000001 endif 1 0.000007 return lines[start : end - 1] FUNCTION coc#list#restore() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 243 Called 1 time Total time: 0.000023 Self time: 0.000023 count total (s) self (s) 1 0.000010 let res = win_gotoid(a:winid) 1 0.000005 if res == 0 | return | endif 1 0.000003 if winnr('$') == 1 1 0.000002 return endif execute 'resize '.a:height if s:is_vim redraw endif FUNCTION coc#list#start_prompt() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 122 Called 2 times Total time: 0.001494 Self time: 0.000361 count total (s) self (s) 2 0.000013 if s:activated | return | endif 1 0.000003 if s:gui && !empty(s:saved_cursor) set guicursor+=a:ver1-CocCursorTransparent/lCursor 1 0.000001 elseif s:is_vim 1 0.000041 0.000039 set t_ve= 1 0.000002 endif 1 0.000004 let s:activated = 1 1 0.000001 try 3 0.000008 while s:activated 3 0.123981 0.123691 let ch = coc#list#getchar() 3 0.000024 if ch ==# "\u26d4" 1 0.000002 break 2 0.000002 endif 2 0.000042 if ch ==# "\" || ch ==# "\" || ch ==# "\" 1 0.000002 continue 1 0.000001 else 1 0.000361 0.000071 call coc#rpc#notify('InputChar', [ch, getcharmod()]) 1 0.000001 endif 2 0.000007 endwhile catch /^Vim:Interrupt$/ let s:activated = 0 call coc#rpc#notify('InputChar', ["\"]) return 1 0.000002 endtry 1 0.000003 let s:activated = 0 FUNCTION 9_SynSet() Defined: /usr/share/vim/vim81/syntax/synload.vim line 33 Called 1 time Total time: 0.000230 Self time: 0.000230 count total (s) self (s) " clear syntax for :set syntax=OFF and any syntax name that doesn't exist 1 0.000022 syn clear 1 0.000020 if exists("b:current_syntax") unlet b:current_syntax 1 0.000001 endif 1 0.000009 let s = expand("") 1 0.000003 if s == "ON" " :set syntax=ON if &filetype == "" echohl ErrorMsg echo "filetype unknown" echohl None endif let s = &filetype 1 0.000001 elseif s == "OFF" let s = "" 1 0.000001 endif 1 0.000001 if s != "" " Load the syntax file(s). When there are several, separated by dots, " load each in sequence. 2 0.000010 for name in split(s, '\.') 1 0.000141 exe "runtime! syntax/" . name . ".vim syntax/" . name . "/*.vim" 2 0.000003 endfor 1 0.000001 endif FUNCTION 19_Highlight_Matching_Pair() Defined: /usr/share/vim/vim81/plugin/matchparen.vim line 39 Called 2 times Total time: 0.000418 Self time: 0.000418 count total (s) self (s) " Remove any previous match. 2 0.000029 if exists('w:paren_hl_on') && w:paren_hl_on silent! call matchdelete(3) let w:paren_hl_on = 0 2 0.000002 endif " Avoid that we remove the popup menu. " Return when there are no colors (looks like the cursor jumps). 2 0.000016 if pumvisible() || (&t_Co < 8 && !has("gui_running")) return 2 0.000002 endif " Get the character under the cursor and check if it's in 'matchpairs'. 2 0.000010 let c_lnum = line('.') 2 0.000006 let c_col = col('.') 2 0.000004 let before = 0 2 0.000031 let text = getline(c_lnum) 2 0.000082 let matches = matchlist(text, '\(.\)\=\%'.c_col.'c\(.\=\)') 2 0.000009 if empty(matches) let [c_before, c] = ['', ''] 2 0.000002 else 2 0.000014 let [c_before, c] = matches[1:2] 2 0.000002 endif 2 0.000102 let plist = split(&matchpairs, '.\zs[:,]') 2 0.000012 let i = index(plist, c) 2 0.000005 if i < 0 " not found, in Insert mode try character before the cursor 2 0.000008 if c_col > 1 && (mode() == 'i' || mode() == 'R') let before = strlen(c_before) let c = c_before let i = index(plist, c) 2 0.000002 endif 2 0.000003 if i < 0 " not found, nothing to do 2 0.000004 return endif endif " Figure out the arguments for searchpairpos(). if i % 2 == 0 let s_flags = 'nW' let c2 = plist[i + 1] else let s_flags = 'nbW' let c2 = c let c = plist[i - 1] endif if c == '[' let c = '\[' let c2 = '\]' endif " Find the match. When it was just before the cursor move it there for a " moment. 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) endif if !has("syntax") || !exists("g:syntax_on") let s_skip = "0" 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. let s_skip = '!empty(filter(map(synstack(line("."), col(".")), ''synIDattr(v:val, "name")''), ' . '''v:val =~? "string\\|character\\|singlequote\\|escape\\|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'. try 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 endtry endif " Limit the search to lines visible in the window. let stoplinebottom = line('w$') let stoplinetop = line('w0') if i % 2 == 0 let stopline = stoplinebottom else let stopline = stoplinetop endif " Limit the search time to 300 msec to avoid a hang on very long lines. " This fails when a timeout is not supported. if mode() == 'i' || mode() == 'R' let timeout = exists("b:matchparen_insert_timeout") ? b:matchparen_insert_timeout : g:matchparen_insert_timeout else let timeout = exists("b:matchparen_timeout") ? b:matchparen_timeout : g:matchparen_timeout endif try 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) endtry if before > 0 if has_getcurpos call setpos('.', save_cursor) else call winrestview(save_cursor) endif endif " If a match is found setup match highlighting. if m_lnum > 0 && m_lnum >= stoplinetop && m_lnum <= stoplinebottom if exists('*matchaddpos') 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\)/' endif let w:paren_hl_on = 1 endif FUNCTION 20_LocalBrowse() Defined: /usr/share/vim/vim81/plugin/netrwPlugin.vim line 102 Called 2 times Total time: 0.000155 Self time: 0.000155 count total (s) self (s) " Unfortunate interaction -- only DechoMsg debugging calls can be safely used here. " Otherwise, the BufEnter event gets triggered when attempts to write to " the DBG buffer are made. 2 0.000015 if !exists("s:vimentered") " If s:vimentered doesn't exist, then the VimEnter event hasn't fired. It will, " and so s:VimEnter() will then be calling this routine, but this time with s:vimentered defined. " call Dfunc("s:LocalBrowse(dirname<".a:dirname.">) (s:vimentered doesn't exist)") " call Dret("s:LocalBrowse") return 2 0.000001 endif " call Dfunc("s:LocalBrowse(dirname<".a:dirname.">) (s:vimentered=".s:vimentered.")") 2 0.000019 if has("amiga") " The check against '' is made for the Amiga, where the empty " string is the current directory and not checking would break " things such as the help command. " call Decho("(LocalBrowse) dirname<".a:dirname."> (isdirectory, amiga)") if a:dirname != '' && isdirectory(a:dirname) sil! call netrw#LocalBrowseCheck(a:dirname) if exists("w:netrw_bannercnt") && line('.') < w:netrw_bannercnt exe w:netrw_bannercnt endif endif 2 0.000016 elseif isdirectory(a:dirname) " call Decho("(LocalBrowse) dirname<".a:dirname."> ft=".&ft." (isdirectory, not amiga)") " call Dredir("LocalBrowse ft last set: ","verbose set ft") " call Decho("(s:LocalBrowse) COMBAK#23: buf#".bufnr("%")." file<".expand("%")."> line#".line(".")." col#".col(".")) sil! call netrw#LocalBrowseCheck(a:dirname) " call Decho("(s:LocalBrowse) COMBAK#24: buf#".bufnr("%")." file<".expand("%")."> line#".line(".")." col#".col(".")) if exists("w:netrw_bannercnt") && line('.') < w:netrw_bannercnt exe w:netrw_bannercnt " call Decho("(s:LocalBrowse) COMBAK#25: buf#".bufnr("%")." file<".expand("%")."> line#".line(".")." col#".col(".")) endif 2 0.000002 else " not a directory, ignore it " call Decho("(LocalBrowse) dirname<".a:dirname."> not a directory, ignoring...") 2 0.000002 endif " call Decho("(s:LocalBrowse) COMBAK#26: buf#".bufnr("%")." file<".expand("%")."> line#".line(".")." col#".col(".")) " call Dret("s:LocalBrowse") FUNCTION coc#util#do_autocmd() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/util.vim line 754 Called 1 time Total time: 0.000024 Self time: 0.000024 count total (s) self (s) 1 0.000019 if exists('#User#'.a:name) exe 'doautocmd User '.a:name 1 0.000001 endif FUNCTION 51() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 400 Called 1 time Total time: 0.000018 Self time: 0.000018 count total (s) self (s) 1 0.000009 if !bufloaded(a:bufnr) | return | endif 1 0.000008 call setbufvar(a:bufnr, a:name, a:val) FUNCTION 57() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 431 Called 1 time Total time: 0.000026 Self time: 0.000026 count total (s) self (s) 1 0.000024 return winheight(a:win_id) FUNCTION 11_SyncAutocmd() Defined: ~/.vim/plugged/coc.nvim/plugin/coc.vim line 168 Called 2 times Total time: 0.027566 Self time: 0.000127 count total (s) self (s) 2 0.000053 if !get(g:,'coc_workspace_initialized', 0) | return | endif 2 0.000009 if get(g:, 'coc_service_initialized', 0) 2 0.027489 0.000050 call coc#rpc#request('CocAutocmd', a:000) else call coc#rpc#notify('CocAutocmd', a:000) 2 0.000001 endif FUNCTION coc#util#set_buf_var() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/util.vim line 906 Called 1 time Total time: 0.000041 Self time: 0.000041 count total (s) self (s) 1 0.000011 if !bufloaded(a:bufnr) | return | endif 1 0.000028 call setbufvar(a:bufnr, a:name, a:val) FUNCTION 69() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 509 Called 1 time Total time: 0.000050 Self time: 0.000050 count total (s) self (s) 1 0.000011 let winnr = win_id2win(a:win_id) 1 0.000003 if winnr != 0 1 0.000005 let [line, col] = a:pos 1 0.000004 let curr = winnr() 1 0.000003 if winnr == curr 1 0.000009 call cursor(line, col + 1) else execute winnr.'wincmd w' call cursor(line, col + 1) execute curr.'wincmd w' 1 0.000001 endif 1 0.000001 endif FUNCTION 14_notify() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/client.vim line 133 Called 10 times Total time: 0.001587 Self time: 0.001479 count total (s) self (s) 10 0.000469 0.000361 let channel = s:get_channel(self) 10 0.000072 if empty(channel) | return '' | endif 10 0.000040 try 10 0.000016 if s:is_vim 10 0.000494 call ch_sendraw(channel, json_encode([0, [a:method, a:args]])."\n") else call call('rpcnotify', [channel, a:method] + a:args) 10 0.000010 endif catch /.*/ if v:exception =~# 'E475' if get(g:, 'coc_vim_leaving', 0) | return | endif echohl Error | echom '['.self.name.'] server connection lost' | echohl None let name = self.name call s:on_exit(name, 0) execute 'silent do User ConnectionLost'.toupper(name[0]).name[1:] elseif v:exception =~# 'E12' " neovim's bug, ignore it else echohl Error | echo 'Error on notify ('.a:method.'): '.v:exception | echohl None endif 10 0.000015 endtry FUNCTION 7_LoadIndent() Defined: /usr/share/vim/vim81/indent.vim line 13 Called 1 time Total time: 0.000119 Self time: 0.000119 count total (s) self (s) 1 0.000006 if exists("b:undo_indent") exe b:undo_indent unlet! b:undo_indent b:did_indent 1 0.000001 endif 1 0.000004 let s = expand("") 1 0.000002 if s != "" 1 0.000003 if exists("b:did_indent") unlet b:did_indent 1 0.000000 endif " When there is a dot it is used to separate filetype names. Thus for " "aaa.bbb" load "indent/aaa.vim" and then "indent/bbb.vim". 2 0.000009 for name in split(s, '\.') 1 0.000075 exe 'runtime! indent/' . name . '.vim' 2 0.000004 endfor 1 0.000001 endif FUNCTION coc#util#clearmatches() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/util.vim line 665 Called 5 times Total time: 0.000284 Self time: 0.000284 count total (s) self (s) 5 0.000077 let winid = get(a:, 1, 0) 5 0.000026 if winid != 0 && win_getid() != winid return 5 0.000008 endif 5 0.000020 for id in a:ids try call matchdelete(id) catch /.*/ " matches have been cleared in other ways, endtry 5 0.000009 endfor 5 0.000027 let exists = get(w:, 'coc_matchids', []) 5 0.000019 if !empty(exists) call filter(w:coc_matchids, 'index(a:ids, v:val) == -1') 5 0.000005 endif FUNCTION coc#list#stop_prompt() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 173 Called 2 times Total time: 0.000177 Self time: 0.000173 count total (s) self (s) 2 0.000032 if get(a:, 1, 0) == 0 2 0.000006 if s:gui set guicursor+=a:ver1-Cursor/lCursor let &guicursor = s:saved_cursor 2 0.000004 elseif s:is_vim 2 0.000079 0.000075 let &t_ve = s:saved_ve 2 0.000003 endif 2 0.000003 endif 2 0.000005 if s:activated 1 0.000003 let s:activated = 0 1 0.000009 call feedkeys("\u26d4", 'int') 2 0.000003 endif FUNCTION coc#list#setlines() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 150 Called 1 time Total time: 0.001111 Self time: 0.001111 count total (s) self (s) 1 0.000849 let total = line('$') 1 0.000007 if a:append silent call append(line('$'), a:lines) 1 0.000021 else 1 0.000120 silent call append(0, a:lines) 1 0.000012 let n = len(a:lines) + 1 1 0.000022 let saved_reg = @" 1 0.000048 silent execute n.',$d' 1 0.000016 let @" = saved_reg 1 0.000001 endif FUNCTION coc#api#call() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 577 Called 13 times Total time: 0.029264 Self time: 0.000748 count total (s) self (s) 13 0.000178 let err = v:null 13 0.000027 let res = v:null 13 0.000020 try 13 0.012455 0.004524 let res = call(s:funcs[a:method], a:args) catch /.*/ let err = v:exception 13 0.000016 endtry 13 0.000035 return [err, res] FUNCTION coc#list#getc() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 85 Called 3 times Total time: 0.000720 Self time: 0.000147 count total (s) self (s) 3 0.000615 0.000082 let c = getchar() 3 0.000095 return type(c) == type(0) ? nr2char(c) : c FUNCTION 13_variables() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/util.vim line 314 Called 1 time Total time: 0.000060 Self time: 0.000060 count total (s) self (s) 1 0.000017 let info = getbufinfo({'bufnr':a:bufnr, 'variables': 1}) 1 0.000007 let variables = copy(info[0]['variables']) 2 0.000007 for key in keys(variables) 1 0.000008 if key !~# '\v^coc' 1 0.000003 unlet variables[key] 1 0.000000 endif 2 0.000002 endfor 1 0.000002 return variables FUNCTION coc#api#notify() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 588 Called 9 times Total time: 0.001421 Self time: 0.000230 count total (s) self (s) 9 0.001404 0.000213 call call(s:funcs[a:method], a:args) FUNCTION 14_request() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/client.vim line 101 Called 2 times Total time: 0.027305 Self time: 0.026354 count total (s) self (s) 2 0.000104 0.000087 let channel = s:get_channel(self) 2 0.000011 if empty(channel) | return '' | endif 2 0.000004 try 2 0.000003 if s:is_vim 2 0.027017 0.026083 let res = ch_evalexpr(channel, [a:method, a:args], {'timeout': 30000}) 2 0.000024 if type(res) == 1 && res ==# '' throw 'timeout after 30s' 2 0.000003 endif 2 0.000011 let [l:errmsg, res] = res 2 0.000009 if !empty(l:errmsg) throw l:errmsg 2 0.000002 else 2 0.000007 return res endif endif return call('rpcrequest', [channel, a:method] + a:args) catch /.*/ if v:exception =~# 'E475' if get(g:, 'coc_vim_leaving', 0) | return | endif echohl Error | echom '['.self.name.'] server connection lost' | echohl None let name = self.name call s:on_exit(name, 0) execute 'silent do User ConnectionLost'.toupper(name[0]).name[1:] elseif v:exception =~# 'E12' " neovim's bug, ignore it else echohl Error | echo 'Error on request ('.a:method.'): '.v:exception | echohl None endif 2 0.000004 endtry FUNCTION coc#rpc#notify() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/rpc.vim line 98 Called 10 times Total time: 0.002510 Self time: 0.000649 count total (s) self (s) 10 0.000562 0.000288 if !coc#rpc#ready() return '' 10 0.000010 endif 10 0.001878 0.000291 call s:client['notify'](a:method, a:args) 10 0.000020 return '' FUNCTION coc#rpc#request() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/rpc.vim line 91 Called 2 times Total time: 0.027439 Self time: 0.000105 count total (s) self (s) 2 0.000069 0.000040 if !coc#rpc#ready() return '' 2 0.000002 endif 2 0.027363 0.000058 return s:client['request'](a:method, a:args) FUNCTION 14_get_channel() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/client.vim line 94 Called 12 times Total time: 0.000125 Self time: 0.000125 count total (s) self (s) 12 0.000056 if s:is_vim 12 0.000048 return a:client['channel'] endif return a:client['chan_id'] FUNCTION coc#list#set_height() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 255 Called 1 time Total time: 0.000034 Self time: 0.000034 count total (s) self (s) 1 0.000024 if winnr('$') == 1| return | endif 1 0.000010 execute 'resize '.a:height FUNCTION 6_LoadFTPlugin() Defined: /usr/share/vim/vim81/ftplugin.vim line 14 Called 1 time Total time: 0.000874 Self time: 0.000874 count total (s) self (s) 1 0.000015 if exists("b:undo_ftplugin") exe b:undo_ftplugin unlet! b:undo_ftplugin b:did_ftplugin 1 0.000002 endif 1 0.000015 let s = expand("") 1 0.000004 if s != "" 1 0.000023 if &cpo =~# "S" && exists("b:did_ftplugin") " In compatible mode options are reset to the global values, need to " set the local values also when a plugin was already used. unlet b:did_ftplugin 1 0.000001 endif " When there is a dot it is used to separate filetype names. Thus for " "aaa.bbb" load "aaa" and then "bbb". 2 0.000010 for name in split(s, '\.') 1 0.000777 exe 'runtime! ftplugin/' . name . '.vim ftplugin/' . name . '_*.vim ftplugin/' . name . '/*.vim' 2 0.000004 endfor 1 0.000001 endif FUNCTION coc#rpc#stop() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/rpc.vim line 59 Called 1 time Total time: 0.000080 Self time: 0.000080 count total (s) self (s) 1 0.000010 if empty(s:client) return 1 0.000001 endif 1 0.000002 try 1 0.000002 if s:is_vim 1 0.000047 call job_stop(ch_getjob(s:client['channel']), 'term') else call jobstop(s:client['chan_id']) 1 0.000001 endif catch /.*/ " ignore 1 0.000002 endtry FUNCTION coc#util#get_bufoptions() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/util.vim line 299 Called 1 time Total time: 0.000145 Self time: 0.000085 count total (s) self (s) 1 0.000010 if !bufloaded(a:bufnr) | return v:null | endif 1 0.000005 let bufname = bufname(a:bufnr) 1 0.000127 0.000067 return { 'bufname': bufname, 'eol': getbufvar(a:bufnr, '&eol'), 'variables': s:variables(a:bufnr), 'fullpath': empty(bufname) ? '' : fnamemodify(bufname, ':p'), 'buftype': getbufvar(a:bufnr, '&buftype'), 'filetype': getbufvar(a:bufnr, '&filetype'), 'iskeyword': getbufvar(a:bufnr, '&iskeyword'), 'changedtick': getbufvar(a:bufnr, 'changedtick'),} FUNCTION coc#list#getchar() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/list.vim line 90 Called 3 times Total time: 0.000843 Self time: 0.000123 count total (s) self (s) 3 0.000808 0.000088 let input = coc#list#getc() 3 0.000018 if 1 != &iminsert 3 0.000010 return input endif "a language keymap is activated, so input must be resolved to the mapped values. let partial_keymap = mapcheck(input, "l") while partial_keymap !=# "" let full_keymap = maparg(input, "l") if full_keymap ==# "" && len(input) >= 3 "HACK: assume there are no keymaps longer than 3. return input elseif full_keymap ==# partial_keymap return full_keymap endif let c = coc#list#getc() if c ==# "\" || c ==# "\" "if the short sequence has a valid mapping, return that. if !empty(full_keymap) return full_keymap endif return input endif let input .= c let partial_keymap = mapcheck(input, "l") endwhile return input FUNCTION 27_execute() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 29 Called 8 times Total time: 0.012261 Self time: 0.012261 count total (s) self (s) 8 0.000094 if a:cmd =~# '^echo' 4 0.006928 execute a:cmd 4 0.000005 else 4 0.005135 silent! execute a:cmd 8 0.000016 endif FUNCTION 13() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 97 Called 19 times Total time: 0.027569 Self time: 0.001313 count total (s) self (s) 19 0.012762 0.006337 return call(a:method, a:args) FUNCTION 15() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 105 Called 14 times Total time: 0.000857 Self time: 0.000853 count total (s) self (s) " command that could cause cursor vanish 14 0.000505 if a:command =~# '^echo' || a:command =~# '^redraw' || a:command =~# '^sign place' 8 0.000115 call timer_start(0, {-> s:execute(a:command)}) 6 0.000006 else 6 0.000095 0.000091 execute a:command 14 0.000014 endif FUNCTION 16() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 114 Called 1 time Total time: 0.000027 Self time: 0.000027 count total (s) self (s) 1 0.000026 return eval(a:expr) FUNCTION 29() Defined: ~/.vim/plugged/coc.nvim/autoload/coc/api.vim line 167 Called 1 time Total time: 0.000016 Self time: 0.000016 count total (s) self (s) 1 0.000016 return win_getid() FUNCTIONS SORTED ON TOTAL TIME count total (s) self (s) function 13 0.029264 0.000748 coc#api#call() 19 0.027569 0.001313 13() 2 0.027566 0.000127 11_SyncAutocmd() 2 0.027439 0.000105 coc#rpc#request() 2 0.027305 0.026354 14_request() 5 0.023334 0.001099 9() 1 0.019781 0.003848 coc#util#close() 8 0.012261 27_execute() 1 0.003668 0.000512 coc#list#create() 10 0.002510 0.000649 coc#rpc#notify() 8 0.002022 0.000312 11_Autocmd() 1 0.001894 0.000273 coc#list#setup() 10 0.001587 0.001479 14_notify() 2 0.001494 0.000361 coc#list#start_prompt() 9 0.001421 0.000230 coc#api#notify() 1 0.001111 coc#list#setlines() 1 0.000874 6_LoadFTPlugin() 14 0.000857 0.000853 15() 3 0.000843 0.000123 coc#list#getchar() 3 0.000720 0.000147 coc#list#getc() FUNCTIONS SORTED ON SELF TIME count total (s) self (s) function 2 0.027305 0.026354 14_request() 8 0.012261 27_execute() 1 0.019781 0.003848 coc#util#close() 10 0.001587 0.001479 14_notify() 19 0.027569 0.001313 13() 1 0.001111 coc#list#setlines() 5 0.023334 0.001099 9() 1 0.000874 6_LoadFTPlugin() 14 0.000857 0.000853 15() 13 0.029264 0.000748 coc#api#call() 10 0.002510 0.000649 coc#rpc#notify() 1 0.003668 0.000512 coc#list#create() 2 0.000418 19_Highlight_Matching_Pair() 2 0.001494 0.000361 coc#list#start_prompt() 8 0.002022 0.000312 11_Autocmd() 12 0.000303 coc#rpc#ready() 5 0.000284 coc#util#clearmatches() 1 0.001894 0.000273 coc#list#setup() 9 0.001421 0.000230 coc#api#notify() 1 0.000230 9_SynSet()