2009/6/14 Dominique Pellé <[email protected]> > > Cháo wrote: > > Thanks Dominique for the suggestions. One thing I overlooked was to set > > nowritebackup, I thought set nobackup was all the backup. So this shaved > a > > couple of seconds off! > > Ok, I totally forgot to use the trusted tools from sysInternals! Strace > > should be nice, but not familiar with it and it captures lots of extra > info > > like mouse movement or what not, so I used File Monitor from sysinternal > and > > I see the difference now between Notepad and GVim. > > I've attached the comparisons in a zip files with 2 formats for those > > without Excel :) > > First up was Notepad - about 2 seconds time to save: it's pretty quick, > it > > just writes and done. But I was wondering why it WRITE in huge chunk > size > > of 133125 and then query stuff and the do some more WRITE operations in > > chuck size of 65536. OH well. It looks like Notepad writes in bigger > > chunks (65536) than gvim. > > 2nd is gvim with a file on the root of a mapped drive - about 3 seconds. > In > > this situation it's mirrors Notepad very close, but gvim queries the heck > > out the file before the WRITE op. > > > > And finally, the 3rd and true problem case, gvim with a file that's deep > in > > the directory structures - about 10 seconds!! Now with FileMon tool, I > can > > see that most of the time it's spending on querying info about the nested > > directories! I've highlighted them in red and also repeated queries of > the > > same directory structures in GREEN background. Lots of traversing the > > network shared drive and all its subdirectories - each time taking about > 2-3 > > seconds! The actual WRITE data is using 8192 chuck size and not bad > > performance - about 2 seconds - guess could speed up a bit more by > allowing > > it to save bigger chunks of data at once like Notepad. So final thought > is > > that GVIM tries to make sure everything is in order before anything > happens? > > Is there an option to disable the traversing from the root of the drive > to > > each of the subdirs when saving a file? If not, I might have to compile > > myself a copy with some changes. > > Go VIM! > > Thanks again, > > Cháo > > > Thanks for the detailed report. That rings a bell now. Take a look > at this thread from January: > > > http://groups.google.com/group/vim_use/browse_thread/thread/ced1795b324d1b4e?pli=1 > > It looks similar to what you're experiencing. > > User reported in above thread said that with 'set noshellslash' then > accessing //computer/c$/test.txt is fast (see :help shellslash) > > Can you confirm whether it also helps in your case? > > Cheers > > PS: (reminder) in this mailing list, the convention is to bottom post > i.e. reply below the original message rather than above it. > > -- Dominique > > > > Thanks for the tip about posting reply at the bottom - it's gmail that's being funny plus I always did that :) So I also emailed another one to vim_dev list aboout slowness when switch buffers of network mapped files and it seems that's related to writing/saving such files as well. And Bram was quick to point out the following:
This is probably caused by the code that figures out the full path name on Unix. This is required to avoid any trouble with symbolic links. Especially editing the same file under different names. Your directory is actually on a network share that doesn't support symbolic links. But that's very difficult to detect. I'm not sure if there is any way to avoid this without compromising reliability. Perhaps the expansion can be postponed or done in the background. That would make it more complex. That "shellslash" didn't work for me. I think in the thread that you sent, they were also working at close to the root of the drive, so performance wasn't as bad. This all subdirs traversing business is causing slowness in proportion to the number of subdirs for a file. I use vimSession to load my "project" from the network mapped drive and it took about 2 mins to finish loading 13 files!!! So I am hoping a way to disable this behavior of visiting each subdir when doing anything to a network mapped drive file. Thanks, -- Cháo Groucho Marx <http://www.brainyquote.com/quotes/authors/g/groucho_marx.html> - "I was married by a judge. I should have asked for a jury." --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
