Commit b3ac45b5 authored by Artem Udovichenko's avatar Artem Udovichenko
Browse files

Reduce number of physical pages used for DexCache's arrays

This commit reduces the amount of physical pages allocated for the .bss
section of an application's oat file.
Many of elements in the application's DexCache arrays are empty.
But during coping content of the DexCaches arrays from
the app's art file into the .bss section all pages become dirty.
The commit fixes that by copying non null elements only. So pages
in the .bss section that contains zeroes remains untouched.
This approach allows to save 209Kb of memory after one minute of
GMaps use.
This number is the difference between the size of .bss section and
the Rss value from the /proc/<pid>/smaps file.

Test: run test-art-host

Change-Id: I3d7bed0805b95b5f344303581274ca8e8e69940e
parent 5b6fbd02
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment