Android gltrace tools——Snapdragon Profiler

Snapdragon Profiler

1.概述

Qualcomm®Snapdragon Profiler是可以运行在Windows,Macintosh和Linux计算机系统上的分析软件。
Snapdragon Profiler允许开发人员分析CPU,GPU,DSP *,内存,电源,散热,和网络数据,找到并修复性能瓶颈。

“这款工具通过三种数据捕获模式显示应用程序的CPU、GPU、DSP、内存、功率、网络连接和设备运行时的发热数据,从多个不同的角度展现设备性能。实时(Realtime)模式下,您可以在设备应用程序运行的同时查看实时度量数据。跟踪捕获(Trace Capture)模式仅捕获Snapdragon处理器驱动设备可用的跟踪事件和数据。快照捕获(Snapshot Capture)模式下,开发人员可借助图形应用程序捕获和调试其OpenGL ES应用程序框架,包括单步调试绘制指令,查看和编辑着色器、程序、纹理以及查看像素历史的能力。”

2.安装,启动和连接

2.1 安装

Latest Mono Framework (4.0.4 or above)

*EXAMPLE INSTALL*
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
echo "deb http://download.mono-project.com/repo/debian wheezy main" | sudo tee /etc/apt/sources.list.d/mono-xamarin.list
sudo apt-get update
sudo apt-get install mono-complete

Latest libc+ + C++ Runtime

*EXAMPLE INSTALL*
sudo apt-get install libc++1 

Install Java Runtime (1.7.0_79) or later

*EXAMPLE INSTALL*
sudo apt-get install default-jre

Install adb (1.0.31) or later

*EXAMPLE INSTALL*
sudo apt-get install android-tools-adb
*Make sure that adb is in the system path*

Install Snapdragon Profiler (in preferred directory)

tar zxvf SnapdragonProfiler_Release_External_Linux.tar.gz

2.2 启动

Execute run_sdp.sh

./run_sdp.sh

Note that the path (./) is included to be able to run from current directory

2.3 连接

1、点击Connect to Device

这里写图片描述

2、点击connect

这里写图片描述

3、连接成功

这里写图片描述

3.Start Page

与Visual Studio类似,Snapdragon Profiler起始页提供了对主Profiler功能的轻松访问:
- Connect to a Device
- Realtime profiling
- New Trace Capture
- New Snapshot Capture

这里写图片描述

3.1 Realtime profiling

Realtime mode允许在Snapdragon支持的设备上运行应用程序时流式传输和查看实时性能指标。
Realtime mode从嵌入式图形驱动程序中绘制收集实时GPU和系统性能数据流,包括系统和进程指标。

系统指标包括:
- CPU Core Frequency
- CPU Core Load
- CPU Core Utilization
- GPU General
- GPU Memory Stats
- GPU Shader Processing
- GPU Stalls
- Network - Cellular
- Network – Wi-Fi
- Power
- Primitive Processing
- System Memory
- Thermal

进程指标包括:
- CPU
- EGL (not available for every process)
- GPU General (not available for every process)
- GPU Memory Stats (not available for every process)
- GPU Shader Processing (not available for every process)
- GPU Stalls (not available for every process)
- Memory
- Network
- Primitive Processing (not available for every process)

Realtime profiling 窗口布局:

这里写图片描述

操作方法如下图:
这里写图片描述
这里写图片描述
这里写图片描述
这里写图片描述

3.2 Trace Capture

Trace Capture mode 抓取Snapdragon设备上可以获得的跟踪事件和数据,一旦抓取成功,可以用于:

  • 收集并显示重要的性能统计信息
  • 查看内核中每个CPU内核上的线程是如何安排的
  • 在相同的时间线上查看CPU,DSP和GPU活动之间的相关性

这里写图片描述

操作方法如下图:
这里写图片描述
这里写图片描述
这里写图片描述

3.3 Snapshot Capture

Snapshot Capture mode,捕获图形应用程序的单个帧生产快照,快照捕获显示如何在CPU上渲染场景。
抓取之前,选择一个进程和想查看的指标,并拍摄快照。一旦帧的数据被抓取,查看抓取的数据并逐步分析执行帧渲染绘制调用。
这里写图片描述
这里写图片描述
参考文章:

Snapdragon Profiler快速入门指南: http://www.csdn.net/article/a/2015-08-05/15826957
Snapdragon Profiler User Guide: https://developer.qualcomm.com/download/sdprofiler/sdprofiler-user-guide.pdf
Snapdragon Profiler Quick Start Guide: https://developer.qualcomm.com/download/sdprofiler/sdprofiler-quick-start-guide.pdf

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值