Moved common gpu functionality to core module

* moved device layer from gpu module to core module
* renamed device namaspace to cuda
* created gpu_private.hpp header for some internal functionality
* renamed cudaSafeCall macros to cvCudaSafeCall, because it is available in public headers