diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-07-26 21:26:34 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-07-26 21:26:34 +0200 |
commit | 7b73d7ebf71c9148c90a500116f25ec2314c7273 (patch) | |
tree | 1138f7122f2bb85454e2bdef9d9edfde06e4e6d4 /src/proto/hashtab.pro | |
parent | 9d5ffceb3fea247a88d4d3936e97b7f488aab6ff (diff) |
patch 8.1.1752: resizing hashtable is inefficientv8.1.1752
Problem: Resizing hashtable is inefficient.
Solution: Avoid resizing when the final size is predictable.
Diffstat (limited to 'src/proto/hashtab.pro')
-rw-r--r-- | src/proto/hashtab.pro | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/proto/hashtab.pro b/src/proto/hashtab.pro index 96907147d1..21794ed6fd 100644 --- a/src/proto/hashtab.pro +++ b/src/proto/hashtab.pro @@ -9,6 +9,7 @@ int hash_add(hashtab_T *ht, char_u *key); int hash_add_item(hashtab_T *ht, hashitem_T *hi, char_u *key, hash_T hash); void hash_remove(hashtab_T *ht, hashitem_T *hi); void hash_lock(hashtab_T *ht); +void hash_lock_size(hashtab_T *ht, int size); void hash_unlock(hashtab_T *ht); hash_T hash_hash(char_u *key); /* vim: set ft=c : */ |