自定义的分配器快速的std :: wstring的分配 [英] Custom allocator for fast std::wstring allocations
问题描述
有没有可以用的std :: wstring的
被用来实施的快速的分配格局就像任何开源分配器(可能在升压)在这个博客帖子 <? / p>
Boost.Pool <一个href=\"http://stackoverflow.com/questions/10451585/using-vectorwstring-with-boost-pool-allocator\">doesn't似乎非常适合这一目的。
没有,没有(我搜索了几个小时,一次)。如果你不小心使用过程中释放内存,它是相当简单的做自己。如果要动态地释放它,那么它就变成对自由列表管理,LRU等大量的工作。
Is there any open-source allocator (possibly in Boost) that can be used with std::wstring
implementing a fast allocation pattern like the one showed in this blog post?
Boost.Pool doesn't seem well suited for this purpose.
No, there isn't (I searched for a couple of hours, once). If you don't care to release memory during usage, it is fairly simple to do yourself. If you want to release it dynamically, then it becomes a lot of work regarding free list management, LRU, etc.
这篇关于自定义的分配器快速的std :: wstring的分配的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!