"Uploading" the same texture3D-object to different effects

Hello,

assume I have a texture3D-object and two different effect files which have a uniform/global texture3d-variable defined in it respectively.

If I load two effect-files and set (=upload) both effect’s global variables to the same texture3D-object, is that particular texture3D-object sent twice to the GPU or once?

My guess is the following: The moment I create/load a texture3D-object, gpu-memory is already allocated for it. Setting a texture3D-parameter in an effect only sets an integer that refers to that given texture3D in the gpu-memory, meaning, it won’t get uploaded to the gpu twice, rather setting a texture3D-object is the same thing as setting an int (memory address).
Is this true, to some extend?

Best regards

_

Yes, the texture is set by reference. Only when you call SetData() actual texture data will be uploaded.

In addition to that (although it may not seem related to this initial question): Would - performance-wise - cuda’s unified memory concept out-perform setData to mimic data-synchronization between CPU and GPU?

Best regards!