Measuring memory footprint in C/C++ code on FreeBSD
Hello
I'd like to measure the memory footprint in C/C++ code for a
program running under FreeBSD and Linux in terms of total process size
including heap objects. Due to execution length, I'd like to avoid the
use of valgrind.
I think that it would be difficult to achieve the task in a
platform-transparent manner, that's why I'll be using /proc/<pid>/status
on Linux, and do something else on FreeBSD.
I was adviced to have a look on getrusage, which I did, but I found
descriptions of certain fields of struct rusage in the manpage too
cryptic to make a proper use of the call.
Could someone please point me in the right direction?
Thanks very much.
~Razmig
_______________________________________________
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"
討論串 (同標題文章)
完整討論串 (本文為第 1 之 11 篇):