ANDROID: vendor_hooks: Add hooks for reducing virtual address fragmentation
When running 32-bit apps for a long time, virtual address becomes fragmented which can lead to allocation failures when a large virtually-contiguous area is requested. Add hooks to implement pools to cluster together small-sized virtual address mappings. Add hooks to implement reserved virtual address zone with usage restrictions controlled by vendor hooks. These hooks help in controlling virtual address space fragmentation. Bug: 187259935 Signed-off-by: xieliujie <xieliujie@oppo.com> Change-Id: I48c057041f9c7b8c5ab0af305f0cd87a039d0447
This commit is contained in:

committed by
Suren Baghdasaryan

parent
f150653471
commit
dc5241048f
@@ -47,6 +47,17 @@ DECLARE_HOOK(android_vh_meminfo_proc_show,
|
||||
DECLARE_HOOK(android_vh_exit_mm,
|
||||
TP_PROTO(struct mm_struct *mm),
|
||||
TP_ARGS(mm));
|
||||
DECLARE_HOOK(android_vh_get_unmapped_area_from_anti_fragment_pool,
|
||||
TP_PROTO(struct mm_struct *mm, struct vm_unmapped_area_info *info,
|
||||
unsigned long *addr),
|
||||
TP_ARGS(mm, info, addr));
|
||||
DECLARE_HOOK(android_vh_exclude_reserved_zone,
|
||||
TP_PROTO(struct mm_struct *mm, struct vm_unmapped_area_info *info),
|
||||
TP_ARGS(mm, info));
|
||||
DECLARE_HOOK(android_vh_get_unmapped_area_include_reserved_zone,
|
||||
TP_PROTO(struct mm_struct *mm, struct vm_unmapped_area_info *info,
|
||||
unsigned long *addr),
|
||||
TP_ARGS(mm, info, addr));
|
||||
DECLARE_HOOK(android_vh_show_mem,
|
||||
TP_PROTO(unsigned int filter, nodemask_t *nodemask),
|
||||
TP_ARGS(filter, nodemask));
|
||||
|
Reference in New Issue
Block a user