Commit 2bbd04ef authored by Samuel Pitoiset's avatar Samuel Pitoiset

Tests/noDist: allow to monitor RSS in testBlockedUniformCompare

parent b926ea5e
......@@ -60,6 +60,11 @@
#include "Utils/FTemplate.hpp"
#ifdef MEMORY_USAGE
#include <sys/time.h>
#include <sys/resource.h>
#endif
#define RANDOM_PARTICLES
const FParameterNames LocalOrder { {"-order"}, "Order of the kernel"};
......@@ -651,6 +656,13 @@ struct RunContainer{
groupalgo.execute();
std::cout << "Done " << "(@Algorithm = " << timer.tacAndElapsed() << "s)." << std::endl;
#ifdef MEMORY_USAGE
// Get the maximum resident set size (RSS) in kilobytes
struct rusage usage;
getrusage(RUSAGE_SELF, &usage);
fprintf(stderr, "(@RSS = %ldKB\n", usage.ru_maxrss);
#endif
// Validate the result
if(FParameters::existParameter(argc, argv, LocalOptionNoValidate.options) == false){
FSize offsetParticles = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment