[PATCH] D139573: [FoldingSet] Move compare to header (NFC).

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 7 13:00:08 PST 2022


fhahn created this revision.
fhahn added reviewers: nikic, serge-sans-paille, yurai007.
Herald added a subscriber: hiraditya.
Herald added a project: All.
fhahn requested review of this revision.
Herald added a project: LLVM.

Moving the compare operator implementations to the header gives a slight
speedup. Not sure if the speedups are worthwhile, but I noticed this
when looking at folding set performance in general.

NewPM-O3: -0.04%
NewPM-ReleaseThinLTO: -0.03%
NewPM-ReleaseLTO-g: -0.01

https://llvm-compile-time-tracker.com/compare.php?from=8fa81cfad47c827ea1b75afe1f32861d4a7bad37&to=3c5e5ebd834106e62407e79d80ced0a49eafc4b7&stat=instructions:u


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D139573

Files:
  llvm/include/llvm/ADT/FoldingSet.h
  llvm/lib/Support/FoldingSet.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D139573.481026.patch
Type: text/x-patch
Size: 4610 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221207/d2030088/attachment.bin>


More information about the llvm-commits mailing list