Xperf Analysis Basics(转)
FQ不易,转载
http://randomascii.wordpress.com/2011/08/23/xperf-analysis-basics/
I started writing a description of how to examine CPU Sampling data in xperf and realized that I needed a basics article to link back to. Here it is. Learn this before you go further.
Symbols
Without symbols you can’t do much, so configuring your symbol path is important. I use a variation on this batch file prior to running xperfview. Configure the “localbuilds” and “OurSymbolServer” directories appropriately, but leave the Microsoft symbol server as is.
@rem Add local build directories
set SYMS=c:\build\localbuilds
@rem Put symbol servers at the end to avoid network trips looking for local symbols.
set SYMS=%SYMS%;SRV*c:\symbols*\\OurSymbolServer\symbols
@rem Microsoft’s symbol server.
set SYMS=%SYMS%;SRV*c:\symbols*http://msdl.microsoft.com/download/symbols
set _NT_SYMBOL_PATH=%SYMS%
If this dialog keeps popping up when you load symbols in xperfview:

then it means you’ve hit a UAC (User Account Control – admin/non-admin) bug. Follow the link to solve it.
You can also configure symbols by going to Trace->Configure Symbol Paths.
You load symbols by going to Trace->Load Symbols, or right clicking and selecting Load Symbols.
It’s worth mentioning that symbols are compressed and cached to c:\symcache. This is an efficient symbol cache that is used exclusively by xperfview. Set the _NT_SYMCACHE_PATH variable if you want to configure the location. I just leave it at its default.
Zoomin’ In, Zoomin’ Out
Navigating the main window in xperfview is mostly a matter of zooming in and out. The obvious ways of doing this are in the right-click context menu. This menu lets you zoom in to the current selection, or zoom all the way out (Unzoom). I find this set of options frustrating. I like to zoom in and out a little bit. Zoom to selection is okay, I guess, but to have the only zoom-out option be “all the way out” is a bit silly.
The solution is to make sure you have a mouse with a mouse wheel. Hold down the control key and roll the wheel. That’s the way real programmers do it. I can’t use xperfview without a mouse wheel.
Enabling/Disabling/Reordering the Graphs
Xperfview defaults to having a particular set of graphs visible. The choice of graphs is biased towards people who are working on optimizing Windows itself, and is not as good a choice for those of us who are not actively working on the Windows scheduler. With that in mind, I recommend that you click on the flyout on the left side of the xperfview window and enable and disable graphs until it matches the correct set of graphs, conveniently shown here:

If you want CPU sampling by CPU, then go for it, but I think you’ll find it is usually not worth it.
In addition, you can change the order of graphs in order to get all of your favorites together. Just drag them around in this list to reorder them, and then double-click on the one you want to see.
Xperfview will remember the enabled/disabled state. That is good.
Xperfview will not remember the order of the graphs. You can’t win them all.
Selections
Selecting a region of interest in a trace is important because that lets you select which part of the trace you will invoke a summary table for. The diamonds on the CPU Scheduling graph and some other graphs are useful because they mark key points and because when selecting you can snap to them.
Once you’ve got a selection you can replicate it to other graphs by right clicking and selecting Clone Selection. This is often very useful.
That’s all folks
That’s enough for now. I’ll add more basics later if they seem worth it.
Xperf Analysis Basics(转)的更多相关文章
- Factoextra R Package: Easy Multivariate Data Analyses and Elegant Visualization
factoextra is an R package making easy to extract and visualize the output of exploratory multivaria ...
- 使用Python对Twitter进行数据挖掘(Mining Twitter Data with Python)
目录 1.Collecting data 1.1 Register Your App 1.2 Accessing the Data 1.3 Streaming 2.Text Pre-processin ...
- Mining Twitter Data with Python
目录 1.Collecting data 1.1 Register Your App 1.2 Accessing the Data 1.3 Streaming 2.Text Pre-processin ...
- Xperf Basics: Recording a Trace(转)
http://randomascii.wordpress.com/2011/08/18/xperf-basics-recording-a-trace/ This post is obsolete ...
- Xperf Basics: Recording a Trace (the easy way)(转)
http://randomascii.wordpress.com/2013/04/20/xperf-basics-recording-a-trace-the-easy-way/ Some ti ...
- An Introduction to Stock Market Data Analysis with R (Part 1)
Around September of 2016 I wrote two articles on using Python for accessing, visualizing, and evalua ...
- 课程一(Neural Networks and Deep Learning),第二周(Basics of Neural Network programming)—— 4、Logistic Regression with a Neural Network mindset
Logistic Regression with a Neural Network mindset Welcome to the first (required) programming exerci ...
- Security Testing Basics
Security Testing BasicsSoftware security testing is the process of assessing and testing a system to ...
- Basics of Algorithmic Trading: Concepts and Examples
https://www.investopedia.com/articles/active-trading/101014/basics-algorithmic-trading-concepts-and- ...
随机推荐
- css兼容tooltip提示框方法
最终效果图: 基本原理 先设定一个背景色的普通div盒子,然后使用上篇post得到的三角型图标,把div盒子设置为相对定位模式,三角型图标设置为绝对定位,位置相对于div盒子,调整到合适的位置.这样就 ...
- js 构造函数
//构造函数 //使自己的对象多次复制,同时实例根据设置的访问等级可以访问其内部的属性和方法 //当对象被实例化后,构造函数会立即执行它所包含的任何代码 function myObject(ms ...
- SVM1 线性SVM
一.Linear Support Vector Machine 接下来的讨论假设数据都是线性可分的. 1.1 SVM的引入:增大对测量误差的容忍度 假设有训练数据和分类曲线如下图所示: 很明显,三个分 ...
- 自动获取socket链接状态
C# TcpClient在连接成功后无法检测连接状态,即使对方关闭了网络连接.以下扩展可检测连接状态: static class TcpClientEx { public static bool Is ...
- SPI数据传输(库函数方法)
主机端: /********************************* 代码功能:SPI数据传输(主机端) 引脚说明: SS/CS:片选(高电平屏蔽,低电平启用) MOSI :主机送出信号 M ...
- The content of element type "configuration" must match "(properties?,settings?,typeAliases?,typeHandlers?,objectFactory?,objectWrapperFactory?,reflectorFactory?,plugins?,environments?,databaseIdProv
在mybatis配置文件config.xml中报错: The content of element type "configuration" must match "(p ...
- pip使用
安装指定版本的插件: pip install -v matplotlib==1.5.1 #安装matplotlib version 1.5.1
- hdu 5792(树状数组,容斥) World is Exploding
hdu 5792 要找的无非就是一个上升的仅有两个的序列和一个下降的仅有两个的序列,按照容斥的思想,肯定就是所有的上升的乘以所有的下降的,然后再减去重复的情况. 先用树状数组求出lx[i](在第 i ...
- 【转】[caffe]深度学习之图像分类模型AlexNet解读
[caffe]深度学习之图像分类模型AlexNet解读 原文地址:http://blog.csdn.net/sunbaigui/article/details/39938097 本文章已收录于: ...
- 【JSP】Tiles框架的基本使用
Tiles介绍 Tiles 是一种JSP布局框架,主要目的是为了将复杂的jsp页面作为一个的页面的部分机能,然后用来组合成一个最终表示用页面用的,这样的话,便于对页面的各个机能的变更及维护. Tile ...