]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
common: compute SimpleLRU's size with contents.size() instead of lru.size() 19977/head
authorXuehan Xu <xuxuehan@360.cn>
Sat, 6 Jan 2018 02:40:33 +0000 (10:40 +0800)
committerPrashant D <pdhange@redhat.com>
Wed, 17 Jan 2018 04:14:26 +0000 (23:14 -0500)
commit91be5317da05dea8f8cf9695b2059a72c4c151c4
tree4825ec00943aa9023d65e8713944801d2ea5b226
parentcc6a3561cc8ec65e05451073d0dfdd6efb4b9700
common: compute SimpleLRU's size with contents.size() instead of lru.size()

As libstdc++ earlier than version 5 implement the list::size() as a O(n) operation,
this should be needed to avoid regression of various ceph component's performance.

Signed-off-by: Xuehan Xu <xuxuehan@360.cn>
(cherry picked from commit 7e0a27a5c8b7d12d378de4d700ed7a95af7860c3)
src/common/simple_cache.hpp