SWDEV-415265 - Fix segfault when library isn't built with current GPU arch
- Return error code instead of segfault during kernel launch when library isn't built with current gpu arch
- Fix string print bug
Change-Id: I91aaa50150fee220317cd2eb4e075d825cc448b2
[ROCm/clr commit: 76c8b3157b]
Этот коммит содержится в:
коммит произвёл
Rakesh Roy
родитель
7792716dcf
Коммит
b3e340eb5d
@@ -196,7 +196,7 @@ hipError_t FatBinaryInfo::ExtractFatBinaryUsingCOMGR(const std::vector<hip::Devi
|
||||
auto dev_it = unique_isa_names.find(device_name);
|
||||
// If the size is 0, then COMGR API could not find the CO for this GPU device/ISA
|
||||
if (dev_it->second.first == 0) {
|
||||
LogPrintfError("Cannot find CO in the bundle for ISA: %s \n", device_name);
|
||||
LogPrintfError("Cannot find CO in the bundle for ISA: %s \n", device_name.c_str());
|
||||
hip_status = hipErrorNoBinaryForGpu;
|
||||
ListAllDeviceWithNoCOFromBundle(unique_isa_names);
|
||||
break;
|
||||
|
||||
@@ -128,6 +128,10 @@ hipError_t Function::getDynFunc(hipFunction_t* hfunc, hipModule_t hmod) {
|
||||
hipError_t Function::getStatFunc(hipFunction_t* hfunc, int deviceId) {
|
||||
guarantee(modules_ != nullptr, "Module not initialized");
|
||||
|
||||
if (dFunc_.size() != g_devices.size()) {
|
||||
return hipErrorSharedObjectInitFailed;
|
||||
}
|
||||
|
||||
hipModule_t hmod = nullptr;
|
||||
IHIP_RETURN_ONFAIL((*modules_)->BuildProgram(deviceId));
|
||||
IHIP_RETURN_ONFAIL((*modules_)->GetModule(deviceId, &hmod));
|
||||
|
||||
Ссылка в новой задаче
Block a user