fix nvcc compiler

- MallocHost and FreeHost deprecation.
- Change tests to call new hipHost* equivs.
- Add missing StreamSynchronize.
This commit is contained in:
Ben Sander committed 2016-03-19 04:20:15 -05:00
1 parent 03731020f1
commit 6984f24d3d
5 files changed
+19 -12

No files matched your search

+2 -2
View File
@@ -178,7 +178,7 @@ void testSimple()
HIPASSERT((char*)attribs.hostPointer+Nbytes/2 == (char*)attribs2.hostPointer);
hipFreeHost(A_Pinned_h);
hipHostFree(A_Pinned_h);
e = hipPointerGetAttributes(&attribs, A_Pinned_h);
HIPASSERT(e == hipErrorUnknown); // Just freed the pointer, this should return an error.
printf("getAttr:%-20s err=%d (%s), neg-test expected\n", "A_d+NBytes", e, hipGetErrorString(e));
@@ -322,7 +322,7 @@ void clusterAllocs(int numAllocs, size_t minSize, size_t maxSize)
if (ref._attrib.memoryType == hipMemoryTypeDevice) {
hipFree(ref._pointer);
} else {
hipFreeHost(ref._pointer);
hipHostFree(ref._pointer);
}
}