c++ - Simple CUDA app, cudaMalloc ends with Error: unspecified driver error -
i'm newbie cuda patient me please. have simple vs2012 project 1 main.cpp file following source code:
#include <stdio.h> /*cuda*/ #include <cuda_runtime.h> #include <cuda_runtime_api.h> #include <cuda.h> int main(int argc, char **argv){ /*device variables*/ uchar3 *image_dev; cudamalloc((void**)&image_dev,64*48*sizeof(uchar3)); printf("error:\t%s\n", cudageterrorstring(cudagetlasterror())); return(0); }
it runs without fatal errors, cudagetlasterror() writes out error "unspecified driver error" , have no clue why. doing wrong?
i have geforce gt 740m latest driver installed. have installed cuda 6.0. configured includes , linkings. add cudart.lib linker->input->additional dependencies.
i set following things:
project configuration->vc++ directoties->executable directories $(cuda_bin_path)
project configuration->vc++ directoties->include directories $(cuda_inc_path)
project configuration->vc++ directoties->library directories $(cuda_lib_path)
project configuration->linker->general->additional library directories->$(cuda_lib_path)
i set compute_30 , sm_30.
what i'm doing wrong?
regards,
robert
well solve problem , don't understand solution, , maybe because of mismatched configuration robert crovella said. have installed cuda 5.5 , cuda 6.0 too, had set 6.0 toolkit. don't know problem.
but solution was: create brand new cuda project , there working fine went thru configurations , set project cuda project , started work when add linker->input->additional dependencies these libraries
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib
what don't understand because of these libraries in inherited values. started work. if know, why needed add libraries manually, post please.
Comments
Post a Comment