Files
frameworks_base/docs/html/tools/help/am-gpu.jd
Cheryl Potter 5fc7099e1e docs: Polish Android Monitor pages
b/26279420

Change-Id: Ic2ccf9510f51adeb843f7aff9197d59e7a532fe2
2016-04-26 15:36:41 -07:00

90 lines
2.8 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
page.title=GPU Monitor
parent.title=Android Monitor
parent.link=android-monitor.html
meta.tags="android, performance, profiling, tools, monitor"
page.tags="android", "performance", "profiling", "tools", "monitor"
page.metaDescription=Use the GPU Monitor for a visual representation of how much time it takes to render the frames of a UI window. Use this information to optimize the code that displays graphics and conserve memory.
page.image=tools/help/thumbnails/am-gpumon.png
page.article=true
@jd:body
<div id="qv-wrapper">
<div id="qv">
<h2>In this document</h2>
<ol>
<li><a href="#running">Displaying a Running App in the GPU Monitor</a></li>
</ol>
</div>
</div>
<p>
The GPU Monitor gives you a quick visual representation of how much time it takes to render the
frames of a UI window. It profiles the amount of time it takes for the render thread to prepare,
process, and execute the draw commands. The GPU Monitor can help you to:
</p>
<ul>
<li>Quickly see how a UI window performs.
</li>
<li>Identify whether any part of the rendering pipeline stands out in using processing time.
</li>
<li>Look for spikes in frame rendering time associated with user or program actions.
</li>
</ul>
<p>
For example, if displaying a static photo continues to take Graphics Processor Unit
(GPU) resources long after it has finished
drawing on the screen, thats a likely candidate for optimization.
</p>
<h2 id="running">
Displaying a Running App in the GPU Monitor
</h2>
<p>
To display an app running on a particular device or emulator in the GPU Monitor:
</p>
<ol>
<li>Meet the <a href=
"{@docRoot}tools/help/am-basics.html#byb">prerequisites and dependencies</a>.
</li>
<li>Open an app project.
</li>
<li><a href=
"{@docRoot}tools/building/building-studio.html#RunningApp">Run the app</a> on a hardware device or
emulator.
</li>
<li>
<a href="{@docRoot}tools/help/am-basics.html#displaying">Display Android Monitor</a>.
</li>
<li>Click the <strong>Monitors</strong> tab and <a href=
"{@docRoot}tools/help/am-basics.html#rearranging">display the GPU Monitor</a>.
</li>
<li>Enable the GPU Monitor by clicking Pause <img src="{@docRoot}images/tools/am-ipause.png"
style="vertical-align:sub;margin:0;height:17px" alt="Pause icon" /> to deselect it.
</li>
<p>
Any GPU usage begins to appear in the GPU Monitor:
</p>
<img src="{@docRoot}images/tools/am-gpumon2.png" style="vertical-align:sub;margin:0" />
<p>
The y-axis is the amount of time it takes the GPU to execute, process, prepare, and draw frames,
in milliseconds. The x-axis records the time elapsed; it starts with seconds, and then minutes
and seconds, and so on.
</p>
<li>To stop the GPU Monitor, click Pause <img src="{@docRoot}images/tools/am-ipause.png" style="vertical-align:sub;margin:0;height:17px" alt="Pause icon" /> again to select
it.
</li>
</ol>