[PATCH] D61178: caseFoldingDjbHash: simplify and make the US-ASCII fast path faster
Pavel Labath via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 26 03:14:00 PDT 2019
labath accepted this revision.
labath added a comment.
This revision is now accepted and ready to land.
Interesting. I take it the new code pipelines/unrolls better because it has a single branchless loop.
In terms of readability, I'd still try to split this into two functions, assuming that doesn't have a negative performance impact (which I'm hoping it doesn't). I'm thinking of something like
if (Optional<uint32_t> Result = fastCaseFoldingDjbHash(Buffer, H))
return *Result;
// slow stuff...
Other than that, this looks good to me. Thanks for improving this.
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D61178/new/
https://reviews.llvm.org/D61178
More information about the llvm-commits
mailing list