SWDEV-254363 - Checks to make sure kernel is launched on the same device as it was launched.
Change-Id: I2f273a70b1a5fc0e9fc9c6144eabd32466ff4e59
[ROCm/hip commit: c4505bede3]
This commit is contained in:
gecommit door
Karthik Jayaprakash
bovenliggende
a3a8ca1359
commit
644e635e64
@@ -160,22 +160,26 @@ DynCO::~DynCO() {
|
||||
delete fb_info_;
|
||||
}
|
||||
|
||||
hipError_t DynCO::getDeviceVar(DeviceVar** dvar, std::string var_name, int device_id) {
|
||||
hipError_t DynCO::getDeviceVar(DeviceVar** dvar, std::string var_name) {
|
||||
amd::ScopedLock lock(dclock_);
|
||||
|
||||
CheckDeviceIdMatch();
|
||||
|
||||
auto it = vars_.find(var_name);
|
||||
if (it == vars_.end()) {
|
||||
DevLogPrintfError("Cannot find the Var: %s ", var_name.c_str());
|
||||
return hipErrorNotFound;
|
||||
}
|
||||
|
||||
it->second->getDeviceVar(dvar, device_id, module());
|
||||
it->second->getDeviceVar(dvar, device_id_, module());
|
||||
return hipSuccess;
|
||||
}
|
||||
|
||||
hipError_t DynCO::getDynFunc(hipFunction_t* hfunc, std::string func_name) {
|
||||
amd::ScopedLock lock(dclock_);
|
||||
|
||||
CheckDeviceIdMatch();
|
||||
|
||||
auto it = functions_.find(func_name);
|
||||
if (it == functions_.end()) {
|
||||
DevLogPrintfError("Cannot find the function: %s ", func_name.c_str());
|
||||
|
||||
Verwijs in nieuw issue
Block a user