platform_system_core/libmeminfo/tools
Christopher Ferris 7f8915c76e Cache only a small portion of page map data.
The scudo memory allocator will allocate a large virtual memory address
that causes procrank to allocate a huge amount of data. Modify so it
caches the data a bit at a time.

Remove some allocations that are not necessary since the data is only used
in the first loop.

Fix a few pread64 checks against the actual bytes read, rather than the
read is < 0.

Fix sort by rss in procrank.

Bug: 135694447

Test: Ran unit tests (only one unit test actually runs the modified code).
Test: Ran the old version of procrank using a static libmeminfo and verified
Test: that the same data is found as the new version.

Change-Id: I8adc169b5607ec994ff13a9e161a479350d84c4d
2019-06-25 21:14:36 -07:00
..
Android.bp meminfo: Add support to track working set with idle page tracking. 2019-01-23 22:53:46 -08:00
librank.cpp libmeminfo: librank optimization using maps instead of vectors 2019-03-01 16:17:20 -08:00
procmem.cpp meminfo: Remove unnecessary working set stats 2019-01-14 09:42:50 -08:00
procrank.cpp Cache only a small portion of page map data. 2019-06-25 21:14:36 -07:00
showmap.cpp meminfo: Add Smaps(), showmap and friends. 2019-01-08 17:08:10 -08:00
wsstop.cpp meminfo: Add support to track working set with idle page tracking. 2019-01-23 22:53:46 -08:00