Merge pull request #721 from fronteer/my-fix

Make correct checking of the returned hipDeviceptr_t from read_global…
Αυτή η υποβολή περιλαμβάνεται σε:
Maneesh Gupta
2018-11-08 11:42:08 +05:30
υποβλήθηκε από GitHub
γονέας 8d8d12f65d de5f47a984
υποβολή e672dc8a55
+2 -2
Προβολή Αρχείου
@@ -347,7 +347,7 @@ hipError_t read_agent_global_from_module(hipDeviceptr_t* dptr, size_t* bytes, hi
tie(*dptr, *bytes) = read_global_description(it0->second.cbegin(), it0->second.cend(), name);
return dptr ? hipSuccess : hipErrorNotFound;
return *dptr ? hipSuccess : hipErrorNotFound;
}
hipError_t read_agent_global_from_process(hipDeviceptr_t* dptr, size_t* bytes, const char* name) {
@@ -372,7 +372,7 @@ hipError_t read_agent_global_from_process(hipDeviceptr_t* dptr, size_t* bytes, c
tie(*dptr, *bytes) = read_global_description(it->second.cbegin(), it->second.cend(), name);
return dptr ? hipSuccess : hipErrorNotFound;
return *dptr ? hipSuccess : hipErrorNotFound;
}
hsa_executable_symbol_t find_kernel_by_name(hsa_executable_t executable, const char* kname) {