Analyzers
Talk to fellow users of Intel Analyzer tools (Intel VTune™ Profiler, Intel Advisor)
5280 토론

VTune CLI: vtune does not accept the event-config modifiers

Bernard
소중한 기여자 I
4,997 조회수

Hello,

I'm using VTune CLI to run custom 'runsa' analysis on our remote SkyLake server. The collector is a perf driverless. VTune seems to reject the custom event-config modifiers. By inspecting the contents of "perfcmd", "sep.events", "map.events" it is clear that default modifiers are used by the perf collector. It is not clear which program is responsible for that. There is no warning message.

Secondly I'm interested only in user mode counting and by looking at the perfcmd file the "uk" modifier is appended to perf raw event, beside that  it is not clear if  sep "pdir" modifier is a directly translated to perf "ppp" highest level of skid reduction.

 

The vtune cli is launched by the python script and here the arguments (copied from vtune log)

 

/opt/intel/vtune_profiler/bin64/vtune -finalization-mode=none -target-pid=24851 -r /tmp/vtune_data -collect-with runsa -knob event-config=CPU_CLK_UNHALTED.THREAD:sa=1000000:OS=no CPU_CLK_UNHALTED.REF_TSC:sa=1000000:OS=no INST_RETIRED.ANY:sa=100000:OS=no INST_RETIRED.PREC_DIST:sa=100000:OS=no:pdir CPU_CLK_UNHALTED.REF_XCLK:sa=50000:OS=no CPU_CLK_UNHALTED.ONE_THREAD_ACTIVE:sa=1000000:OS=no CPU_CLK_UNHALTED.THREAD_P:sa=1000000:OS=no UOPS_RETIRED.RETIRE_SLOTS:sa=1000000:OS=no:pdir FP_ARITH_INST_RETIRED.SCALAR_SINGLE:sa=100000:OS=no:pdir FP_ARITH_INST_RETIRED.128B_PACKED_SINGLE:sa=100000:OS=no:pdir FP_ARITH_INST_RETIRED.256B_PACKED_SINGLE:sa=100000:OS=no:pdir FP_ARITH_INST_RETIRED.SCALAR_DOUBLE:sa=100000:OS=no:pdir FP_ARITH_INST_RETIRED.128B_PACKED_DOUBLE:sa=100000:OS=no:pdir FP_ARITH_INST_RETIRED.256B_PACKED_DOUBLE:sa=100000:OS=no:pdir UOPS_EXECUTED.X87:sa=100000:OS=no:pdir UOPS_EXECUTED.THREAD:sa=100000:OS=no FP_ARITH_INST_RETIRED.512B_PACKED_DOUBLE:sa=100000:OS=no:pdir FP_ARITH_INST_RETIRED.512B_PACKED_SINGLE:sa=100000:OS=no:pdir -knob enable-stack-collection=true -knob stack-size=0 -knob sampling-interval=0.01 -data-limit=5000

 

 

Here is the content of python script used to launch vtune.

Bernard_0-1598880751261.png

I attached aforementioned sep,perfcmd and map files.

Thank you for your help

--Bernard

 

레이블 (1)
0 포인트
1 솔루션
Alexey_B_Intel
4,943 조회수

You can adjust "Event mode" knob in the custom analysis configuration setting it to USER. In the command line -knob event-mode=user can be used to count events in user space only.

-Alexei

원본 게시물의 솔루션 보기

0 포인트
10 응답
Kirill_U_Intel
4,993 조회수

Hi, Bernard.

there is mistake in your python script. You splitted events row but it must be as one line.

'-knob event-config=EVENT1,EVENT2,....EVENTN'

Kirill

0 포인트
Bernard
소중한 기여자 I
4,990 조회수

Hi Kirill,

The script was written by someone else, I only added the custom events.

Will ordering the events in single line fix the issues described in my question?

 

Best regards,

--Bernard

0 포인트
Bernard
소중한 기여자 I
4,986 조회수

Hi Kirill,

I quickly rearranged the events into the single line and got the same result as the previous one. Only two events are collected and their modifiers are the default one.

I do not know if this is the issue of the script (I'm not a Python programmer).

Thanks in advance.

 

0 포인트
Kirill_U_Intel
4,982 조회수

Could you share how the scripts looks now? Full line must be in one pair quotes

 

0 포인트
Bernard
소중한 기여자 I
4,974 조회수

I'm not in front of my development machine now.

In regards to your question -- the full line was not inside of the single quotes pair. Tomorrow I will correct it and rerun the test. I hope, that correct modifiers will be passed to perf. I will keep you informed.

Thank you.

0 포인트
Alexey_B_Intel
4,971 조회수

Hi Bernard,

Support of custom event modifiers for driverless Perf based collection is currently limited. However collection of events in user space only should work. pdir modifier is not yet supported.

perfcmd file is generated just for the reference so a user could copy, paste, modify and then collect perf data using system Perf tool and then import collected data file into VTune GUI for further analysis.

-Alexei

0 포인트
Bernard
소중한 기여자 I
4,950 조회수

Hi Alexey,

Thank you for your response.

In regards to support of "sep" event modifiers (in the driverless mode) I came also to the same conclusion while seeing this perfcmd file:

Bernard_0-1598946604179.png

Currently I'm not interested in mapping the events to their machine code instruction triggers, so I would like to skip over "pdir" modifier.  The real problem now is the way to enforce only user mode counting because kernel mode count pollutes the results (out code runs in user mode address space).

>>>However collection of events in user space only should work.>>>

Is there any possibility to enforce the "u" modifier in driverless mode? I can not use SEP driver now and our script calls vtune to profile the test module.

Best regards

--Bernard

0 포인트
Alexey_B_Intel
4,944 조회수

You can adjust "Event mode" knob in the custom analysis configuration setting it to USER. In the command line -knob event-mode=user can be used to count events in user space only.

-Alexei

0 포인트
Bernard
소중한 기여자 I
4,940 조회수

Hi Alexey

Thank you for the help

Regards,

--Bernard

0 포인트
JananiC_Intel
중재자
4,925 조회수

Hi,


Thanks for the confirmation. We would discontinue monitoring this issue.Please raise a new thread if you have further issues.


0 포인트
응답