title: Detection if a pointer is pointing in the device or host in CUDA
body: <p>In CUDA are there any way of knowing if the pointer is pointing in memory on the device or the host.</p>
  
  <p>A made op example of this could be:</p>
  
  <pre><code>int *dev_c, *host_c;
  cudaMalloc( (void**)&amp;dev_c, sizeof(int) );
  host_c = (int*) malloc(sizeof(int));
  </code></pre>
  
  <p>I can of course look at the name, but are there any way of looking ad the pointer dev_c and host_c and saying, host_c points ad the host and dev_c points ad the device.</p>