commit | 29b243bb3e4a5735a0cf2d4da8381c66734562be | [log] [tgz] |
---|---|---|
author | Jun Lan <ljlan@google.com> | Wed Nov 01 16:05:06 2023 +0800 |
committer | Jun Lan <ljlan@google.com> | Wed Nov 01 17:09:43 2023 +0800 |
tree | 1f92fbde2d63ca47df94a9123b0fcccdb36a7345 | |
parent | 1742fa2ed0cd85f38aff831adb775ca4494710eb [diff] |
Add cache for PackageManager.getPackageUid to improvement performance Context: `PackageManager.getPackageUid` is IPC which could be slow. Add a map in BatteryDiffEntry to cache the data. The cache lifecycle would be the same as other cache in BatteryDiffEntry. Test: manual Bug: 304439237 Fix: 304439237 Change-Id: I98d9c8cfee24dd43e9a4037b1b61c8353bf1bcea