blob: b38b7c4df90faa002abd49368f4c64847d7bc55e [file] [log] [blame]
Ryan Savitski29082bf2020-02-12 15:13:51 +00001# Copyright (C) 2020 The Android Open Source Project
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15service traced_perf /system/bin/traced_perf
16 class late_start
17 disabled
18 # socket for receiving /proc/pid/{maps,mem} file descriptors
19 socket traced_perf stream 0666 root root
20 user nobody
21 # readproc to stat(/proc/pid) to find out UID of processes, and read
22 # /proc/pid/cmdline.
23 group nobody readproc
24 # KILL for sending BIONIC_SIGNAL_PROFILER.
25 # DAC_READ_SEARCH for stack unwinding and on-device symbolization (requires
26 # opening libraries/executables for sections not already mapped in).
27 capabilities KILL DAC_READ_SEARCH
28 writepid /dev/cpuset/foreground/tasks
29
30on property:persist.traced_perf.enable=1
31 start traced_perf
32on property:persist.traced_perf.enable=0
33 stop traced_perf
34