Performance TestCase Interface in Android

Has anybody implemented the PerformanceTestCase provided by android and got some results...If you have done it please provide some source code,it will be really helpful...

Here is the android link: http://developer.android.com/reference/android/test/PerformanceTestCase.html

I have used the traceview tool but I need results like CPU cycles used,memory used by the app either in real-time or after its execution..


Asked by: Emily534 | Posted: 20-01-2022






Answer 1

There is a wrapper class for performance test case in android source code called as performance test base..you can use that class to get performance parameters...Also see the performance collector and performance collector test class for more information..

Answered by: Maya280 | Posted: 21-02-2022



Similar questions

Does using interface in android app hurts app performance

In one presentation deck of Reto Meier, I read his suggestion to prefer virtual methods over interface but there were no more explanation. Apart from the runtime overhead is there anything else which specifically hurts app performance in android ? Because to make code more flexible and readable I heavily use interface in my android project.


performance - android slow interface on zenfone 5

I'm developing app in android studio using standard android interface. Problem is that all interface is very laggy on Asus zenfone 5. Listviews scroll very slow and freezy, animation (rotation, translation) also very slow and laggy. At my neighbors Nexus 5 all is fine, in emulator all also fine. But on my zenfone are problems. May be it because of Intel chip set?


performance - Android resource hungry operations

I am using JSON to receive data from the web service, creating text to JSON object is resource hungry operation. I have to load images from the web, I am lazy loading images in the async process how can I compress and make the cache ?? After the crash, how can I stop re-launching activity? How can I know how much memory remaining and Android OS will kill my...


performance - Android ListView Refresh Single Row

After I have gotten the data for a single row of a ListView, I want to update that single row. Currently I am using notifyDataSetChanged(); but that makes the View react very slowly. Are there any other solutions?


android OpenGL ES simple Tile generator performance problem

following this question : Best approach for oldschool 2D zelda-like game Thank to previous replies, and with a major inspiration from http://insanitydesign.com/wp/projects/nehe-android-ports/ , i started to build a ...


Streaming video playback performance issues with background tasks on Android

I have developed a little application that can play video from a rstp streaming sever (darwin in this case, but this is not relevant) by means of the VideoView widget (I have tried Mplayer+SurfaceView approach too). I use Wifi connection for this. The video plays just smooth when video is the only task. The small application should carry out other tasks at the same time such as continously discover...


Replace standard Android JSON parser for better performance?

I know that Android has a JSON parser baked in but I was wondering if it was worth using something that offered better performance (like Jackson - see http://jackson.codehaus.org/) ? Anybody tried that ?


dalvik - Changing coding style due to Android GC performance, how far is too far?

I keep hearing that Android applications should try to limit the number of objects created in order to reduce the workload on the garbage collector. It makes sense that you may not want to created massive numbers of objects to track on a limited memory footprint, for example on a traditional server application created 100,000 objects within a few seconds would not be unheard of. The problem is how far should I tak...


android - For-Loop Performance Oddity

I just noticed something concerning for-loop performance that seems to fly in the face of the recommendations given by the Google Android team. Look at the following code: package com.jackcholt; import android.app.Activity; import android.os.Bundle; import android.util.Log; public class Main extends Activity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(save...


performance - How to cache and store objects and set an expire policy in android?

I have an app fetch data from internet, for better performance and bandwidth, I need to implement a cache layer. There are two different data coming from the internet, one is changing every one hour and another one does not change basically. So for the first type of data, I need to implement an expire policy to make it self deleted after it was created for 1 hour, and when user request that data, I will check the s...


How does Android emulator performance compare to real device performance?

I'm looking into writing an Android game, tough I don't curerntly own an Android device. For those of you who own a device, how does the performance on the emulator relate to real device performance? I'm especially interested in graphics related tasks. This obviously depends on both the machine running the emulator, and the specific device in question, but I'm talking rough numbers here. This question is a ...


performance - Is it better to use GL_FIXED or GL_FLOAT on Android

I would have assumed that GL_FIXED was faster, but the iPhone docs actually say to use GL_FLOAT because GL_FIXED has to be converted to GL_FLOAT. Is it the same on Android? I suppose it varies by phone, but what about recent popular ones (Nexus One, Droid/Milestone, etc.)? Bonus points: This appears to be completely undocumented (e.g. search google for GL_FI...






Still can't find your answer? Check out these communities...



Android Google Support | Android Community | Android Community (Facebook) | Dev.io Android



top