[PATCH] D112333: [DebugInfo][InstrRef][NFC] Use DenseMaps where we can, use more efficient ValueIDNum repr
Jeremy Morse via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 25 05:53:36 PDT 2021
jmorse added inline comments.
================
Comment at: llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.h:1029
+ static unsigned getHashValue(const ValueIDNum &Val) {
+ return Val.asU64();
+ }
----------------
Orlando wrote:
> Curious if you have you tried experimenting with this hash function at all?
I tried the standard llvm hash_code, which caused CTMark to be slower. Looking at the assembly, hash_code adds three or four instructions, and that's all. This difference is for the transition of hash_code to nothing, and shows a speedup:
http://llvm-compile-time-tracker.com/compare.php?from=d6553eab88c71e1d797163295750f2d1bc3d86ba&to=cfe24102d48687ccb7fbcc8311488bb3a87010bb&stat=instructions
IMO, the distribution is (seemingly) good enough already.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D112333/new/
https://reviews.llvm.org/D112333
More information about the llvm-commits
mailing list