From 87c279cf1ef8576b06ca183cb3122c3b2f2736ca Mon Sep 17 00:00:00 2001 From: Aditya Avinash Atluri Date: Thu, 3 Mar 2016 13:48:58 -0600 Subject: [PATCH] Changed test to match CUDA output of errors We changed the test so that it runs on CUDA. As we are emulating CUDA behavior, this should pass on HIP. [ROCm/clr commit: c5606c13e79b3b5311c70da45024bd70554027a0] --- projects/clr/hipamd/tests/src/hipPointerAttrib.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/projects/clr/hipamd/tests/src/hipPointerAttrib.cpp b/projects/clr/hipamd/tests/src/hipPointerAttrib.cpp index 3d5075950c..b9745a1903 100644 --- a/projects/clr/hipamd/tests/src/hipPointerAttrib.cpp +++ b/projects/clr/hipamd/tests/src/hipPointerAttrib.cpp @@ -164,7 +164,7 @@ void testSimple() hipFree(A_d); e = hipPointerGetAttributes(&attribs, A_d); - HIPASSERT(e == hipErrorInvalidValue); // Just freed the pointer, this should return an error. + HIPASSERT(e == hipErrorUnknown); // Just freed the pointer, this should return an error. // Device-visible host memory @@ -180,7 +180,7 @@ void testSimple() hipFreeHost(A_Pinned_h); e = hipPointerGetAttributes(&attribs, A_Pinned_h); - HIPASSERT(e == hipErrorInvalidValue); // Just freed the pointer, this should return an error. + 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)); @@ -188,7 +188,7 @@ void testSimple() printf ("\nOS-allocated memory (malloc)\n"); e = hipPointerGetAttributes(&attribs, A_OSAlloc_h); printf("getAttr:%-20s err=%d (%s), neg-test expected\n", "A_OSAlloc_h", e, hipGetErrorString(e)); - HIPASSERT(e == hipErrorInvalidValue); // OS-allocated pointers should return hipErrorInvalidValue. + HIPASSERT(e == hipErrorUnknown); // OS-allocated pointers should return hipErrorUnknown. } //---