how to compile cuda with mex where i dont have parallel toolbox
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Michaelscheinfeild
am 26 Okt. 2016
Beantwortet: Joss Knight
am 31 Okt. 2016
i have matlab 2015 i want to make mex from cuda file , i dont have the parallel toolbox
setenv('MW_NVCC_PATH','/usr/local/CUDA/bin')
mex mexGPUExample.cu
*Building with 'NVIDIA CUDA Compiler'.
Error using mex
LINK : fatal error LNK1181: cannot open input file 'gpu.lib'*
0 Kommentare
Akzeptierte Antwort
Joss Knight
am 31 Okt. 2016
You can't build CUDA kernels using mex without Parallel Computing Toolbox. This requires the NVIDIA compiler nvcc and the infrastructure to call that from mex is only provided with PCT.
You need to build your device code into a separate library independently of MATLAB and built using nvcc, and then write mex functions that link to it using the -l option.
0 Kommentare
Weitere Antworten (0)
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!