Track peak RAM in benchmarks

This commit is contained in:
Siarhei Fedartsou 2024-07-12 20:35:33 +02:00
parent 2dcd6af43f
commit 51844f5a98

View File

@ -656,17 +656,15 @@ try
return EXIT_FAILURE;
}
std::cout
<< "Peak RAM: "
<< std::setprecision(3)
<< static_cast<double>(osrm::util::PeakRAMUsedInBytes()) / static_cast<double>((1024 * 1024))
<< "MB"
<< std::endl;
std::cout << "Peak RAM: " << std::setprecision(3)
<< static_cast<double>(osrm::util::PeakRAMUsedInBytes()) /
static_cast<double>((1024 * 1024))
<< "MB" << std::endl;
return EXIT_SUCCESS;
}
catch (const std::exception &e)
{
std::cerr << "Error: " << e.what() << std::endl;
return EXIT_FAILURE;
std::cerr << "Error: " << e.what() << std::endl;
return EXIT_FAILURE;
}