|
|
@ -97,6 +97,7 @@ DEFINE_string( |
|
|
|
"readseq," |
|
|
|
"readseq," |
|
|
|
"readreverse," |
|
|
|
"readreverse," |
|
|
|
"compact," |
|
|
|
"compact," |
|
|
|
|
|
|
|
"compactall," |
|
|
|
"readrandom," |
|
|
|
"readrandom," |
|
|
|
"multireadrandom," |
|
|
|
"multireadrandom," |
|
|
|
"readseq," |
|
|
|
"readseq," |
|
|
@ -2420,6 +2421,8 @@ void VerifyDBFromDB(std::string& truth_db_name) { |
|
|
|
method = &Benchmark::WriteSeqSeekSeq; |
|
|
|
method = &Benchmark::WriteSeqSeekSeq; |
|
|
|
} else if (name == "compact") { |
|
|
|
} else if (name == "compact") { |
|
|
|
method = &Benchmark::Compact; |
|
|
|
method = &Benchmark::Compact; |
|
|
|
|
|
|
|
} else if (name == "compactall") { |
|
|
|
|
|
|
|
CompactAll(); |
|
|
|
} else if (name == "crc32c") { |
|
|
|
} else if (name == "crc32c") { |
|
|
|
method = &Benchmark::Crc32c; |
|
|
|
method = &Benchmark::Crc32c; |
|
|
|
} else if (name == "xxhash") { |
|
|
|
} else if (name == "xxhash") { |
|
|
@ -5049,6 +5052,15 @@ void VerifyDBFromDB(std::string& truth_db_name) { |
|
|
|
db->CompactRange(CompactRangeOptions(), nullptr, nullptr); |
|
|
|
db->CompactRange(CompactRangeOptions(), nullptr, nullptr); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void CompactAll() { |
|
|
|
|
|
|
|
if (db_.db != nullptr) { |
|
|
|
|
|
|
|
db_.db->CompactRange(CompactRangeOptions(), nullptr, nullptr); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
for (const auto& db_with_cfh : multi_dbs_) { |
|
|
|
|
|
|
|
db_with_cfh.db->CompactRange(CompactRangeOptions(), nullptr, nullptr); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void ResetStats() { |
|
|
|
void ResetStats() { |
|
|
|
if (db_.db != nullptr) { |
|
|
|
if (db_.db != nullptr) { |
|
|
|
db_.db->ResetStats(); |
|
|
|
db_.db->ResetStats(); |
|
|
|