c++ - How to get memory information on Linux system? -


Using total memory, memory, and free memory from C ++ code on Linux system?

Run your program through valgrind . For a program called foo , for example:

  valgrind foo  

This program will keep in the harness that keeps Track the usage of memory and print out that information after the program is over.

If you do not have valgrind installed for any reason, then you should be able to find it in your distributions package repository


Comments

Popular posts from this blog

c# - SignalR: "Protocol error: Unknown transport." when navigating to hub -

c# - WPF Expander overlay used in ItemsControl -

class - Kivy: how to instantiate a dynamic classes in python -