History log of /frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
f53201f8c796e8500b76b72e4fad6269d8547369 15-Sep-2017 Calin Juravle <calin@google.com> Add an explicit reason for the compilation of shared apks

Some devices might find it more beneficial to compile shared apks like gms
or gms modules with quicken rather then speed.

Bug: 65591595
Test: build
Change-Id: I90b79e9f6bc4b4d6b3f5c0b90ab95e8880c4ac9d
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
246dccf9327631597767afe418ce43ae6d07d102 25-May-2017 Shubham Ajmera <shubhamajmera@google.com> Reduce app size by downgrading inactive apps

This will trigger when the device will have low space.
Active apps here refer to the apps which were either active
in foregrond or in background and also used by other packages.
Apps which are inactive for X days downgraded to verify. X is
determined by sysprop pm.dexopt.unopt_after_inactive_days

If the system properties are not set, no effect will take place.

The above operations will take place in background dexopt service.
If user uses the app again, it will again be speed-compiled when
background dexopt service starts next time.

Bug: 36598475
Test: manual
* Remove the check in the code that allows downgrade only when
the space is low on the device.
* adb root
* Set pm.dexopt_unopt_after_inactive_days to 600
* Make sure the current time of the device is correctly set
* Install 2 non system apps - B, C
* Downgrade B to extract
* Upgrade a system apps to speed-profile - E
* Downgrade a system app to quicken - G
* adb shell cmd package bg-dexopt-job

Expected Results:
* Extract - B
* Verify - C
* There should not be any entries for apps E an G
in dalvik_cache

Change-Id: I68f9f617d6722a7ba8b00aa2181cb38a165cfc51
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
b0818e8871eb157ee6a6991ea27a6082dc084741 05-May-2017 Nicolas Geoffray <ngeoffray@google.com> resolve merge conflicts of c2421a2a3c37 to oc-dev-plus-aosp

Test: I solemnly swear I tested this conflict resolution.
Change-Id: I5825e002c7ac5655703cd31d84ccc1cb5379f0e0
d093b203f557685de33179bff0eb35ea205294a2 03-May-2017 Nicolas Geoffray <ngeoffray@google.com> Handle safe mode in PackageManager.

PackageManager side of the change.

bug:37929796
Test: manual OTA with a safemode app.
Change-Id: I98c8200d4330dc88fec7eb8ffeb27717a22a220b
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
9cea1d28dd96b05cf3cb910e03ade9dfc5146745 21-Apr-2017 Nicolas Geoffray <ngeoffray@google.com> Drop REASON_FORCED_DEXOPT.

This can already be configured with the default compiler filter.

Also remove unused performDexOptIfNeeded.

bug:35794392
Test: device boots, forced dexopt works.
Change-Id: I14fc86c4783b2d7ac9cf8972b6619ba303e79659
(cherry picked from commit e103256c1fee6b53ead10efe13ca35ad270626fa)
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
2ab076f611cecb771fe546580634583a27c61aa5 26-Mar-2017 Nicolas Geoffray <ngeoffray@google.com> Drop REASON_SHARED_APK.

This reason was only used by "system shared libraries", not shared
APKs like GMS.

Code that uses this reason is now obsolete, as we do compile these shared
libraries when we see an apk that uses it.

bug:33799337
Test: m -j32 && boot
Change-Id: I2eef22797551401a5c39ed339bc2486cf0d091a8
(cherry picked from commit 86d1e9e23e79687ae94854fc6aa22c3d4ad98423)
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
de0272b85c4ff1eba1c58a3cdfd53bd5eb9925ef 26-Mar-2017 Nicolas Geoffray <ngeoffray@google.com> Drop REASON_NON_SYSTEM_LIBRARY.

Dexopt them with the same "mode" as the apk we are
going to dexopt. Because we treat them as shared, this
means they are only going to be fully compiled once an app
that has it in its <uses-library> gets compiled.

bug:33799337
Test: m -j32 && boot
Change-Id: Ic93fbcf45be6b9cf31ad3a3eb498f9fbbefeb288
(cherry picked from commit 90978b4159dd1394c0643ae8171d24668fbc27a4)
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
30f18587e3bf6079f910699c89f1b702664982b5 24-Mar-2017 Nicolas Geoffray <ngeoffray@google.com> Drop REASON_CORE_APP.

After ensuring apps used by system server are speed compiled
on /system, we don't need a special reason anymore.

bug:36532541
bug:33799337

