Kernel functions cannot be analyzed using nsys

Hello,
when i use my nsight system to profile my program,it can’t profile the kernel function.the program is as below

Blockquote#include <stdio.h>

global void hello() {
printf(“Hello world from device\n”);
}

int main() {
printf(“Hello world from host\n”);
hello<<<1, 1>>>();

cudaDeviceSynchronize();
return 0;

}

i got the result as below


it seems like that, i can’t profile the kernel function.so how can i use the nsys,by the way ,the nsight version is as below

the driver version is 525,the cuda version is 12.0

Changing category to Nsight Systems

So you are showing the console, and it appears that Nsys ran correctly. Was there a .nsys-rep file created? Did you try to open that in the GUI?

Alternatively if you just want so see simple statistics, you can add the --stats option to your command line and it will print some of the most commonly used statistics to the terminal when the run is complete.