Visible to Intel only — GUID: GUID-C1066BE6-5C48-4AF8-8DF8-0761280AB61D
Visible to Intel only — GUID: GUID-C1066BE6-5C48-4AF8-8DF8-0761280AB61D
Import Linux Perf* Trace with VTune Profiler Metrics
If you have your own performance monitoring system based on Linux Perf (for example, as part of your date center infrastructure) and cannot collect data with the Intel® VTune™ Profiler, you can still use the VTune Profiler for data analysis as follows:
Select a VTune Profiler analysis type that is of interest to you.
Use VTune Profiler to get a set of Linux Perf options and apply them to a Perf collection on your target system.
Import the generated Linux Perf trace into a VTune Profiler project and start analysis.
Select a VTune Profiler Analysis Type
VTune Profiler provides a rich set of predefined analysis types targeting particular performance problems. Each analysis type contains a selected list of low-level performance events and high-level metrics based on them. For example, Microarchitecture Exploration analysis collects all required PMU (Performance Monitoring Unit) events from CPU cores needed for TMA methodology. The Memory Access analysis has a set of both core and uncore PMU events needed for memory-related performance metrics (like DRAM bandwidth).
Using a native Linux Perf interface to collect all needed low-level PMU events may be complicated, so consider reusing the VTune Profiler configuration targeted for Perf collection (driverless mode).
Run VTune Profiler to Get Linux Perf Options for Analysis
When the VTune Profiler runs a performance data collection in the driverless mode, it uses a Linux Perf command line and logs it inside the result folder in the <result-folder>/data.0/perfcmd file. To get a correct set of Perf options, do the following:
Install the VTune Profiler on any Linux system with a similar hardware configuration (the same CPU family) as the system where real performance profiling is planned to be run.
Run a VTune Profiler analysis of your interest to generate perfcmd file with Perf options:
$ vtune-cl -r <result-folder> -collect <analysis-type> -finalization-mode=none -d 1
For example, for the Microarchitecture Exploration run:
vtune-cl -r bogus_result -collect uarch-exploration -finalization-mode=none -d 1
The <result-folder>/data.0/perfcmd file with all necessary Linux Perf options is generated.
NOTE:You do not run any real workload here. The only purpose of this run is to generate the perfcmd file.
VTune Profiler license is not required for this step since you only collect data without opening it.
Open the perfcmd file and copy-paste its content to a Linux Perf command invocation on your real target system.
NOTE:Your Perf tool should contain a patch from https://github.com/torvalds/linux/commit/f92da71280fb8da3a7c489e08a096f0b8715f939#diff-809984534aa420619413fdf4c260605d. In Linux kernel version >= 4.19, this patch is applied out of the box, in earlier versions you need to manually apply it and recompile the Perf tool.
Run the Linux Perf configuration on your target system.
Import the Linux Perf Trace into a VTune Profiler Project
Create a VTune Profiler project or open an existing one.
Click the Import Result toolbar button.
The Import File and Create a Result window opens.
Select Import a single file option and navigate to the Linux Perf trace file.
VTune Profiler imports the trace and opens the result in the default viewpoint. You may switch between viewpoints to apply the most relevant. For example, use the Microarchitecture Exploration viewpoint for the Microarchitecture Exploration analysis.