Mulai 27 Maret 2025, sebaiknya gunakan android-latest-release
, bukan aosp-main
, untuk mem-build dan berkontribusi pada AOSP. Untuk mengetahui informasi selengkapnya, lihat Perubahan pada AOSP.
Konfigurasi Pengelola Paket (tidak digunakan lagi)
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
Penerapan dexopt di pengelola paket hanya berlaku untuk Android
13 dan yang lebih lama. Di Android 14, fitur ini diganti dengan ART
Service, dan akan dihapus dari pengelola paket di versi berikutnya. Untuk informasi tentang
cara mengonfigurasi Layanan ART, lihat
Konfigurasi Layanan ART.
Sejak Android 7.0, ada cara umum untuk menentukan tingkat
kompilasi/verifikasi yang terjadi di berbagai tahap.
Tingkat kompilasi dapat dikonfigurasi melalui properti sistem
dengan default:
pm.dexopt.install=speed-profile
Ini adalah filter kompilasi yang digunakan saat menginstal aplikasi melalui Google Play atau app store
lainnya. Sebaiknya filter penginstalan ditetapkan ke speed-profile
untuk mengaktifkan
penggunaan profil dari file metadata dex (lihat
blog).
Perhatikan bahwa jika profil tidak diberikan atau kosong, speed-profile
setara dengan verify
.
pm.dexopt.bg-dexopt=speed-profile
Ini adalah filter kompilasi yang digunakan saat perangkat tidak ada aktivitas dan sedang mengisi daya. Coba
filter compiler speed-profile
untuk memanfaatkan kompilasi terpandu profil dan menghemat
penyimpanan.
pm.dexopt.boot-after-ota=verify
Filter kompilasi yang digunakan setelah update over-the-air. Sebaiknya
gunakan filter compiler verify
untuk opsi
ini guna menghindari waktu booting yang sangat lama.
pm.dexopt.first-boot=verify
-
Filter kompilasi untuk pertama kalinya perangkat melakukan booting. Filter
yang digunakan di sini hanya memengaruhi waktu booting setelah pabrik. Sebaiknya gunakan filter
verify
agar pengguna tidak perlu menunggu lama sebelum
menggunakan ponsel untuk pertama kalinya. Perhatikan bahwa jika semua aplikasi dalam
image sistem sudah dikompilasi dengan verify
, speed-profile
, atau
speed
dengan konteks class loader yang tepat, kompilasi pada booting pertama akan
dilewatkan, dan pm.dexopt.first-boot
tidak akan berpengaruh.
Konten dan contoh kode di halaman ini tunduk kepada lisensi yang dijelaskan dalam Lisensi Konten. Java dan OpenJDK adalah merek dagang atau merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2025-07-27 UTC.
[[["Mudah dipahami","easyToUnderstand","thumb-up"],["Memecahkan masalah saya","solvedMyProblem","thumb-up"],["Lainnya","otherUp","thumb-up"]],[["Informasi yang saya butuhkan tidak ada","missingTheInformationINeed","thumb-down"],["Terlalu rumit/langkahnya terlalu banyak","tooComplicatedTooManySteps","thumb-down"],["Sudah usang","outOfDate","thumb-down"],["Masalah terjemahan","translationIssue","thumb-down"],["Masalah kode / contoh","samplesCodeIssue","thumb-down"],["Lainnya","otherDown","thumb-down"]],["Terakhir diperbarui pada 2025-07-27 UTC."],[],[],null,["# Package Manager Configuration (deprecated)\n\nThe dexopt implementation in the package manager only applies to Android\n13 and lower. In Android 14, it is replaced by ART\nService, and it will be removed from the package manager in the next version. For information about\nconfiguring ART Service, see\n[ART Service Configuration](/docs/core/runtime/configure/art-service).\n\n\nSince Android 7.0, there's a generic way to specify the level of\ncompilation/verification that happened at various stages.\nThe compilation levels can be configured via system properties\nwith the defaults being:\n\n- `pm.dexopt.install=speed-profile`\n- This is the compilation filter used when installing applications through Google Play or other app stores. We recommend the install filter be set to `speed-profile` in order to enable the use of profiles from the dex metadata files (see [blog](https://android-developers.googleblog.com/2019/04/improving-app-performance-with-art.html)). Note that if a profile isn't provided or if it is empty, `speed-profile` is equivalent to `verify`.\n- `pm.dexopt.bg-dexopt=speed-profile`\n- This is the compilation filter used when the device is idle and charging. Try the `speed-profile` compiler filter to take advantage of profile-guided compilation and save on storage.\n- `pm.dexopt.boot-after-ota=verify`\n- The compilation filter used after an over-the-air update. We **strongly** recommend the `verify` compiler filter for this option to avoid very long boot times.\n- `pm.dexopt.first-boot=verify`\n-\n The compilation filter for the first time the device ever boots. The filter\n used here only affects the boot time after factory. We recommend the filter\n `verify` for it to avoid long times before a user gets to\n use the phone for the very first time. Note that if all applications in\n the system image are already compiled with `verify`, `speed-profile`, or\n `speed` with the right class loader context, the compilation on the first boot will be\n skipped, and `pm.dexopt.first-boot` will have no effect."]]