allendaicool / thrust

Automatically exported from code.google.com/p/thrust
Apache License 2.0
0 stars 0 forks source link

How to use thrust with cuda 2.3 (using device emulation ) #252

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

Hi everyone,

   I am Cuda learner. I am doing cuda program using Cuda 2.3 with help device emulation for Compilation ( on Windows XP ). I try to use Thrust 
library but I am getting error as follows

(Program is sum.cu from thrust Example)

For thrust version 1.0

C:\thrust-v1.0.0>nvcc -deviceemu sum.cu
sum.cu
tmpxft_00000af4_00000000-3_sum.cudafe1.cpp
tmpxft_00000af4_00000000-7_sum.ii

C:\Downloads\thrust-v1.0.0>a.exe
Assertion failed: properties.major == 1, file .\thrust/experimental arch.inl, 
line 80

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

//-----------------------------------------------------------
For thrust version 1.2

C:\thrust-v1.2>nvcc -deviceemu sum.cu
sum.cu
tmpxft_00000de0_00000000-3_sum.cudafe1.cpp
tmpxft_00000de0_00000000-7_sum.ii
-----------------------------------------------------------------------
| WARNING: Thrust does not support device emulation
-----------------------------------------------------------------------

//-----------------------------------------------------------

For thrust version 1.3

C:\thrust-v1.3.0>nvcc -deviceemu sum.cu
sum.cu
.\thrust/detail/config/compiler.h(29) : fatal error C1189: #error :  "CUDA v3.0
or newer is required"

Please suggest me which version of thrust I should use & how to use with device 
emulation.

Thanks in Advance 

Original issue reported on code.google.com by sache.si...@gmail.com on 14 Oct 2010 at 7:16

GoogleCodeExporter commented 9 years ago
Hi Sache,

Unfortunately Thrust never supported device emulation so if you don't have a 
GPU you'll need to use the OpenMP backend using these instructions [1].  

Note that device emulation was deprecated in CUDA 3.0 and removed entirely in 
CUDA 3.1, so there's no possibility of it ever working with Thrust.

[1] http://code.google.com/p/thrust/wiki/DeviceBackends

Original comment by wnbell on 18 Oct 2010 at 10:49