Skip to content

Long startup times #2617

@mattia-marini

Description

@mattia-marini

Description

Hi! Newbie question right here. First of all thank you for developing such a beautiful plugin for free!

I was wondering if there was any way to reduce startup times. I know you are not supposed to lazy load the plugin, but even on rather small files (~500 lines), vimtex seems to add about 150-200 milliseconds to startup times.

The lag persist even with only vimtex installed with everything on default configuration. I also tried disabling every feature I could to see if that could lead to any improvement but it still seemed too slow for me (I attached the file of that configuration).

My last resort was trying to manually copy/paste the parts I strongly need (so basically the context detection and the compile module) and create a "light version" of the plugin. That has been possible for the former option, but not for the latter, as the compiler module seems to be more articulated.

P.s. I have read through the "high level documentation" of the plugin, but i would love to take a deeper dive to learn a bit more. Is there any other more detailed doc available to public?
P.p.s. This is my first issue on GitHub and my English is ass, so if I did something wrong let me know ;)

Steps to reproduce

let g:vimtex_view_method = 'skim'
let g:vimtex_view_skim_sync = 1
let g:vimtex_view_skim_activate = 0
let g:vimtex_indent_enabled = 0
let g:vimtex_quickfix_mode=1

let g:vimtex_quickfix_ignore_filters = [
      \ 'Underfull',
      \ 'Overfull',
      \ 'Warning',
      \]

let g:vimtex_quickfix_open_on_warning = 0

let g:vimtex_matchparen_enabled = 0
let g:vimtex_fold_enabled = 0 
let g:vimtex_complete_recursive_bib=0
let g:vimtex_syntax_enabled = 0
let g:vimtex_toc_enabled = 0
let g:vimtex_matchparen_enabled =0
let g:vimtex_motion_enabled = 0
"let g:vimtex_quickfix_enabled = 0
let g:vimtex_text_obj_enabled =0
"let g:vimtex_view_enabled = 0
let g:vimtex_complete_enable = 0
let g:vimtex_fold_bib_enabled = 0
let g:vimtex_indent_enabled = 0
let g:vimtex_indent_bib_enabled = 0
let g:vimtex_doc_enabled = 0
let g:vimtex_include_search_enabled = 0
let g:vimtex_viewer_check = 0

Expected behavior

No response

Actual behavior

No response

Do you use a latexmkrc file?

No

VimtexInfo

System info:
  OS: Mac OS X 10.15.7 (19H15)
  Vim version: NVIM v0.8.2
  Has clientserver: true
  Servername: /var/folders/1p/0hs20_dj0kv566xzkq3tt6cw0000gn/T/nvim.mattia/CZ2Xw3/nvim.3538.0

VimTeX project: Analisi_1
  base: Analisi_1.tex
  root: /Users/mattia/Library/Mobile Documents/com~apple~CloudDocs/LatexWorkspace/Analisi_1
  tex: /Users/mattia/Library/Mobile Documents/com~apple~CloudDocs/LatexWorkspace/Analisi_1/Analisi_1.tex
  main parser: current file verified
  document class: article
  packages: amsbsy amsfonts amsgen amsmath amsopn amssymb amstext array atbegshi atbegshi-ltx atveryend atveryend-ltx auxhook babel bigintcalc bitset calc elocalloc environ epstopdf-base etexcmds etoolbox expl3 float forest geometry gettitlestring graphics graphicx hycolor hyperref iftex ifvtex infwarerr inlinedef inputenc intcalc keyval kvdefinekeys kvoptions kvsetkeys letltxmacro listings lstmisc ltxcmds mathrsfs mathtools mhsetup nameref pdfescape pdftexcmds pgf pgf-pie pgfcomp-version-0-65 pgfcomp-version-1-18 pgfcore pgffor pgfkeys pgfmath pgfopts pgfplots pgfrcs pgfsys refcount rerunfilecheck scalefnt soul soulutf8 tabularx tikz tocloft trig trimspaces uniquecounter url xcolor xparse
  source files:
    Analisi_1.tex
    ../.preamble.tex
    Sections/1.tex
    Sections/2.tex
    Sections/3.tex
    Images/Riemann.pdf_tex
  compiler: latexmk
    engine: -pdf
    options:
      -verbose
      -file-line-error
      -synctex=1
      -interaction=nonstopmode
    callback: 1
    continuous: 1
    executable: latexmk
  viewer: Skim
  qf method: LaTeX logfile

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions