Working on CUDA backend