Compiles, but code seems to be broken on CUDA5