Merge "PackageManager: Skip dexopt on install for debuggable apps" into pi-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
f22fd65a25
@@ -17419,6 +17419,7 @@ public class PackageManagerService extends IPackageManager.Stub
|
|||||||
// 1) it is not forward locked.
|
// 1) it is not forward locked.
|
||||||
// 2) it is not on on an external ASEC container.
|
// 2) it is not on on an external ASEC container.
|
||||||
// 3) it is not an instant app or if it is then dexopt is enabled via gservices.
|
// 3) it is not an instant app or if it is then dexopt is enabled via gservices.
|
||||||
|
// 4) it is not debuggable.
|
||||||
//
|
//
|
||||||
// Note that we do not dexopt instant apps by default. dexopt can take some time to
|
// Note that we do not dexopt instant apps by default. dexopt can take some time to
|
||||||
// complete, so we skip this step during installation. Instead, we'll take extra time
|
// complete, so we skip this step during installation. Instead, we'll take extra time
|
||||||
@@ -17430,7 +17431,8 @@ public class PackageManagerService extends IPackageManager.Stub
|
|||||||
&& !forwardLocked
|
&& !forwardLocked
|
||||||
&& !pkg.applicationInfo.isExternalAsec()
|
&& !pkg.applicationInfo.isExternalAsec()
|
||||||
&& (!instantApp || Global.getInt(mContext.getContentResolver(),
|
&& (!instantApp || Global.getInt(mContext.getContentResolver(),
|
||||||
Global.INSTANT_APP_DEXOPT_ENABLED, 0) != 0);
|
Global.INSTANT_APP_DEXOPT_ENABLED, 0) != 0)
|
||||||
|
&& ((pkg.applicationInfo.flags & ApplicationInfo.FLAG_DEBUGGABLE) == 0);
|
||||||
|
|
||||||
if (performDexopt) {
|
if (performDexopt) {
|
||||||
Trace.traceBegin(TRACE_TAG_PACKAGE_MANAGER, "dexopt");
|
Trace.traceBegin(TRACE_TAG_PACKAGE_MANAGER, "dexopt");
|
||||||
|
|||||||
Reference in New Issue
Block a user