mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-12-28 03:37:59 +00:00
ENH: handle 64-bit memory information (#3060)
- on large memory systems (eg, 6TB) the process information exceeds an 'int' range, so adjust parsing of the /proc/.. to use int64 ENH: update/modernize OSspecific system information ENH: minor update of profiling code - std::string, noexcept, lazier evaluations STYLE: use direct call of memInfo
This commit is contained in:
@ -1,3 +1,3 @@
|
||||
Test-memInfo.C
|
||||
Test-memInfo.cxx
|
||||
|
||||
EXE = $(FOAM_USER_APPBIN)/Test-memInfo
|
||||
|
||||
@ -47,14 +47,18 @@ int main(int argc, char *argv[])
|
||||
memInfo mem;
|
||||
|
||||
Info<< memTags << mem << endl;
|
||||
List<vector> lst(n, vector::one);
|
||||
|
||||
Info<< "allocate " << n << " vectors" << nl
|
||||
<< memTags << mem.update() << endl;
|
||||
List<vector> list(n, vector::one);
|
||||
|
||||
lst.clear();
|
||||
Info<< "clear" << nl
|
||||
<< memTags << mem.update() << endl;
|
||||
Info<< "allocate " << n << " vectors" << nl;
|
||||
Info<< memTags << mem.update() << endl;
|
||||
|
||||
list.clear();
|
||||
Info<< "clear" << nl;
|
||||
Info<< memTags << mem.update() << endl;
|
||||
|
||||
mem.writeEntry("memory", Info);
|
||||
Info<< endl;
|
||||
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user