Fixed a couple of issues and got the CUDA helpers working.