yc9559 / dfps

Dynamic screen refresh rate controller for Android 10+
Apache License 2.0
378 stars 17 forks source link

Fix "Per App profiles not working on Android 13" #9

Closed hamjin closed 1 year ago

hamjin commented 1 year ago

This fixed #7 and parse more optimization flags to the linker

Since Android 13, we can't monitor cgroups' changing by inotify. So I create a new thread to monitor top app. This is not the best way to fix it but works for me.

The optimization flags comes from @asto18089 's idea. It is better to parst -fuse-ld=lld to clang, but we don't need it in NDK environment.

Stardusstt commented 1 year ago

thread "Android13Worker" , seems to be killed? when screen is lock. ( Android 13, MIUI 14) this cause per app profiles not working , need to restart the dfps to create "Android13Worker" again.

hamjin commented 1 year ago

thread "Android13Worker" , seems to be killed? when screen is lock. ( Android 13, MIUI 14) this cause per app profiles not working , need to restart the dfps to create "Android13Worker" again.

Line 42 is wrong.

yc9559 commented 1 year ago

Fixed in cgroup_listener: Fix not working in Android 13