cleanups and fixes for process_madvise compaction
some fix suggestions that came up on ag/13665789 and some other cleanups
1. Use unique_fd instead of raw int to keep pidfd
2. Return the total compacted bytes on success for compactProcess
3. Fix for error potentially returning a random value
4. Fix truncation that could happen when calling madvise
5. Fail fast after encountering an error instead of silently
advancing to other VMAs when compacting.
Bug: 162993824
Test: Manual
Signed-off-by: Edgar Arriaga <edgararriaga@google.com>
Change-Id: Ide644f66cf0ebdea570dcb365d6a2400ffb18f4e
Loading
Please register or sign in to comment