Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ff4d1e22 authored by Kevin Jeon's avatar Kevin Jeon
Browse files

Allow PM to scan directories in parallel.

Starting PM during boot is expensive, with about a third of the time
spent in trawling system directories and processing the packages inside.
PM currently parallelizes package scanning/parsing within each
directory, but directories themselves are processed in sequence (with
package installs being the blocker). This means that large or otherwise
slow-to-process packages will block boot even when there are scan/parse
tasks in other directories that can be carried out.

This change updates PM to scan all directories in parallel, with
packages being installed in the order that they were scanned. This
eliminates the slack when moving between directories, or ~55ms
(245ms -> 189ms).

Test: build, flash, boot, measure improvement in latency
Bug: 401622806
Flag: android.content.pm.parallel_package_parsing_across_system_dirs
Change-Id: Ia155741beab4541dea16e78dee73a2e453dc2d64
parent bfe2c0c9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment