Now, if I use this code to try access to GPU-RAM from CPU-Cores by using CUDA5.5 in GeForce GTX460SE (CC2.1), then I get an exception "Access Violation":
#include "cuda_runtime.h"
#include "device_launch_parameters.h"
#include <iostream>
int main()
{
unsigned char* gpu_ptr = NULL;
cudaMalloc((void **)&gpu_ptr, 1024*1024);
*gpu_ptr = 1;
int q; std::cin >> q;
return 0;
}
But we know, that there is UVA(Unified Virtual Addressing). And there are some new:
- 25 October 2013 - 331.17 Beta Linux GPU Driver: The new NVIDIA Unified Kernel Memory module is a new kernel module for a Unified Memory feature to be exposed by an upcoming release of NVIDIA's CUDA. The new module is nvidia-uvm.ko and will allow for a unified memory space between the GPU and system RAM. http://www.phoronix.com/scan.php?page=news_item&px=MTQ5NDc
- Key features of CUDA 6 include: Unified Memory -- Simplifies programming by enabling applications to access CPU and GPU memory without the need to manually copy data from one to the other, and makes it easier to add support for GPU acceleration in a wide range of programming languages. http://www.techpowerup.com/194505/nvidia-dramatically-simplifies-parallel-programming-with-cuda-6.html
Would it be possible to access memory GPU-RAM from CPU-Cores by using the simple pointer in a new CUDA6?