Profiling a cuda/opengl app fails to record opengl events

I’m trying to profile my opengl app with the latest version of nsight systems (2024.1.2) as a sudo user.
I’m using cuda/opengl interop and the profiler is able to correctly capture the cuda calls however it fails to show any of the opengl events in the timeline.
More specifically, the “OpenGL API” and “OpenGL HW” entries are completely empty while the “CUDA API” and “CUDA HW” are populated adequately.
I’ve checked “Collect OpenGL trace” and “Collect GPU workload trace” before launching the app and the analysis summary reports that some opengl events were successfully collected. The only error that is reported is “EnableActivity(handle, kind) returned 14: CUPTI_ERROR_NOT_COMPATIBLE”.
What’s going on? Why is the opengl timeline empty?

When you open the result in the timeline, do you see any errors displayed in the top r-hand corner of the timeline page? Alternatively, use the dropdown to switch to the diagnostics pane and see if there are errors there.

Yes, there are some errors as I mentioned in my previous message.
Here is a screenshot of the report:


And here is a screenshot of the timeline:

As you can see, the cuda api and cuda hw lines are populated but the opengl api and opengl hw lines are completely empty.

@liuyis can you see if there is an OpenGL irregularity here? I did notice that the summary pane says that the command line was nsys profile --stats true -t cuda,nvtx -s none python benchmark_gevm.py, which doesn’t call opengl trace, however the timeline rows for it are showing up.

Not sure if that is a glitch in the command line transcription or if that’s the underlying issue.

Hi @utilisateur2281, is it possible to share the report file? Could you also share the result of nvidia-smi on your system? The error EnableActivity(handle, kind) returned 14: CUPTI_ERROR_NOT_COMPATIBLE might be due to a recent bug.

I’m not sure if it’s related to OpenGL through. If you right click the “OpenGL API” row, you can select “Show In Events View”. After that, do you see any entries in the event table below the timeline? I’m wondering if there were some OpenGL events with too short duration that you cannot easily notice on the timeline.

The opengl event views is completely empty.
Here is the report:
report11.zip (425.9 KB)

And here is what nvidia-smi says:

nvidia-smi
Fri Apr 5 18:48:38 2024
±----------------------------------------------------------------------------+
| NVIDIA-SMI 515.48.07 Driver Version: 515.48.07 CUDA Version: 11.7 |
|-------------------------------±---------------------±---------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|===============================+======================+======================|
| 0 NVIDIA RTX A6000 On | 00000000:73:00.0 On | Off |
| 34% 55C P8 38W / 300W | 2437MiB / 49140MiB | 0% Default |
| | | N/A |
±------------------------------±---------------------±---------------------+

±----------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=============================================================================|
| 0 N/A N/A 2224 G /usr/lib/xorg/Xorg 98MiB |
| 0 N/A N/A 4837 G /usr/lib/xorg/Xorg 438MiB |
| 0 N/A N/A 4974 G /usr/bin/gnome-shell 98MiB |
| 0 N/A N/A 1498081 G …RendererForSitePerProcess 112MiB |
| 0 N/A N/A 2583122 G …RendererForSitePerProcess 77MiB |
| 0 N/A N/A 3124291 G /usr/lib/firefox/firefox 180MiB |
| 0 N/A N/A 3157548 G …ost-linux-x64/nsys-ui.bin 1244MiB |
±----------------------------------------------------------------------------+

Thanks, looks like there’s some bug here, I can see some OpenGL activites way after the collection window, at around 85 seconds:

The events view is also indicating there’s some OpenGL API calls around that time, but that’s invisible on the timeline:

Is it possible for us to run the application on our side to see if we can reproduce the issue?