获取运行Android 8 Oreo的设备的CPU使用率 [英] Get CPU usage of a device running Android 8 Oreo
问题描述
我真的很困惑.我刚刚注意到,从Android 8开始,所有系统调用(例如/proc/stat)都将被禁用.好的,但是如何解决Android 8中的CPU使用率问题?根本没有系统调用.有一些我不熟悉的API吗?
I'm really confused. I have just noticed that starting from Android 8 all system calls like /proc/stat will be disabled. Ok, but what is work around to get CPU Usage in Android 8? No system calls at all. Is there some API that I'm not familiar with?
我真的希望有我现在看不到的解决方案.
I really hope that there is solution which I can't see now.
推荐答案
否,非系统应用程序的所有/proc/stat已被禁用,作为辅助渠道.
No, all of /proc/stat has been disabled for non-System apps, as a side-channel.
更多信息,请点击此处,获得Google的官方回复: https://issuetracker.google.com/issues/37140047
More information, with an official response from Google here: https://issuetracker.google.com/issues/37140047
这篇关于获取运行Android 8 Oreo的设备的CPU使用率的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!