No description
Find a file
Sandeep Patil a14119d069 Add procrank2
Implement procrank using new libmeminfo APIs. procrank2 is functionally
equivalent to procrank except for the part where the old procrank would
print processes under each oomadj level if called with 'procrank -c -o'.

The output format of 'procrank2' is identical to that of 'procrank'.
'procrank2' also gives significant performance boost over 'procrank' but
does cost a more memory as the library is written to 99% use case where
callers almost always want to read the memory usage of hte process.

Bug: 114325007
Bug: 111694435
Test:
     # adb push /google/data/ro/users/ss/sspatil/test-memutils.sh /data/local/tmp/
     # adb push procmem2 /data/local/tmp && adb push procrank2 /data/local/tmp
     # adb root && adb shell
     $ cd /data/local/tmp/
     $ chmod +x test-memutils.sh
     $ ./test-memutils.sh 2>&1 | tee test.log
Test:
  procrank:
    0m00.43s real     0m00.11s user     0m00.32s system
  procrank2:
    0m00.42s real     0m00.05s user     0m00.36s system

Change-Id: I37b71a4625248e333ba01801c0d8d7ef348e4cfa
Signed-off-by: Sandeep Patil <sspatil@google.com>
2018-12-07 09:15:16 -08:00
adb Merge "adb: fix authentication when reconnecting." 2018-12-04 20:41:14 +00:00
adf Make libadf, libsync_recovery recovery_available. 2018-08-07 10:53:07 -07:00
base Merge "base: add more error-checking overloads for unique_fd." 2018-12-03 22:41:22 +00:00
bootstat switch to using android-base/file.h instead of android-base/test_utils.h 2018-11-14 09:35:34 -08:00
cpio Switch from dist-for-goals to dist in Android.bp 2018-11-19 23:06:12 -08:00
debuggerd C++17 is the default now. 2018-12-03 09:02:18 -08:00
demangle Build adbd for recovery 2018-05-24 14:11:11 +09:00
diagnose_usb Build adbd for recovery 2018-05-24 14:11:11 +09:00
fastboot Merge "C++17 is the default now." 2018-12-04 07:53:24 +00:00
fs_mgr Merge "liblp: Allocate "b" extents in the second half of super." 2018-12-04 21:53:48 +00:00
gatekeeperd Multi-threaded Keystore 2018-11-07 11:39:23 -08:00
healthd healthd: BatteryMonitor: Fix compiler warning 2018-11-02 17:59:09 +00:00
include Move android_filesystem_config.h => fs_config.h 2017-08-02 16:31:19 -07:00
init Merge "Convert fs_mgr_swapon_all() to use the new Fstab struct" 2018-12-04 18:41:56 +00:00
libappfuse Stop using SO_SNDBUFFORCE 2018-03-15 14:22:27 +09:00
libasyncio Build adbd for recovery 2018-05-24 14:11:11 +09:00
libbacktrace Verify that the elf matches the expected arch. 2018-10-29 18:08:09 -07:00
libbinderwrapper Make libbinderwrapper available in /vendor partition 2018-04-06 08:41:21 +09:00
libcrypto_utils Convert more modules to Android.bp 2018-10-31 21:53:37 -07:00
libcutils Increase netlink uevent rcvbuf size to 16M 2018-12-03 18:39:24 +00:00
libdiskconfig Rename target.linux[_x86[_64]] to target.linux_glibc[_x86[_64]] 2017-10-02 10:44:29 -07:00
libgrallocusage Merge "Build both static and shared lib." 2018-09-25 22:29:31 +00:00
libion libion: cleanup logging 2018-03-07 10:56:06 -08:00
libkeyutils Build adbd for recovery 2018-05-24 14:11:11 +09:00
liblog Merge "Add missing <android/log.h> documentation." 2018-11-02 23:32:43 +00:00
libmeminfo Add procrank2 2018-12-07 09:15:16 -08:00
libmemtrack Add OWNERS. 2017-12-07 13:30:03 -08:00
libmemunreachable Validate allocations against mappings 2018-11-29 11:02:56 -08:00
libmetricslogger Make native metrics logger write to statsd socket 2018-10-24 15:19:14 -07:00
libnativebridge Convert more modules to Android.bp 2018-10-31 21:53:37 -07:00
libnativeloader Add error_msg argument to CloseNativeLibrary 2018-09-12 01:36:06 +02:00
libnetutils Merge "Add OWNERS." am: 3289b9c928 2017-12-07 23:51:13 +00:00
libpackagelistparser Mark as recovery_available: true 2018-05-15 09:47:04 +09:00
libpixelflinger Convert libpixelflinger to Android.bp 2018-11-16 19:15:38 -08:00
libprocessgroup Introduce additional service options for controlling memory cgroups. 2018-10-31 17:09:59 -07:00
libprocinfo libprocinfo: provide MapInfo structure for reading maps. 2018-10-30 17:36:09 -07:00
libqtaguid Redirect qtaguid native call to netd fwmark client 2017-11-09 18:02:22 -08:00
libsparse Revert "libsparse: Add sparse typed callback" 2018-07-26 05:23:45 +00:00
libstats Make native metrics logger write to statsd socket 2018-10-24 15:19:14 -07:00
libsuspend Remove libsuspend from VNDK. 2018-08-14 13:39:55 -07:00
libsync Merge libsync_recovery rules into libsync. 2018-08-07 11:00:50 -07:00
libsystem Move system/core/ off NO_ERROR. 2018-10-08 11:15:52 -07:00
libsysutils Suppress implicit-fallthrough warning. 2018-10-10 14:39:02 -07:00
libunwindstack Add support for caching small reads. 2018-11-28 13:04:58 -08:00
libusbhost Merge "Remove urb request size maximum." am: 1cb765c867 am: 1ab6e9d018 2018-02-13 09:02:38 +00:00
libutils Suppress lint warnings on google-default-arguments 2018-10-29 23:06:23 +09:00
libvndksupport bpfmt. 2018-02-16 17:58:14 -08:00
libziparchive Merge "TEST_MAPPING: add the rest of our actively maintained tests." 2018-11-28 00:56:36 +00:00
llkd llkd: do not crash kernel if llkd stops running 2018-11-19 15:26:20 -08:00
lmkd lmkd: Cleanup unused code for killing processes in bulk 2018-10-29 16:20:50 +00:00
logcat Stop using __STRING unnecessarily. 2018-11-14 14:27:22 -08:00
logd Fix null pointer dereference in auditParse 2018-11-27 14:01:29 -08:00
logwrapper Build adbd for recovery 2018-05-24 14:11:11 +09:00
mkbootimg Revert "Revert "mkbootimg: Build mkbootimg with Soong."" 2018-09-27 14:11:51 +00:00
property_service Prevent dependency cycle due to system_shared_libs expansion 2018-12-03 15:50:00 -08:00
qemu_pipe Build adbd for recovery 2018-05-24 14:11:11 +09:00
reboot reboot: only pause indefinitely for non-shutdown operations 2017-09-29 16:29:52 +00:00
rootdir Merge "Add ANDROID_RUNTIME_ROOT environment variable" 2018-12-04 12:39:16 +00:00
run-as run-as: add ":fromRunAs" selector in seinfo. 2018-11-06 15:31:59 -08:00
sdcard Add support for esdfs mounting 2018-01-19 12:58:42 -08:00
shell_and_utilities Make unzip available. 2018-09-04 13:33:30 -07:00
storaged storaged: emplace recent_perf in load_perf_history_proto 2018-11-20 09:00:05 -08:00
toolbox getevent: O_RDWR -> O_RDONLY | O_CLOEXEC 2018-08-24 12:16:17 -07:00
trusty Add noexcept to move constructors and assignment operators. 2018-10-05 16:43:47 +00:00
usbd bpfmt. 2018-02-16 17:58:14 -08:00
watchdogd Move watchdogd out of init 2018-08-02 12:25:58 -07:00
.clang-format Add a 2 width option of clang format. 2017-03-10 13:01:39 -08:00
.clang-format-2 Remove PenaltyExcessCharacter from clang-formats. 2018-07-19 13:50:41 -07:00
.clang-format-4 Remove PenaltyExcessCharacter from clang-formats. 2018-07-19 13:50:41 -07:00
.gitignore Ignore adb/*.pyc files 2015-08-11 12:59:58 -07:00
Android.bp Export android_filesystem_config.h as a filegroup 2017-01-17 18:20:28 -08:00
Android.mk
CleanSpec.mk Shared libs are supported in recovery mode 2018-06-10 08:32:24 +09:00
MODULE_LICENSE_APACHE2 auto import from //depot/cupcake/@135843 2013-07-30 13:56:49 -07:00
NOTICE Fix omission in NOTICE file. 2013-07-30 13:56:55 -07:00
OWNERS Move per-file OWNERS directives to their directories. 2018-06-06 11:49:40 +09:00
PREUPLOAD.cfg Add a PREUPLOAD.cfg file to run git-clang-format on every commit 2017-03-08 16:51:26 +08:00
TEST_MAPPING TEST_MAPPING: add the rest of our actively maintained tests. 2018-10-30 11:24:57 -07:00