检查应用程序的性能?
嘿,我完成了我的代码,一切都正常运行,但我想知道,因为智能手机的电池、CPU 有限。我如何检查我的应用程序是否能在旧手机上正常运行?如何检查我的应用程序是否消耗手机电池? 谢谢
Hey, I finished my code and everything works as it should but I'm wondering since smartphones have limited battery, CPU .. How can I check if my application will run good on older phones? and how can I check if my app consumes the phones battery?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
真正了解它的唯一方法是在手机中测试应用程序。
也就是说,您可以对其进行分析,并根据您的应用程序的 CPU 密集程度、运行时间进行有根据的猜测,如果您有连续使用 cpu 的服务等。
需要考虑以下几点:
观看此视频:http://www.google.com/events/io/2009/sessions/CodingLifeBatteryLife.html
The only way to really know it to test the app in the phones.
That said, you can profile it and make educated guesses based on how CPU-intensive is your app, for how long is it running, if you have services using cpu continuously, etc.
There are a few things to consider:
Take a look at this video: http://www.google.com/events/io/2009/sessions/CodingLifeBatteryLife.html
还看一下
http://developer.android.com/guide/developing/debugging/debugging -tracing.html
Also take a look on
http://developer.android.com/guide/developing/debugging/debugging-tracing.html