[Rd] Use GPU in R with .Call
Norm Matloff
matloff at cs.ucdavis.edu
Mon Jul 23 01:37:08 CEST 2012
[Sorry, originally sent to wrong list.]
I'm not exactly sure what you are asking, Raymond, but this may answer
your question.
Say you have a file x.cu. After compiling with nvcc -c as you did, then
do something like this:
setenv PKG_LIBS "-L/usr/local/cuda/lib -lcudart"
R CMD SHLIB x.o -o x.so
PKG_LIBS is an environment variable used by R CMD SHLIB.
Of course, you need to translate the setting of the environment variable
from Linux C shell to Windows, and substitute your location of the CUDA
library.
Norm
More information about the R-devel
mailing list