CUDA C SVN? Does it Exist?

Dear All …

Looking to download CUDA ‘C’ SVN, if there is one. Not sure if I am talking the right thing. I basically want to see the source code of cudaMalloc(void** devptr, size) function. Why just for curiosity.

Can anyone please help me with this.

Thank you for any help you can provide.

Amit_Kumar

The implementation of the CUDA API is not open source. NVIDIA does not have a public version control repository. With each CUDA release, they do publish the source tar file for one of the compiler components, as it is based on the Open64 compiler, licensed under the GPL.

The implementation of the CUDA API is not open source. NVIDIA does not have a public version control repository. With each CUDA release, they do publish the source tar file for one of the compiler components, as it is based on the Open64 compiler, licensed under the GPL.

Hello, interesting so see that more poeple would be interested in cudaMalloc, perhaps for different reasons.

As for me, I would like to know how cudaMallocHost works in order to see what functions are being called in kernel space for a given call. I would like to intercept it, e.g. when the size or the pointer passed in has a perticular value, and return the memory location of some reserved memory which a driver for a data acquisition card writes to.

Any chance of finding out how that works?
peter

Hello, interesting so see that more poeple would be interested in cudaMalloc, perhaps for different reasons.

As for me, I would like to know how cudaMallocHost works in order to see what functions are being called in kernel space for a given call. I would like to intercept it, e.g. when the size or the pointer passed in has a perticular value, and return the memory location of some reserved memory which a driver for a data acquisition card writes to.

Any chance of finding out how that works?
peter

Have you tried using strace on a simple CUDA program to see what kernel calls and device I/O is performed?

Have you tried using strace on a simple CUDA program to see what kernel calls and device I/O is performed?

Hi Seibert …thank you for your reply and info, mystery of SVN solved :-); strace sounds like a good idea to get some more idea … i will try that;

Hi Peter my curiosity was more naive, I wanted to emulate the same behavior of what the API i doing internally. may be if I can find a simple host side allocation example code, will serve the purpose of my interest at this point. I wasn’t able to do so on the host side malloc as well.

GPU is FUN!

Hi Seibert …thank you for your reply and info, mystery of SVN solved :-); strace sounds like a good idea to get some more idea … i will try that;

Hi Peter my curiosity was more naive, I wanted to emulate the same behavior of what the API i doing internally. may be if I can find a simple host side allocation example code, will serve the purpose of my interest at this point. I wasn’t able to do so on the host side malloc as well.

GPU is FUN!