Salome HOME
tests on memory measurements
[modules/smesh.git] / src / SMESH / memoire.h
index fe08e6124cb7136b5c13705d7a4029eeabd99e05..0b8a44b6e4f37c7e394339b1b3f917f311228342 100644 (file)
@@ -30,14 +30,14 @@ void memostat(const char* f, int l)
 #ifdef WIN32
         //rnv: TODO: find alternative of the malloc_stats() on windows platform
 #else
-  /*  struct mallinfo mem = mallinfo(); */
-  /*  std::cerr << f << ":"<< l << " " << mem.arena << " " << mem.ordblks << " " << mem.hblks << " " << mem.hblkhd << " "  << mem.uordblks << " "  << mem.fordblks << " " << mem.keepcost << std::endl; */
+  struct mallinfo mem = mallinfo();
+  std::cerr << f << ":"<< l << " " << mem.arena << " " << mem.ordblks << " " << mem.hblks << " " << mem.hblkhd << " "  << mem.uordblks << " "  << mem.fordblks << " " << mem.keepcost << std::endl;
   std::cerr << f << ":" << l << " --------------------------" << std::endl;
   malloc_stats();
   std::cerr << f << ":" << l << " --------------------------" << std::endl;
 #endif
 }
 
-#define MEMOSTAT //memostat( __FILE__, __LINE__ )
+#define MEMOSTAT memostat( __FILE__, __LINE__ )
 
 #endif