[llvm-dev] Custom allocator for DenseMap
Prashanth Menon via llvm-dev
llvm-dev at lists.llvm.org
Wed Aug 22 11:24:18 PDT 2018
Hi all,
I'm curious, is there a reason why DenseMap doesn't templatize a custom
Allocator? I'm
in the process of switching all my uses of std::unordered_map and a
custom-rolled hash
map implementation to StringMap and DenseMap. StringMap allows the
injection of an
allocator, but not DenseMap.
Aside from subclassing DenseMapBase and implementing grow/shrink
functionality similar
to DenseMap, is there a simpler solution to injecting custom allocation and
deallocation
into a DenseMap?
Thanks,
Prashanth
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180822/855e7c93/attachment.html>
More information about the llvm-dev
mailing list