Print msg for single gpu

Change-Id: I2d23c73542add8973990ba96592016726994422e
Tento commit je obsažen v:
Sandeep Kumar
2017-05-04 13:57:01 +05:30
odevzdal Maneesh Gupta
rodič cb60763737
revize dfcba01db6
+6 -4
Zobrazit soubor
@@ -55,13 +55,9 @@ void checkPeer2PeerSupport()
{
int gpuCount;
int canAccessPeer;
int p2pCapableDeviceCount=0;
HIPCHECK(hipGetDeviceCount(&gpuCount));
if (gpuCount < 2)
printf("Peer2Peer application requires atleast 2 gpu devices");
for (int currentGpu=0; currentGpu<gpuCount; currentGpu++)
{
HIPCHECK(hipSetDevice(currentGpu));
@@ -161,6 +157,12 @@ int main(){
HIPCHECK(hipGetDeviceCount(&gpuCount));
if (gpuCount < 2)
{
printf("Peer2Peer application requires atleast 2 gpu devices");
return 0;
}
currentGpu = 0;
peerGpu = (currentGpu + 1);