Hi. I'm trying to read how much ram an app is using reading http://unix.derkeiler.com/Mailing-Lists/FreeBSD/stable/2006-03/msg00246.html from ru.ru_maxrss. While ru.ru_maxrss gives me used accurate ram-usage when memory increases it doesn't immediately count down when memory is released.
So I tried to get a more accurate reading using this using /usr/src/sys/kern/kern_clock.c as example: struct thread *td; td = curthread; p = td->td_proc; vm = p->p_vmspace; rss = pgtok(vmspace_resident_count(vm)); Curthread is not defined, I searched google but can't find any references. But is this the proper way to get an apps memory usage? -- regards Claus When lenity and cruelty play for a kingdom, the gentler gamester is the soonest winner. Shakespeare twitter.com/kometen _______________________________________________ [email protected] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "[email protected]"
