Community
cancel
Showing results for 
Search instead for 
Did you mean: 
yao__cody
Beginner
220 Views

how Intel® VTune™ Profiler counts counter value and samples information about a given process.

Jump to solution

Dear all,

As we know, each core has private registers(general and fixed counter), when the process switches to another CPU, we need to re-enable counter above the current CPU.
In Linux code, the context switch does this. However, in vtune driver(sepdk), I don’t have seen anything like this, so I was wondering how vtune driver did it.

If anyone knows, please help to explain it~

Thanks

cody

 

 

0 Kudos
1 Solution
Dmitry_R_Intel1
Employee
220 Views

The sepdk contains 2 different drivers actually. The sep driver doesn't handle context switches at all. Basically it always collects data system-wide (per-core).

The second driver called vtss (which is usually used when you select collection with stacks) does intercept context switches and behaves in a way similar to Linux perf in per-process mode. 

View solution in original post

5 Replies
ArunJ_Intel
Moderator
220 Views

Hi Cody,

 

Thanks for reaching out to us. As this is an involved query regarding the internals of vtune . We are forwarding your case to SME.

 

 

Arun Jose

Dmitry_R_Intel1
Employee
221 Views

The sepdk contains 2 different drivers actually. The sep driver doesn't handle context switches at all. Basically it always collects data system-wide (per-core).

The second driver called vtss (which is usually used when you select collection with stacks) does intercept context switches and behaves in a way similar to Linux perf in per-process mode. 

View solution in original post

yao__cody
Beginner
220 Views
Hi Dmitry, I got it. Thanks~
yao__cody
Beginner
220 Views

Dmitry Ryabtsev (Intel) wrote:

The sepdk contains 2 different drivers actually. The sep driver doesn't handle context switches at all. Basically it always collects data system-wide (per-core).

The second driver called vtss (which is usually used when you select collection with stacks) does intercept context switches and behaves in a way similar to Linux perf in per-process mode. 

 

Hi Dmitry,

I tried it on my system, and used the following command:

1.vtune -collect-with runsa -knob event-config=INST_RETIRED.ANY -knob enable-driverless-collection=false ls

2.vtune -collect hotspots -knob sampling-mode=hw ls

But the result indicated that the collector type is always driverless perf per-process sampling. What circumstances Vtune sampling driver would be used.

My platform information:

Name:intel(R) Processor code named Skylake

Frequency:3.504HZ

Logical CPU count:4

kernel version 5.4.0

Thanks

cody

Dmitry_R_Intel1
Employee
220 Views

Please check that VTune driver is installed and has correct permissions. See this article for more details: https://software.intel.com/en-us/vtune-help-building-and-installing-the-sampling-drivers-for-linux-targets

 

Reply