Dominique Pelle wrote:

> Attached patch speeds up function ga_grow() by
> using realloc() instead of freeing and allocating
> a new block when growing an array.  It should also
> reduce memory usage.
> 
> Vim is 25% faster after patch with this test case:
> 
> $ wget http://dominique.pelle.free.fr/speed-join.vim.gz
> $ gzip -d speed-join.vim.gz
> 
> $ time vim -u NONE -S speed-join.vim
> 
> 3 measurements with vim-7.3.444 _before_ patch:
> 
>   22.252 sec
>   23.094 sec
>   22.748 sec
> 
> 3 measurements with vim-7.3.444 _after_ patch:
> 
>   16.509 sec
>   16.342 sec
>   16.077 sec
> 
> That's ~25% faster.
> 
> ga_grow() is used for many things in Vim
> so there might be other things that are also faster.

Thanks.  I'll check out the details soon.

-- 
"I simultaneously try to keep my head in the clouds and my feet on the
ground.  Sometimes it's a stretch, though."              -- Larry Wall

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
You received this message from the "vim_dev" 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

Raspunde prin e-mail lui