Wednesday, May 24, 2017

Re: Vim startup profiling

> Ok I save 100ms using the plugin manager vim-plug but not enough for me.
> Is anyone can advise me or explain to me why some files are loaded twice and take twice or more times N msec:
> - vim80/menu.vim
> - vim80\filetype.vim

I never compared vimplug vs VAM, but I'd be interested in it.
AFAIK parsing commands such as Plug takes time, you may want to lookup
its definition and call that code in .vimrc instead - maybe it saves you 1 ms.


VAM is only 770 lines - because we split the 'everyday runtime code' and
the 'update/install' code. This eventually could be done for VimPlug as
well.

If you want to give VAM a try you can create dictionaries like this:

{'filetype_regex': '\%(rb)$', 'names': ['vim-ruby', 'vim-addon-rdebug', 'vim-addon-ruby-debug-ide', 'textobj-rubyblock' ]}
{'name': 'matchit.zip'}

and write such a file and load by

call vam#Scripts(expand('~/.vim-scripts'), {})

github:repo/name can be used as names.

I don't say use VAM, but it could shed some light into whether you can be
faster and wheter VimPlug can be improved. It has features VAM does not
have - such as fixing version.

VAM has had an experimental mode 'merging all plugin/*' files into one
to seed things up - but its likely to break code such as did_load or
similar.

See vam#install#MergePluginFiles( ..

But as far as I remember I stopped using it myself even before switching
to SSD / getting a faster machine.

Marc Weber

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments: