I made an application and I wanted to see if I can improve performance by running a traceview on a certain activity + it’s background tasks.
This link points to an image from traceview. As you can see there are 2 colors that are taking the most time + processor.
- The blue color is from
drawBitmap. (I use a header logo, a repeating
header background and another background that repeats over the whole
screen, all described in XML layout file). - The green color is something called
dalvik/system/VMDebug.startGC ()V
My questions:
- Can I do something to make this drawBitmap less expensive ? (I would
however like to keep all images on the screen) - What is this VMDebug thing? Can’t seem to find much about it via
Google
It sounds like you may be able to optimize your bitmap drawing,(you mention a background that is drawn repeatedly)
VMDebug is the dalvik debug monitor
the startGC() function is called to start garbage collection