#include <CoWRecordStats.h>
|
enum | ValueIdx {
Size =0,
Rss =1,
Pss =2,
Shared_Clean =3,
Shared_Dirty =4,
Private_Clean =5,
Private_Dirty =6,
Referenced =7,
Anonymous =8,
AnonHugePages =9,
Swap =10,
KernelPageSize =11,
MMUPageSize =12,
Locked =13,
VmFlags =14
} |
|
Definition at line 13 of file CoWRecordStats.h.
◆ ValueIdx
Enumerator |
---|
Size | |
Rss | |
Pss | |
Shared_Clean | |
Shared_Dirty | |
Private_Clean | |
Private_Dirty | |
Referenced | |
Anonymous | |
AnonHugePages | |
Swap | |
KernelPageSize | |
MMUPageSize | |
Locked | |
VmFlags | |
Definition at line 16 of file CoWRecordStats.h.
◆ CoWRecordStats()
CoWTools::CoWRecordStats::CoWRecordStats |
( |
bool |
summary = true | ) |
|
|
inline |
◆ getValueArray() [1/2]
long long* CoWTools::CoWRecordStats::getValueArray |
( |
| ) |
|
|
inline |
◆ getValueArray() [2/2]
const long long* CoWTools::CoWRecordStats::getValueArray |
( |
| ) |
const |
|
inline |
◆ operator bool()
CoWTools::CoWRecordStats::operator bool |
( |
| ) |
const |
|
inlineexplicit |
◆ operator+=()
◆ operator-()
◆ operator-=()
◆ parseRecord()
void CoWTools::CoWRecordStats::parseRecord |
( |
std::istream & |
in | ) |
|
Definition at line 40 of file CoWRecordStats.cxx.
44 while(!(std::getline(in,
line).eof())){
49 sscanf(
line.c_str(),
"%19s%n",
buff,&len);
50 if(strcmp(
buff,
"VmFlags:")==0){
52 while(len<(
int)
line.size()){
58 sscanf(
line.c_str()+len,
"%8lu",&
val);
◆ operator+
◆ operator-
◆ operator<
Definition at line 80 of file CoWRecordStats.h.
81 if((
a.m_vals[5]+
a.m_vals[6])<(
b.m_vals[5]+
b.m_vals[6])){
83 }
else if((
a.m_vals[5]+
a.m_vals[6])==(
b.m_vals[5]+
b.m_vals[6])){
84 if((
a.m_vals[3]+
a.m_vals[4])<(
b.m_vals[3]+
b.m_vals[4])){
86 }
else if((
a.m_vals[3]+
a.m_vals[4])==(
b.m_vals[3]+
b.m_vals[4])){
87 return (
a.m_vals[1]<
b.m_vals[1]);
◆ operator<<
Definition at line 67 of file CoWRecordStats.cxx.
70 snprintf(
buff,2048,
"VMem= %8lld, RSS= %8lld, PSS= %8lld, Shared= %8lld, Private= %8lld, Swap= %8lld Anon= %8lld",
71 m.m_vals[0],
m.m_vals[1],
m.m_vals[2],
m.m_vals[3]+
m.m_vals[4],
m.m_vals[5]+
m.m_vals[6],
m.m_vals[10],
m.m_vals[8]);
79 "Shared_Clean: %8lld kB\n" \
80 "Shared_Dirty: %8lld kB\n" \
81 "Private_Clean: %8lld kB\n" \
82 "Private_Dirty: %8lld kB\n" \
83 "Referenced: %8lld kB\n" \
84 "Anonymous: %8lld kB\n" \
85 "AnonHugePages: %8lld kB\n" \
87 "KernelPageSize: %8lld kB\n" \
88 "MMUPageSize: %8lld kB\n" \
◆ m_summary
bool CoWTools::CoWRecordStats::m_summary |
|
private |
◆ m_vals
long long CoWTools::CoWRecordStats::m_vals[20] |
|
private |
Initial value:={0,0,0,0,0,
0,0,0,0,0,
0,0,0,0,0,
0,0,0,0,0}
Definition at line 97 of file CoWRecordStats.h.
◆ s_vmFlags
const std::map< std::string, int > CoWTools::CoWRecordStats::s_vmFlags |
|
staticprivate |
Initial value:={
{"rd",0x00000001},
{"wr",0x00000002},
{"ex",0x00000004},
{"sh",0x00000008},
{"mr",0x00000010},
{"mw",0x00000020},
{"me",0x00000040},
{"ms",0x00000060},
{"gd",0x00000080},
{"pf",0x00000100},
{"dw",0x00000200},
{"lo",0x00000400},
{"io",0x00000800},
{"sr",0x00001000},
{"rr",0x00002000},
{"dc",0x00004000},
{"de",0x00008000},
{"ac",0x00010000},
{"nr",0x00020000},
{"ht",0x00040000},
{"nl",0x00080000},
{"ar",0x00100000},
{"dd",0x00200000},
{"sd",0x00400000},
{"mm",0x00800000},
{"hg",0x01000000},
{"nh",0x02000000},
{"mg",0x04000000}
}
Definition at line 103 of file CoWRecordStats.h.
The documentation for this class was generated from the following files: