xref: /aosp_15_r20/art/artd/README.md (revision 795d594fd825385562da6b089ea9b2033f3abf5a)
1*795d594fSAndroid Build Coastguard Worker## artd
2*795d594fSAndroid Build Coastguard Worker
3*795d594fSAndroid Build Coastguard Workerartd is a component of ART Service. It is a shim service to do tasks that
4*795d594fSAndroid Build Coastguard Workerrequire elevated permissions that are not available to system_server, such as
5*795d594fSAndroid Build Coastguard Workermanipulation of the file system and invoking dex2oat. It publishes a binder
6*795d594fSAndroid Build Coastguard Workerinterface that is internal to ART service's Java code. When it invokes other
7*795d594fSAndroid Build Coastguard Workerbinaries, it passes input and output files as FDs and drops capability before
8*795d594fSAndroid Build Coastguard Workerexec.
9*795d594fSAndroid Build Coastguard Worker
10*795d594fSAndroid Build Coastguard Worker### System properties
11*795d594fSAndroid Build Coastguard Worker
12*795d594fSAndroid Build Coastguard Workerartd can be controlled by the system properties listed below. Note that the list
13*795d594fSAndroid Build Coastguard Workerdoesn't include options passed to dex2oat and other processes.
14*795d594fSAndroid Build Coastguard Worker
15*795d594fSAndroid Build Coastguard Worker- `dalvik.vm.artd-verbose`: Log verbosity of the artd process. The syntax is the
16*795d594fSAndroid Build Coastguard Worker  same as the runtime's `-verbose` flag.
17*795d594fSAndroid Build Coastguard Worker
18*795d594fSAndroid Build Coastguard Worker### The `--pre-reboot` flag
19*795d594fSAndroid Build Coastguard Worker
20*795d594fSAndroid Build Coastguard Workerartd can be run in Pre-reboot mode through the `--pre-reboot` flag. The
21*795d594fSAndroid Build Coastguard WorkerPre-reboot mode is for generating outputs for Pre-reboot Dexopt. The flag does
22*795d594fSAndroid Build Coastguard Workernot change the actual behavior, but only affects the service name, the log tag,
23*795d594fSAndroid Build Coastguard Workera few return checks, etc. Note that how artd addresses input files and output
24*795d594fSAndroid Build Coastguard Workerfiles is solely determined by AIDL arguments and is **not** affected by the
25*795d594fSAndroid Build Coastguard Worker`--pre-reboot` flag.
26