mirror of https://github.com/facebook/rocksdb.git
Fix the build and test bugs in the Trace_analyzer (#4274)
Summary: The wrong options are used in the trace_analyzer_test, removed. The potential loses integer precision are fixed. Pass the specified testing case, make asan_check Pull Request resolved: https://github.com/facebook/rocksdb/pull/4274 Reviewed By: yiwu-arbug Differential Revision: D9327811 Pulled By: zhichao-cao fbshipit-source-id: d62cb18d6586503a490cd323bfc1c672b68b346e
This commit is contained in:
parent
33ad9060d3
commit
8ae2bf5331
|
@ -55,8 +55,6 @@ class TraceAnalyzerTest : public testing::Test {
|
|||
void GenerateTrace(std::string trace_path) {
|
||||
Options options;
|
||||
options.create_if_missing = true;
|
||||
options.IncreaseParallelism();
|
||||
options.OptimizeLevelStyleCompaction();
|
||||
options.merge_operator = MergeOperators::CreatePutOperator();
|
||||
ReadOptions ro;
|
||||
WriteOptions wo;
|
||||
|
|
|
@ -740,7 +740,7 @@ Status TraceAnalyzer::MakeStatisticCorrelation(TraceStats& stats,
|
|||
|
||||
// Process the statistics of QPS
|
||||
Status TraceAnalyzer::MakeStatisticQPS() {
|
||||
uint32_t duration = (end_time_ - begin_time_) / 1000000;
|
||||
uint32_t duration = static_cast<uint32_t>((end_time_ - begin_time_) / 1000000);
|
||||
int ret;
|
||||
Status s;
|
||||
std::vector<std::vector<uint32_t>> type_qps(
|
||||
|
@ -1098,7 +1098,7 @@ Status TraceAnalyzer::KeyStatsInsertion(const uint32_t& type,
|
|||
if (ts < begin_time_) {
|
||||
time_in_sec = 0;
|
||||
} else {
|
||||
time_in_sec = (ts - begin_time_) / 1000000;
|
||||
time_in_sec = static_cast<uint32_t>((ts - begin_time_) / 1000000);
|
||||
}
|
||||
|
||||
uint64_t dist_value_size = value_size / FLAGS_value_interval;
|
||||
|
|
Loading…
Reference in New Issue