run CUDA in emulation mode on virtual machine

Hi all,

Does anyone successfully run CUDA on a virtual machine, link ubuntu 10.04 ?

I don’t have an NVIDIA GPU, and I have only a virtual machine. I tried to run CUDA in emulation mode, but the system reported error:

FATAL: Module NVIDIA not found
NVIDIA: failed to load the NVIDIA kernel module
Processing time: 316.2356792 ms
Test passed

Does anyone know what’s the problem is ? Is this caused by the virtual machine ? Thanks !

The problem is that the VM has no cuda compatible GPU - no cuda comptiable GPU = no CUDA. Citrix have some sort of pass through mode for xen which will let a VM use a physical GPU, but I have no idea if it works with CUDA or not.

There are better alternatives anyway - particularly the truly excellent Ocelot, which will allow you to JIT emulate PTX execution, or translate PTX directly to x86 for native execution.

Thank you!

But my purpose is to evaluate the performance of my code when it is applied to a GPU, the Ocelot transform the CUDA code into the format suitable for the CPU, I guess the performance measured should be the performance of the code when it is applied to CPU target.

My problem is that I don’t have a real GPU, so I use the CUDA toolkit 2.3 in emulation mode (on a virtual machine ubuntu 10.04). However, I came across such question:

Fatal: no nvidia module found

NVIDIA: fail to load nvidia kernel to the module

I don’t know if this error is caused by the virtual machine? I even don’t know whether virtual machine is qualified to run CUDA in emulation mode ? Thanks!

Emulation mode doesn’t actually run on a GPU, so you won’t be able to get any meaningful performance information out of it, even if you get it working.

If you want performance numbers you have a few options: 1) see if your virtual machine vendor has a pass through layer for NVIDIA GPUs that supports CUDA (I seriously doubt that they do), 2) use a GPU remoting library like rCUDA or Ocelot that allows you to start up a server on a machine with a GPU and have your application connect to it, or 3) buy/rent a real machine with a GPU in it.

Thankyou !