Hi,
On Tue, Jul 26, 2005 at 11:11:03AM +0200, Bert van Leeuwen wrote:
How can I check how much heap space is left (or used) in my drops/oskit program? Normally (in linux/gnu) I would use getrusage, which also returns a number of other useful statistics, but this function doesn't seem to exist in drops/oskit...
In "MODE = l4env" you could use one of:
#include <oskit/lmm.h>
extern lmm_t malloc_lmm;
unsigned int free_memory = lmm_avail(&malloc_lmm, 0); lmm_dump(&malloc_lmm); lmm_stats(&malloc_lmm);