NAMD
memusage.h
Go to the documentation of this file.
1 
7 #ifndef MEMUSAGE_H
8 #define MEMUSAGE_H
9 
10 unsigned long memusage(const char **source = 0);
11 
12 inline double memusage_kB() { return memusage() / 1024.; }
13 inline double memusage_MB() { return memusage() / 1048576.; }
14 
15 class memusageinit {
16 public:
17  memusageinit();
18 private:
19  static int initialized;
20  static unsigned long sbrkval;
21  static unsigned long memusage_sbrk();
22  friend unsigned long memusage(const char **source);
23 };
24 
26 
27 #endif
28 
double memusage_kB()
Definition: memusage.h:12
static memusageinit memusageinitobject
Definition: memusage.h:25
double memusage_MB()
Definition: memusage.h:13
memusageinit()
Definition: memusage.C:22
unsigned long memusage(const char **source)
Definition: memusage.C:158
friend unsigned long memusage(const char **source)
Definition: memusage.C:158