Menu

Select compute device with CUDA backend

mmoeller
2017-08-24
2017-08-24
  • mmoeller

    mmoeller - 2017-08-24

    Dear all,

    selecting the device with the OpenCL backend can be done via

    viennacl::ocl::set_context_device_type(n, viennacl::ocl::gpu_tag());
    

    Is there a similar thing for the CUDA backend?

    Thanks and best regards,
    Matthias

     

    Last edit: mmoeller 2017-08-24
  • Karl Rupp

    Karl Rupp - 2017-08-24

    Hi Matthias,
    no, CUDA only works for GPUs. If you want to select a particular CUDA device, use cudaSetDevice() directly (at the very beginning of your application).
    Best regards,
    Karli

     

Log in to post a comment.