]> git-server-git.apps.pok.os.sepia.ceph.com Git - rocksdb.git/commit
Remove the unnecessary use of shared_ptr
authorkailiu <hfevers@gmail.com>
Thu, 16 Jan 2014 02:17:58 +0000 (18:17 -0800)
committerkailiu <hfevers@gmail.com>
Thu, 16 Jan 2014 02:22:01 +0000 (18:22 -0800)
commiteae1804f29585cc643dee798a52d71569d1d90de
tree85effd988503065e90e262a17e3ccf242020cf6f
parent787f11bb3bbd1539de1cfece609af1131e4eae9a
Remove the unnecessary use of shared_ptr

Summary:
shared_ptr is slower than unique_ptr (which literally comes with no performance cost compare with raw pointers).
In memtable and memtable rep, we use shared_ptr when we'd actually should use unique_ptr.

According to igor's previous work, we are likely to make quite some performance gain from this diff.

Test Plan: make check

Reviewers: dhruba, igor, sdong, haobo

CC: leveldb
Differential Revision: https://reviews.facebook.net/D15213
db/memtable.cc
db/memtable.h
db/version_set.cc
include/rocksdb/memtablerep.h
util/hash_skiplist_rep.cc
util/hash_skiplist_rep.h
util/skiplistrep.cc
util/vectorrep.cc