Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
複数のGPUでThrustを使用するにはどうすればよいですか?それは単にcudaSetDevice(deviceId)を使用してから、関連するThrustコードを実行するだけの問題ですか?
CUDA 4.0以降でcudaSetDevice(deviceId)は、スラストコードが続くはずです。
cudaSetDevice(deviceId)
各デバイスで個別のベクターを作成して操作する必要があることに注意してください(ピアツーピアメモリアクセスをサポートするデバイスがあり、PCI-express帯域幅で十分な場合を除きます)。