diff options
author | David Blaikie <dblaikie@gmail.com> | 2023-12-11 23:51:51 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2023-12-12 00:07:08 +0000 |
commit | 2e197602305be18b963928e6ae024a004a95af6d (patch) | |
tree | 97e71672e72e423947b8aa7a1fc6e93a237611ad /llvm/lib/Object/COFFObjectFile.cpp | |
parent | 67c631d283fc96d652304199cd625be426b98f8e (diff) | |
download | llvm-2e197602305be18b963928e6ae024a004a95af6d.zip llvm-2e197602305be18b963928e6ae024a004a95af6d.tar.gz llvm-2e197602305be18b963928e6ae024a004a95af6d.tar.bz2 |
lldb: Cache string hash during ConstString pool queries/insertions
lldb was rehashing the string 3 times (once to determine which StringMap
to use, once to query the StringMap, once to insert) on insertion (twice
on successful lookup).
This patch allows the lldb to benefit from hash improvements in LLVM
(from djbHash to xxh3).
Though further changes would be needed to cache this value to disk - we
shouldn't rely on the StringMap::hash remaining the same in the
future/this value should not be serialized to disk. If we want cache
this value StringMap should take a hashing template parameter to allow
for a fixed hash to be requested.
Diffstat (limited to 'llvm/lib/Object/COFFObjectFile.cpp')
0 files changed, 0 insertions, 0 deletions