makeRemoteBufferView(_:)
Creates a remote view of the buffer for another GPU in the same peer group.
Declaration
func makeRemoteBufferView(_ device: any MTLDevice) -> (any MTLBuffer)?Mentioned in
Discussion
The device instance that this buffer belongs to and the device you pass to the method both need to have the same nonzero peer group identifier (peerGroupID). This buffer needs to use the private storage mode (MTLStorageMode.private).
A remote view doesn’t allocate any storage for the new buffer; it references the memory allocated for the original buffer. You can use remote views only as a source for copy commands encoded by an MTLBlitCommandEncoder. For more information, see Transferring data between connected GPUs.