No description
Find a file
Danny Lin 1aea24d503 init.rc: Disable native stats collection service
When opening and closing activities in Settings, a measurably
significant amount of CPU time is spent processing and logging stats
events in statsd:

0.02%     /apex/com.android.os.statsd/lib64/libstatspull.so                                                                                         @plt
0.01%     /apex/com.android.os.statsd/bin/statsd                                                                                                    @plt
0.01%     /apex/com.android.os.statsd/bin/statsd                                                                                                    SocketListener::runListener()
0.01%     /apex/com.android.os.statsd/bin/statsd                                                                                                    android::os::statsd::LogEvent::parseBuffer(unsigned char*, unsigned long)
0.01%     /apex/com.android.os.statsd/bin/statsd                                                                                                    android::os::statsd::LogEvent::parseAnnotations(unsigned char, int)

Over longer device uptimes with real-world usage, statsd uses a
substantial amount of total CPU time. We have no use for the stats
recorded by statsd, so disable the service entirely to save CPU in
potential hotpaths.

This is the system/core part of the change; changes to frameworks/base
are also required.

Test: simpleperf record -a; verify that statsd no longer appears in
      sample hits
Change-Id: Idf6fdb0eff987169bd5f370dd72315e831a669e6
Signed-off-by: Hưng Phan <phandinhhungvp2001@gmail.com>
Signed-off-by: Dmitrii <bankersenator@gmail.com>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
Signed-off-by: rmp22 <195054967+rmp22@users.noreply.github.com>
2025-05-16 23:25:48 +00:00
bootstat bootstat: avoid vector<const T> 2024-06-28 00:52:41 -07:00
cli-test [LSC] Add LOCAL_LICENSE_KINDS to system/core 2021-02-19 12:59:05 -08:00
code_coverage Disable code_coverage.other for riscv64 2022-10-13 13:49:10 -07:00
debuggerd Android 15.0.0 Release 20 (BP1A.250305.019) 2025-03-09 07:31:20 +02:00
diagnose_usb Support building diagnose_usb against musl 2021-12-16 14:04:06 -08:00
fastboot Android 15.0.0 Release 20 (BP1A.250305.019) 2025-03-09 07:31:20 +02:00
fs_mgr fs_mgr: always use "check_at_most_once" 2025-05-16 23:25:48 +00:00
gatekeeperd gatekeeperd_service_fuzzer: Add signal() to handle SIGPIPE 2024-11-29 15:02:21 +05:30
healthd Android 15.0.0 Release 20 (BP1A.250305.019) 2025-03-09 07:31:20 +02:00
include Remove include/backtrace symlink. 2020-10-20 12:46:14 -07:00
init init: Migrate vendor_init_defaults to select() 2025-04-25 00:00:14 +03:00
janitors Add maco to OWNERS. 2024-05-06 13:22:28 +00:00
libappfuse [LSC] Add LOCAL_LICENSE_KINDS to system/core 2021-02-19 12:59:05 -08:00
libasyncio Set min_sdk_version 2021-12-02 09:23:42 +09:00
libcrypto_utils Remove VNDK definition(s) 2024-03-15 08:19:44 +00:00
libcutils Revert "libprocessgroup: Remove schedtune support" 2025-03-10 13:28:31 -04:00
libgrallocusage Make apex_available explicit 2022-02-09 11:37:19 -08:00
libkeyutils Make libfs_mgr dependencies vendor_ramdisk_available. 2021-07-23 16:50:06 -07:00
libmodprobe libmodprobe: add support for dynamic module options 2024-10-25 09:27:45 +00:00
libnetutils Remove VNDK definition(s) 2024-03-15 08:19:44 +00:00
libpackagelistparser parse_line: allow -1 for apexes and sdk libraries. 2024-04-26 15:30:30 +00:00
libprocessgroup Perf: Adjust the bg task slack 2025-05-16 23:25:48 +00:00
libsparse libsparse: Add simg2img_static target for host 2024-09-09 03:28:46 +03:00
libstats Merge "Remove libstats*_lazy tests from MTS" into main 2024-10-08 02:13:26 +00:00
libsuspend libsuspend: vendor_available. 2021-11-02 13:52:40 -07:00
libsync Remove NDK exports 2024-09-03 20:40:28 +00:00
libsystem Add COLOR_MODE_DISPLAY_BT2020 to graphics header. 2022-12-01 22:25:40 -08:00
libsysutils Android 15.0.0 Release 20 (BP1A.250305.019) 2025-03-09 07:31:20 +02:00
libusbhost Remove VNDK definition(s) 2024-03-15 08:19:44 +00:00
libutils libutils OWNERS for shayba@ 2024-11-26 23:44:17 +00:00
libvendorsupport Revert^2 "Deprecating libvendorsupport_llndk_headers" 2024-11-09 02:41:13 +00:00
libvndksupport try llndk-deprecate 2023-12-21 02:09:14 +00:00
llkd llkd: Include llkd-debuggable.rc in eng builds only 2024-09-09 03:28:46 +03:00
mini_keyctl Remove alanstokes@google.com from mini_keyctl/OWNERS 2024-07-09 21:12:32 +00:00
mkbootfs read() can return fewer bytes than requested 2024-10-30 10:35:52 -07:00
property_service Remove OEM_UNLOCK_PROP usage 2024-09-22 03:51:29 +00:00
reboot Define reboot.recovery and watchdogd.recovery 2024-12-06 23:18:18 +00:00
rootdir init.rc: Disable native stats collection service 2025-05-16 23:25:48 +00:00
run-as run-as: remove a special case. 2023-11-10 22:02:00 +00:00
sdcard [LSC] Add LOCAL_LICENSE_KINDS to system/core 2021-02-19 12:59:05 -08:00
shell_and_utilities Replace partition-specific toybox make module with soong modules 2024-12-05 18:50:11 +00:00
storaged use V4 Health HAL 2024-11-20 01:07:41 +00:00
toolbox Define toolbox.recovery 2024-12-06 01:51:35 +00:00
trusty Merge "Update trusty to use secretkeeper hal V1" into main 2024-12-04 21:22:00 +00:00
usbd usb: migration to USB gadget AIDL 2023-01-10 11:24:36 +08:00
watchdogd Define reboot.recovery and watchdogd.recovery 2024-12-06 23:18:18 +00:00
.clang-format
.clang-format-2 Move clang-formats to build. 2019-01-18 14:26:33 -08:00
.clang-format-4 Move clang-formats to build. 2019-01-18 14:26:33 -08:00
.gitignore
Android.bp Add dirgroup for trusty genrule 2024-10-10 18:21:29 +09:00
CleanSpec.mk snapshotctl don't auto-merge. 2020-03-03 13:19:49 -08:00
MODULE_LICENSE_APACHE2
OWNERS Add bug component to system/core 2023-07-26 07:57:58 -07:00
PREUPLOAD.cfg PREUPLOAD += bpfmt 2024-06-04 23:10:21 +00:00
rustfmt.toml Configure rustfmt for preupload hook 2022-04-06 21:11:09 +00:00