From 3926ad2c0f45f909c253d8d21f2e3023c0b60516 Mon Sep 17 00:00:00 2001 From: Mathieu Chartier Date: Mon, 11 Nov 2019 13:15:34 -0800 Subject: Update ArtManagerService for new profilebootclasspath properties Added logic to use profilebootclasspath properties instead of profilebootimage. Bug: 139883463 Bug: 144173681 Test: manual (cherry picked from commit 88db67cd49ab9458063e0c452755ca462d1f4e61) Exempt-From-Owner-Approval: Cherry pick Merged-In: I5b2947acbb77476b6dc7eed94e713ef7e8fb8f07 Change-Id: I6e5e69287cec0bea0a1ccf3756c8814454f6bbfa --- services/core/java/com/android/server/pm/dex/ArtManagerService.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/services/core/java/com/android/server/pm/dex/ArtManagerService.java b/services/core/java/com/android/server/pm/dex/ArtManagerService.java index 9948a3ad47da..b8d3ca56e368 100644 --- a/services/core/java/com/android/server/pm/dex/ArtManagerService.java +++ b/services/core/java/com/android/server/pm/dex/ArtManagerService.java @@ -317,9 +317,13 @@ public class ArtManagerService extends android.content.pm.dex.IArtManager.Stub { case ArtManager.PROFILE_APPS : return SystemProperties.getBoolean("dalvik.vm.usejitprofiles", false); case ArtManager.PROFILE_BOOT_IMAGE: + // The device config property overrides the system property version. + boolean profileBootClassPath = SystemProperties.getBoolean( + "persist.device_config.runtime_native_boot.profilebootclasspath", + SystemProperties.getBoolean("dalvik.vm.profilebootclasspath", false)); return (Build.IS_USERDEBUG || Build.IS_ENG) && SystemProperties.getBoolean("dalvik.vm.usejitprofiles", false) && - SystemProperties.getBoolean("dalvik.vm.profilebootimage", false); + profileBootClassPath; default: throw new IllegalArgumentException("Invalid profile type:" + profileType); } -- cgit v1.2.3-59-g8ed1b