Test: m -j32 && boot
Change-Id: I1fb894f0f5b796cb9d59ed01a4afb2709c0f5496
(cherry picked from commit b70e4bfe0776a3446ccfddd5a10b1ff155f60e34)
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
c657b769ab9d37daa8a6086ec0e468bcb3530a50 03-Mar-2017 Elliott Hughes <enh@google.com> Merge "Remove the name length limit for system properties."
33cc60ccc98b555bb7d9e7c75d7435917cca1458 02-Mar-2017 Elliott Hughes <enh@google.com> Remove the name length limit for system properties.

Bug: http://b/33926793
Test: builds
Change-Id: Ib89b66b7abebc9a28961a0c9032b99947e3db0d6
Merged-In: Ib89b66b7abebc9a28961a0c9032b99947e3db0d6
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
7218363a92d15cc1854cf298ef77e1ed2aeafa3b 17-Jan-2017 Calin Juravle <calin@google.com> Compile secondary dex files in DexManager

Add logic for secondary dex compilation in DexManager. Also, extend the
`cmd package compile` command with '--secondary-dex' option which will
compile all used secondary dex files for the given package.

Test: flash & boot,
cmd package compile --secondary-dex -f -m speed
com.google.android.gms
Bug: 32871170

(cherry picked from commit c22c30ed1c05c5c24185dc4d380d1c5026923d46)

Change-Id: I3cf26edbfb5e9f3683e608bb2a596e1ab5682bd4

Merged-In: Ia2b95cb70d26c4ead5cb650047641b0881ca84ae
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
c77001de5158b531b18858a84488a08d9460a429 02-Mar-2017 Elliott Hughes <enh@google.com> Remove the name length limit for system properties.

Bug: http://b/33926793
Test: builds
Change-Id: Ib89b66b7abebc9a28961a0c9032b99947e3db0d6
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
c22c30ed1c05c5c24185dc4d380d1c5026923d46 17-Jan-2017 Calin Juravle <calin@google.com> Compile secondary dex files in DexManager

Add logic for secondary dex compilation in DexManager. Also, extend the
`cmd package compile` command with '--secondary-dex' option which will
compile all used secondary dex files for the given package.

Test: flash & boot,
cmd package compile --secondary-dex -f -m speed
com.google.android.gms
Bug: 32871170

Change-Id: Ia2b95cb70d26c4ead5cb650047641b0881ca84ae
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
258aa3e56b02b95e8e855ef949a29babe178b4a5 01-Jun-2016 Narayan Kamath <narayan@google.com> PackageManager: Dexopt core-apps during service bringup.

Code from these apps can be loaded by the system_server and so
we need to make sure they're compiled before their package contexts
are requested. Leaving them interpreted will cause performance issues.

On a Nexus 6P with WITH_DEXPREOPT=false, this adds an additional
26 seconds to every upgrade / first-boot and ends up optimizing a total
of 20 apps.

bug: 28639246
Change-Id: Ief3c0048fda4f1b1742fbf3e2476e65fa607a18a
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
47c170a7460e8455ffc07981916c400fa980433a 31-Mar-2016 Andreas Gampe <agampe@google.com> Package Manager: Use new DexFile function to upgrade filter

In case an app is shared, do not simply use "full" for compilation.
Instead, upgrade the asked-for filter to the non-guided version.

Bug: 27921071
Change-Id: I54735b61732e6a5c9dc62425d04bc740dd365083
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
6823f6d038c296cadda20e0b8d75ae08cbf677c3 26-Mar-2016 Andreas Gampe <agampe@google.com> PackageManager: Introduce first-boot dexopt reason

On first boot and when upgrading to N, there are no profiles for
apps. Add a new dexopt reason to allow to adjust the compiler
filter for this case.

Bug: 27689078
Change-Id: I7d68e02fe129c8dd12cb210df555bbb6dfc1487b
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
43fc2447df2354fcb7b843a86b1c266946ca5702 25-Mar-2016 Andreas Gampe <agampe@google.com> PackageManager: Move compilation reasons to PMS

Move the reasons to PackageManagerService (making them public) so
they can be used by clients.

Bug: 27189430
Change-Id: I30e1f823f9297e95c5b1e389004a4fd3052d5702
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java
bdd30d86ef98456161069d11481b2ccd25a11b4e 20-Mar-2016 Andreas Gampe <agampe@google.com> Frameworks/base: Refactor package manager

Introduce a mapping between dexopt reasons and compiler filters. Use
reasons in package manager and other classes, where possible.

Change PackageDexOptimizer to accept a compilation filter. Adapt for
the split-out profile merging. Pass compilation filter to installd.

Bug: 27689078
Change-Id: I8c0ea6f10fbfdbd096adecc52abfd2466d048fdc
/frameworks/base/services/core/java/com/android/server/pm/PackageManagerServiceCompilerMapping.java