Run CUDA or PTX Code on GPU
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Hi all, I have a problem with running CUDA code on GPU. According to Run CUDA or PTX Code on GPU, I have to create PTX file from my kernel.cu file. I did it with VS2013: Converting CUDA .cu file to PTX file.
But after I tried to run it in Matlab, I got an error:
Error using iCheckPTXEntryAgainstCProto (line 370) The number of inputs to the PTX code (0) is NOT the same as the number of inputs in the C prototype (6)
On VS2013 everything runs ok. Can one specify, how kernel.cu must look in order everything to be ok? May be one provide me a simple valid CUDA kernel (like adding two vectors on GPU). Thanks
0 Kommentare
Antworten (1)
matt dash
am 16 Dez. 2014
Bearbeitet: matt dash
am 16 Dez. 2014
I'm not sure, but this sounds like some kind of compilation error maybe, or an error in how you're calling the ptx file from matlab. It might help if you posted your code. Basically matlab is parsing both your .cu file and your .ptx file, and it's finding that they have different numbers of input arguments.
Since both the .cu and .ptx file are plain text, you might be able to skim them and see whether they have the same number of inputs. (The ptx is not quite human-readable, but you should at least be able to find where the inputs are defined)
Edit: might also help to see exactly what command you're running to compile the ptx file.
0 Kommentare
Siehe auch
Kategorien
Mehr zu GPU Computing finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!