Hi,
Is there a way to do an async memcopy on a NON-pinned memory?
I want to launch a kernel (which calculates some formulas) and while its running copy the data needed
for the next kernel. Problem is that it seems that i must use pinned memory and I can’t - I use textures
and in current CUDA version textures can’t be bounded to pinned memory.
I am suprised to find out that you can’t use textures. I was under the impression that memory on the device was memory on the device, and it didn’t matter how it was transferred. Thought pinned was just to do with host memory. That said, it’s been a while since I used streams…
There is a very simple reason why pinned memory is required for async transfers. Proof: Assume the contrary unpinned memory can be used. An async transfer is started and backgrounded. Then the OS needs to do memory management and shuffles virtual pages around in physical memory. Poof! The pages the aysnc transfer is copying no longer exist where they were at the start of the transfer and you are copying garbage data to the GPU.