Fix MS warnings. Use ROCKSDB_Prsz for size_t.

Summary: Closes https://github.com/facebook/rocksdb/pull/1737

Differential Revision: D4378852

Pulled By: yiwu-arbug

fbshipit-source-id: ba8b02d
main
Dmitri Smirnov 8 years ago committed by Facebook Github Bot
parent c081f7215b
commit e04480faed
  1. 10
      tools/db_bench_tool.cc

@ -3430,11 +3430,11 @@ class Benchmark {
continue;
}
}
writes_ /= open_options_.max_bytes_for_level_multiplier;
writes_ /= static_cast<int64_t>(open_options_.max_bytes_for_level_multiplier);
}
for (size_t i = 0; i < num_db; i++) {
if (sorted_runs[i].size() < num_levels - 1) {
fprintf(stderr, "n is too small to fill %lu levels\n", num_levels);
fprintf(stderr, "n is too small to fill %" ROCKSDB_PRIszt " levels\n", num_levels);
exit(1);
}
}
@ -3481,11 +3481,11 @@ class Benchmark {
}
num_files_at_level0[i] = meta.levels[0].files.size();
}
writes_ *= static_cast<double>(100) / (ratio + 200);
writes_ = static_cast<int64_t>(writes_* static_cast<double>(100) / (ratio + 200));
}
for (size_t i = 0; i < num_db; i++) {
if (sorted_runs[i].size() < num_levels) {
fprintf(stderr, "n is too small to fill %lu levels\n", num_levels);
fprintf(stderr, "n is too small to fill %" ROCKSDB_PRIszt " levels\n", num_levels);
exit(1);
}
}
@ -3594,7 +3594,7 @@ class Benchmark {
for (size_t k = 0; k < num_db; k++) {
auto db = db_list[k];
fprintf(stdout,
"---------------------- DB %lu LSM ---------------------\n", k);
"---------------------- DB %" ROCKSDB_PRIszt " LSM ---------------------\n", k);
db->GetColumnFamilyMetaData(&meta);
for (auto& levelMeta : meta.levels) {
if (levelMeta.files.empty()) {

Loading…
Cancel
Save