[PATCH] D125979: [ADT] add LockFreeDataPool class.
Alexey Lapshin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon May 23 11:55:20 PDT 2022
avl added a comment.
In D125979#3529745 <https://reviews.llvm.org/D125979#3529745>, @dblaikie wrote:
> (any chance we can avoid duplicating this, and instead refactor the lld one into LLVM and have lld use that one instead of using its own local copy?)
I thought about that. But the implementation from lld looks too specific for general implementation.
It uses knowledge about stored data:
1. It keeps data together with hash inside hash table. This is OK for 32-bit integer but it would not be OK for larger type.
2. It compares data to select which version should be stored. We need a way to do it or avoid it without introducing more checks.
if (!oldCell.isEmpty() >>>&& oldCell < newCell<<<)
return idx;
I do not have effective way on how to put that behaviour in general implementation at the moment.
Probably, that might be done by inheritance and redefinition in child implementations.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D125979/new/
https://reviews.llvm.org/D125979
More information about the llvm-commits
mailing list