NVlabs / NVBit

198 stars 18 forks source link

nvbit_get_kernel_argument_sizes get error CUDA_ERROR_INVALID_VALUE #80

Open Zhaojp-Frank opened 2 years ago

Zhaojp-Frank commented 2 years ago

I tried to call the following API, compiled ok but hit ERROR during run with a simple test kernel, Things get ok if I remove nvbit_get_kernel_argument_sizes.

nvbit_get_kernel_argument_sizes(CUfunction func); ERROR file nvbit_imp.cpp line 1598: CUDA_ERROR_INVALID_VALUE invalid argument

so wondering whether the API is fully tested?

env: T4, 450.80.02 cuda11.2

x-y-z commented 2 years ago

The bug is confirmed. It will be fixed in the next release. Thanks for reporting it.

Zhaojp-Frank commented 1 year ago

@x-y-z hi, any update on the release plan ?

Yfeng-44 commented 1 year ago

Just wondering if there's any advances on this thread or other work around?

rodhuega commented 3 months ago

Me too. Is there any plan to solve it?

atomicapple0 commented 2 months ago

Consider using cuFuncGetParamInfo if you are on Cuda 12.4 or higher.

rodhuega commented 2 months ago

Consider using cuFuncGetParamInfo if you are on Cuda 12.4 or higher.

Hi, thanks for the suggestion. But NVBit does not work with CUDA 12 :(

cesar-avalos3 commented 2 months ago

You could always use the (admittedly very hacky) LD_PRELOAD trick to use CUDA 12 Driver API functions with nvbit, https://github.com/cesar-avalos3/ld_trick_nvbit/tree/main I've been using it with cuStreamGetId and our tracer tool to correlate results between NCU/NSYS and it.

rodhuega commented 2 months ago

You could always use the (admittedly very hacky) LD_PRELOAD trick to use CUDA 12 Driver API functions with nvbit, https://github.com/cesar-avalos3/ld_trick_nvbit/tree/main I've been using it with cuStreamGetId and our tracer tool to correlate results between NCU/NSYS and it.

Ohh, nice idea. Thank you