android / ndk

The Android Native Development Kit
1.97k stars 255 forks source link

[BUG]Can not get boot-time profile #1792

Open lxsmall0624 opened 1 year ago

lxsmall0624 commented 1 year ago

Description

After running adb root adb shell simpleperf boot-record --enable "-a -g --duration 10 --exclude-perf""' adb reboot

I can not get the profile data under /data/simpleperf_boot_data. Look likes simpleperf didn't work in booting.

Affected versions

r25

Canary version

No response

Host OS

Windows

Host OS version

WIN10

Affected ABIs

armeabi-v7a

Build system

ndk-build

Other build system

No response

minSdkVersion

extras-master-simpleperf

Device API level

No response

yabinc commented 1 year ago

On which android version are you using the command? The function needs support of init script in https://cs.android.com/android/platform/superproject/+/master:system/extras/simpleperf/simpleperf.rc, which doesn't exist before android T. To help debug, can you upload result of getprop persist.simpleperf.boot_record and logcat | grep simpleperf before and after reboot?