mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
[RocksDB] Introduce Fast Mutex option
Summary: This diff adds an option to specify whether PTHREAD_MUTEX_ADAPTIVE_NP will be enabled for the rocksdb single big kernel lock. db_bench also have this option now. Quickly tested 8 thread cpu bound 100 byte random read. No fast mutex: ~750k/s ops With fast mutex: ~880k/s ops Test Plan: make check; db_bench; db_stress Reviewers: dhruba CC: MarkCallaghan, leveldb Differential Revision: https://reviews.facebook.net/D11031
This commit is contained in:
@@ -73,7 +73,8 @@ Options::Options()
|
||||
stats_dump_period_sec(3600),
|
||||
block_size_deviation (10),
|
||||
advise_random_on_open(true),
|
||||
access_hint_on_compaction_start(NORMAL) {
|
||||
access_hint_on_compaction_start(NORMAL),
|
||||
use_adaptive_mutex(false) {
|
||||
}
|
||||
|
||||
static const char* const access_hints[] = {
|
||||
@@ -208,6 +209,8 @@ Options::Dump(Logger* log) const
|
||||
advise_random_on_open);
|
||||
Log(log," Options.access_hint_on_compaction_start: %s",
|
||||
access_hints[access_hint_on_compaction_start]);
|
||||
Log(log," Options.use_adaptive_mutex: %d",
|
||||
use_adaptive_mutex);
|
||||
} // Options::Dump
|
||||
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user