Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error about wrap a viennacl vector with an existing device vector. #290

Open
ztdepztdep opened this issue Aug 3, 2022 · 1 comment
Open

Comments

@ztdepztdep
Copy link

ztdepztdep commented Aug 3, 2022

when i wrap the vector with an thrust device vector as follows.
viennacl::vector vcl_rhs(thrust::raw_pointer_cast(d_b.data()), viennacl::CUDA_MEMORY, vcl_size);

I have include the
#ifndef VIENNACL_WITH_CUDA
#define VIENNACL_WITH_CUDA
#endif
in the head file ,but i still get the errors. What does it means.

terminate called after throwing an instance of 'viennacl::cuda_not_available_exception'
what(): ViennaCL was compiled without CUDA support, but CUDA functionality required for this operation.
Caught signal 6 - SIGABRT (abort)

@karlrupp
Copy link
Collaborator

karlrupp commented Aug 3, 2022

Please make sure to define VIENNACL_WITH_CUDA before including any ViennaCL header files (i.e. at the very top of the file that contains the code line you've referenced).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants