Basics of Vtune™ Performance Analyzer Intel Software College
Total Page:16
File Type:pdf, Size:1020Kb
Objectives At the completion of this module, you will be able to: • Understand the intended purpose and usage models supported by the VTune™ Performance Analyzer. • Identify hotspots by drilling down through various sample views. • Understand how sampling works • Use callgraph profiling to find hotspots Basics of VTune™ Performance Analyzer Intel Software College Basics of VTune™ Performance Analyzer 2 Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Agenda VTune™ Performance Analyzer What is the VTune™ Performance Analyzer? Helps you identify and characterize performance issues by: Performance tuning concepts • Collecting performance data from the system running your application. Using the sampling collector • Organizing and displaying the data in a variety of interactive views, from system-wide down to source code or processor instruction How sampling works perspective. Sampling Over Time • Identifying potential performance issues and suggesting improvements. Call Graph Basics of VTune™ Performance Analyzer Basics of VTune™ Performance Analyzer 3 4 Copyright © 2006, Intel Corporation. All rights reserved. Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. 1 Supported Environments Local Performance Analysis Intel® IA-32 Processors Local and remote data collection • Microsoft Windows* operating systems Profile applications that are running on the system that has the • Red Hat Linux* analyzer installed on it, or • SuSE Linux Itanium® Family Processors Run profiling experiments on other systems that are running • Microsoft Windows operating systems VTune analyzer remote agents on them • Red Hat Linux • SuSE Linux For specific operating systems versions, see the release notes Basics of VTune™ Performance Analyzer Basics of VTune™ Performance Analyzer 5 6 Copyright © 2006, Intel Corporation. All rights reserved. Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Host/Target Environment Feature Overview VTune™ Performance Analyzer supports remote data Sampling collection VTune™ Performance Analyzer installed on host system Call graph Remote agent installed on target system Host System Target System • Windows* • IA-32 or Itanium® operating system processor family LAN Connection • Controls target • Windows or Linux* • View results of data • Intel® PXA2xx collection processors running Windows CE* Basics of VTune™ Performance Analyzer Basics of VTune™ Performance Analyzer 7 8 Copyright © 2006, Intel Corporation. All rights reserved. Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. 2 VTune™ Analyzer Features and Usage Models VTune™ Analyzer Features and Usage Models Basics of VTune™ Performance Analyzer Basics of VTune™ Performance Analyzer 9 10 Copyright © 2006, Intel Corporation. All rights reserved. Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. VTune™ Analyzer Features and Usage Models VTune™ Analyzer Features and Usage Models Basics of VTune™ Performance Analyzer Basics of VTune™ Performance Analyzer 11 12 Copyright © 2006, Intel Corporation. All rights reserved. Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. 3 What Is a Hotspot? Sampling: The Statistical Method of Finding Hotspots Where in an application or system there is a significant amount The sampling collector of activity • Periodically interrupts the processor • Where = address in memory => OS process => OS thread => • Time-based executable file or module => user function (requires symbols) => • Event-based: Triggered by the occurrence of a certain number of line of source code (requires symbols with line numbers) or microarchitectural events processor (assembly) instruction • Collects the execution context • Significant = activity that occurs infrequently probably does not have • Execution address in memory (CS:IP) much impact on system performance • Operating system process and thread ID • Activity = time spent or other internal processor event • Executable module loaded at that address • Examples of other events: Cache misses, branch mispredictions, floating- • If you have symbols for the module, post-processing can identify the point instructions retired, partial register stalls, and so on. function or method at the memory address. • Line numbers from the symbol file can direct you to the relevant line of source code. Basics of VTune™ Performance Analyzer Basics of VTune™ Performance Analyzer 13 14 Copyright © 2006, Intel Corporation. All rights reserved. Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. VTune™ Analyzer Sampling Collector Sampling Collector Sampling Results Periodically interrupt the processor to obtain the execution context by Operating • Time-based sampling (TBS) is triggered by: System Process • Operating system timer services This operating system • Every n processor clockticks process that has the most • Event-based sampling (EBS) is triggered by processor event counter clockticks samples overflow • These events are processor-specific, like L2 cache misses, branch mispredictions, floating-point instructions retired, and so on Sorted by Clockticks Basics of VTune™ Performance Analyzer Basics of VTune™ Performance Analyzer 15 16 Copyright © 2006, Intel Corporation. All rights reserved. Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. 4 VTune™ Analyzer Sampling Collector VTune™ Analyzer Sampling Collector Click here for Over Time view. Click here Click here for OS to break Process down by view. Display only CPU. This view was filtered Clockticks by selecting only one sample data. item from the process view. Basics of VTune™ Performance Analyzer Basics of VTune™ Performance Analyzer 17 18 Copyright © 2006, Intel Corporation. All rights reserved. Copyright © 2006, Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States or other countries. *Other brands and names are the property of their respective owners. VTune™ Analyzer Sampling Collector VTune™ Analyzer Sampling Collector Hotspot view of one module for all OS processes and threads grouped by function (or method). Table View: