Assigned
Status Update
Comments
lo...@gmail.com <lo...@gmail.com> #2
Update: according to the trace, dex2oat starts at the same moment as the application. So i guess, the problem lays in xiaomi firmware that starts the optimization with the application during benchmark
Description
Component used: jetpack macrobenchmark Version used: 1.4.0-alpha07 Devices/Android versions reproduced on: miui android 12 Xiaomi Redmi Note 9
On some perfetto traces during benchmark with
CompilationMode.Partial(warmUpIterations=3)
i found that dex files are opening terribly slow (up to 10 seconds to open dex files)I checked what's going on with the compilation and found that i have run-from-apk status of compilation with unknown reason:
arm64: [status=run-from-apk] [reason=unknown]
I then opened top and found
dex2oat32
still running during the test after the compilation should have already finished loading cpu up to 500%After some iterations it led to system being fully frozen
The problem is that benchmark executes
cmd package compile -f -m speed-profile x.y.z
to compile application, and on xiaomi by some reason it instantly returns success even though dex2oat is still runningI think it would be good to check if dex2oat32 or dex2oat64 is not running before the test and wait for it to finish