improve code object loading error message (#1889)

Tá an tiomantas seo le fáil i:
Siu Chi Chan údaraithe agus GitHub tiomanta 2020-02-28 16:47:40 +05:30
1 tuismitheoir 3e1f41c165
tiomantas 57edf48191
1 comhad athraithe
+5 -1
+5 -1
Féach ar an gComhad
@@ -426,7 +426,11 @@ public:
auto check_hsa_error = [](hsa_status_t s) {
if (s != HSA_STATUS_SUCCESS) {
hip_throw(std::runtime_error{"error when loading code object"});
const char* hsa_err_msg;
hsa_status_string(s, &hsa_err_msg);
hip_throw(std::runtime_error{
std::string("error when loading code object: ") +
hsa_err_msg});
}
};