- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I'm working in the Intel DevCloud with VTune connected through VSCode
( as described here: https://www.intel.com/content/www/us/en/docs/vtune-profiler/cookbook/2023-0/using-vtune-server-with-vs-code-intel-devcloud.html )
In my code I'm using `__itt_resume()` and `__itt_pause()` as in this example:
include <ittnotify.h>
int main(int argc, char* argv[])
{
// Do initialization work here
__itt_resume();
// Do profiling work here
__itt_pause();
// Do finalization work here
return 0;
}
I set up my environment as in this guide:
The problem is that when I run the profiler in paused mode the exectuion finishes but all of the analysis results are 0 except of elapsed time.
My compile flags are:
g++ -std=c++14 -g -mavx512vl -c -I../common -I/opt/intel/oneapi/vtune/2024.1/sdk/include -O3 -fopenmp -mcmodel=medium ft.cpp
g++ -std=c++14 -g -mavx512vl -O3 -fopenmp -mcmodel=medium -o ../bin/ft.B ft.o -lm -lpthread -littnotify -ldl -L/opt/intel/oneapi/vtune/2024.1/sdk/lib64
I also tried setting the env variables:
export INTEL_LIBITTNOTIFY64=/opt/intel/oneapi/vtune/2024.1/lib64/runtime/libittnotify_collector.so
export INTEL_LIBITTNOTIFY32=/opt/intel/oneapi/vtune/2024.1/lib32/runtime/libittnotify_collector.so
(I'm not sure if I did this correctly, a clarification about how and where is should be done would help)
I need help figuring this out
Thank you
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
__itt_resume( )/__itt_pause( ) are just used to control the data collection. You can focus on the code area analysis you have an interest in.
You need to start the application run with collection paused, like below:
$ vtune -collect hotspots --start-paused -- your path/binary
From the VTune data below, you can see all data started to collect until the binary goes to the API, __itt_resume( ) and data stopped when the __itt_pause( ) is ended.
But from your post above, it looks like there is no data and metrics shown in the VTune data, you need to check VTune works first w/o ITT API.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That's exactly my problem.
VTune works fine when I don't use the API,
But when I try starting paused and calling __itt_resume( ) then I get nothing recorded
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Could you share your VTune data?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I now tried running the same code once in `Performance Snapshot` mode and once in `Hotspots` mode.
In `Performance Snapshot` I got the same results as in the original post showing 0 collected data.
In `Hotspots` I actually got result similar to yours, showing me the paused section with the collected data afterwards.
I don't understand why would `Performance Snapshot` won't work with the ITT api?
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you check if the VTune drivers are all working?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How can I test if the VTune drivers are working?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Enter VTune driver source path, like /opt/intel/oneapi/vtune/latest/sepdk/src , run ./insmod-sep -q to check driver.
pax driver is loaded and owned by group "vtune" with file permissions "660".
socperf3 driver is loaded and owned by group "vtune" with file permissions "660".
sep5 driver is loaded and owned by group "vtune" with file permissions "660".
socwatch2_15 driver is loaded and owned by group "vtune" with file permissions "660".
vtsspp driver is loaded and owned by group "vtune" with file permissions "660".
Run vtune-self-checker.sh to check VTune environment:
/opt/intel/oneapi/vtune/latest/bin64$ vtune-self-checker.sh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Are there any updates for this issue? I see the same issue as the original poster.
The sampling drivers are installed and vtune-self-checker.sh passes.
If I start VTune paused and try to resume with __itt_resume() then it says collection never resumed, but this only happens for performance_snapshot. It works for other collection types.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page