summaryrefslogtreecommitdiffstats
path: root/docs/html/tools/studio/index.jd
diff options
context:
space:
mode:
authorRich Slogar <rslogar@google.com>2015-08-17 15:38:33 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2015-08-17 15:38:33 +0000
commit1614f115c38c68d49a74c2553a68a46bd2f4c913 (patch)
treec7b3e4bfaf5d4720b72cbac881f20ceb2ec647fd /docs/html/tools/studio/index.jd
parent605c890bf0e01235bb538c9175495830e77f0783 (diff)
parent8f0d5451302c48dcaed262e9f3212c92ff53ffda (diff)
downloadframeworks_base-1614f115c38c68d49a74c2553a68a46bd2f4c913.zip
frameworks_base-1614f115c38c68d49a74c2553a68a46bd2f4c913.tar.gz
frameworks_base-1614f115c38c68d49a74c2553a68a46bd2f4c913.tar.bz2
am 8f0d5451: am e5fe2468: docs: studio 1.3 allocation tracker
* commit '8f0d5451302c48dcaed262e9f3212c92ff53ffda': docs: studio 1.3 allocation tracker
Diffstat (limited to 'docs/html/tools/studio/index.jd')
-rw-r--r--docs/html/tools/studio/index.jd24
1 files changed, 24 insertions, 0 deletions
diff --git a/docs/html/tools/studio/index.jd b/docs/html/tools/studio/index.jd
index bbb4edc..43cb2fe 100644
--- a/docs/html/tools/studio/index.jd
+++ b/docs/html/tools/studio/index.jd
@@ -226,6 +226,30 @@ snapshot in the <em>Captures</em> view and select <strong>Export to standard .hp
+<h4 id="alloc-tracker">Allocation tracker </h4>
+<p>Android Studio allows you to track memory allocation as it monitors memory use. Tracking memory
+allocation allows you to monitor where objects are being allocated when you perform certain actions.
+Knowing these allocations enables you to adjust the method
+calls related to those actions to optimize your app's performance and memory use. </p>
+
+<img src="{@docRoot}images/tools/studio-allocation-tracker.png" alt="" />
+ <p class="img-caption"><strong>Figure 6.</strong> Allocation tracker.</p>
+
+<p>Perform the following steps to track and analyze allocations: </p>
+<ol>
+ <li>Click the Start/Stop Allocation Tracking icon
+ (<img src="{@docRoot}images/tools/studio-allocation-tracker-icon.png" style="vertical-align:bottom;margin:0;height:17px"/>) in the
+ <a href="#mem-cpu">Memory Monitor</a>. Android Studio starts tracking memory allocations.</li>
+ <li>Perform the tasks whose mallocs you want to track. </li>
+ <li>Click the Start/Stop Allocation Tracking icon again. Android Studio stops tracking mallocs
+ and saves the data to a file named <code>Allocation-yyyy.mm.dd-hh.mm.ss.alloc</code>. The
+ resulting file appears in the <em>Captures</em> tab. </li>
+ <li>Double-click the file to open it in the allocation viewer.
+ <p>The allocation viewer allows you to view and analyze the allocations your app made while
+ running. </p> </li>
+</ol>
+
+
<h3>Data file access</h3>
<p>The Android SDK tools, such as <a href="{@docRoot}tools/help/systrace.html">Systrace</a>,
<a href="{@docRoot}tools/help/logcat.html">logcat</a>, and