Improve P2P test.

- Ensure proper device is set before each command.

- Add command line switches:
    +bool p_memcpyWithPeer = false; // use the peer device for the P2P copy
    +bool p_mirrorPeers = false; // in addition to mapping current to peer
            space, map peer to current space.
    +int  p_peerDevice = -1;  // explicly specify which peer to use, else
use p_gpuDevice + 1.


[ROCm/hip commit: c2d37b4bbd]
This commit is contained in:
Ben Sander committed 2016-04-11 07:58:58 -05:00
1 parent 07de649833
commit a563ec9700
2 files changed
+29 -10

No files matched your search

+1 -1
View File
@@ -111,7 +111,7 @@ int parseStandardArguments(int argc, char *argv[], bool failOnUndefinedArg)
failed("Bad iterations argument");
}
} else if (!strcmp(arg, "--gpu") || (!strcmp(arg, "-g"))) {
} else if (!strcmp(arg, "--gpu") || (!strcmp(arg, "-gpuDevice")) || (!strcmp(arg, "-g"))) {
if (++i >= argc || !HipTest::parseInt(argv[i], &p_gpuDevice)) {
failed("Bad gpuDevice argument");
}