How to copy data between 2 contexts inside GPU?

I create context1 and context2 on a same GPU,then how can I copy data between the 2 contexts without copying data out from GPU?

I think it may be possible using CUDA IPC.

https://docs.nvidia.com/cuda/cuda-driver-api/group__CUDA__MEM.html#group__CUDA__MEM_1gd6f5d5bcf6376c6853b64635b0157b9e

thanks,but IPC functionality only supported in TCC driver model,I’m using a Geforce card and WDDM driver model(I dont know whether geforce is support tcc mode) on Windows,so I can’t use cuIpcXXX(), so is there any other way to do it?

CUDA contexts are equivalent to processes. For security reasons, processes generally have separate, protected, address spaces, so a special mechanism is needed to allow processes to share data: IPC.

If IPC is not available to you because you are using a WDDM driver on the Windows platform, you might want to re-think your software architecture.