diff options
| author | Mattias EngdegÄrd | 2023-11-21 12:27:42 +0100 |
|---|---|---|
| committer | Mattias EngdegÄrd | 2024-01-13 20:50:38 +0100 |
| commit | 3b00255a4c70bc1075446c94a8ff65c987ac143f (patch) | |
| tree | c47f8d591ac87bdd1f8ca70c74d5aa11b6ac136c /src/coding.h | |
| parent | a3ae5653cfe1ab2b3eb4c77ce729844ad442b562 (diff) | |
| download | emacs-3b00255a4c70bc1075446c94a8ff65c987ac143f.tar.gz emacs-3b00255a4c70bc1075446c94a8ff65c987ac143f.zip | |
Inlined and specialised hash table look-up
This improves performance in several ways. Separate functions are
used depending on whether the caller has a hash value computed or not.
* src/fns.c (hash_lookup_with_hash, hash_lookup_get_hash): New.
(hash_lookup): Remove hash return argument.
All callers adapted.
hash_lookup_with_hash hash_hash_t arg
Diffstat (limited to 'src/coding.h')
| -rw-r--r-- | src/coding.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/coding.h b/src/coding.h index e9b72403c6b..9beb4350bbf 100644 --- a/src/coding.h +++ b/src/coding.h | |||
| @@ -194,7 +194,7 @@ enum coding_attr_index | |||
| 194 | 194 | ||
| 195 | #define CODING_SYSTEM_ID(coding_system_symbol) \ | 195 | #define CODING_SYSTEM_ID(coding_system_symbol) \ |
| 196 | hash_lookup (XHASH_TABLE (Vcoding_system_hash_table), \ | 196 | hash_lookup (XHASH_TABLE (Vcoding_system_hash_table), \ |
| 197 | coding_system_symbol, NULL) | 197 | coding_system_symbol) |
| 198 | 198 | ||
| 199 | /* Return true if CODING_SYSTEM_SYMBOL is a coding system. */ | 199 | /* Return true if CODING_SYSTEM_SYMBOL is a coding system. */ |
| 200 | 200 | ||