Analyzers
Support for Analyzers (Intel VTune™ Profiler, Intel Advisor, Intel Inspector)
Announcements
This community is designed for sharing of public information. Please do not share Intel or third-party confidential information here.
4679 Discussions

Feature request: setting threshold for effective CPU utilization in command-line interface

FJ_Shen
Beginner
408 Views

FJ_Shen_0-1629914844046.png

FJ_Shen_1-1629915028818.png

 

I'm trying to calculate how much "wall time" each function spends in my application. However, vTune does not seem to report that metric on a per-function basis in its reports, and the closest approximation that I can use is this 5-tier categorized  "effective CPU time by Utilization" metric that is presented in the hotspot report. 

My analysis involves generating hotspot reports for a great number of application runs, therefore I found the CLI very useful. I did not, however, find a way to modify in CLI the threshold value that demarcates the five tiers (Idle, Poor, Ok, Ideal, Over); and the only way to modify these thresholds is to go into the GUI, manually drag the bars to change the threshold. 

Could it be possible that the development team add a CLI option that sets the threshold values for demarcating  the five tiers of CPU utilization? Or possibly make vTune calculate a "wall time" metric for each function?  

0 Kudos
3 Replies
FJ_Shen
Beginner
406 Views

My OS version: Ubuntu 20.04.3 LTS

Tool version: vTune standalone 2021.5

FJ_Shen
Beginner
375 Views

After some text searching I believe one (hackful) way to do this is:

1. Add the following configuration (marked in bold) to <project_name>.vtuneproj. The values highlighted in red are the threshold values for CPU utilization that I want to configure 

<root>

<!--Other auto-generated configurations-->

<engine>
<knobs>
<utilizationThreshold type="string">
&lt;bag xmlns:boolean=&quot;http://www.w3.org/2001/XMLSchema#boolean&quot; xmlns:double=&quot;http://www.intel.com/2001/XMLSchema#double&quot; id=&quot;utilizationThreshold&quot;&gt;
&lt;minValueThresholds domain=&quot;&quot;&gt;
&lt;double:minValueThreshold name=&quot;Idle&quot;&gt;-40 &lt;boolean:readonly&gt;true&lt;/boolean:readonly&gt;
&lt;/double:minValueThreshold&gt;
&lt;double:minValueThreshold name=&quot;Poor&quot;&gt;3.9999999999999998e-06 &lt;boolean:readonly&gt;true&lt;/boolean:readonly&gt;
&lt;/double:minValueThreshold&gt;
&lt;double:minValueThreshold name=&quot;Ok&quot;&gt;4.5 &lt;boolean:readonly&gt;false&lt;/boolean:readonly&gt;
&lt;/double:minValueThreshold&gt;
&lt;double:minValueThreshold name=&quot;Ideal&quot;&gt;8.5 &lt;boolean:readonly&gt;false&lt;/boolean:readonly&gt;
&lt;/double:minValueThreshold&gt;
&lt;double:minValueThreshold name=&quot;Over&quot;&gt;12.5 &lt;boolean:readonly&gt;false&lt;/boolean:readonly&gt;
&lt;/double:minValueThreshold&gt;
&lt;/minValueThresholds&gt;
&lt;/bag&gt;
</utilizationThreshold>
</knobs>
</engine>

</root>
 

2. Write a script where you iterate over all reports and use vtune -I to refinalize the results.

 

Before a CLI option comes out I think this is the only convenient way to minimize my work to change the CPU utilization threshold value for every report in a project.

FJ_Shen
Beginner
339 Views

It appears that the .vtuneproj configuration file only affects the GUI tool's behavior. If I'm calling vtune -finalize in CLI, those threshold values will not at all be picked up! So far I cannot figure out a purely CLI-based means to do what I want to do. 

Reply