SWDEV-374402 - Added check for invalid events in hipExtLaunchKernel

Change-Id: I8dfd69aa1ef38971a72b98c723d2099347a66d11
Bu işleme şunda yer alıyor:
Ioannis Assiouras committed 2022-12-21 12:37:12 -05:00
1 ebeveyn 845bf0adb4
işleme b83271b4ca
3 files changed
+17 -1

No files matched your search

+15
Dosyayı Görüntüle
@@ -260,6 +260,21 @@ hipError_t Event::addMarker(hipStream_t stream, amd::Command* command, bool reco
return status;
}
// ================================================================================================
bool isValid(hipEvent_t event) {
// NULL event is always valid
if (event == nullptr) {
return true;
}
amd::ScopedLock lock(eventSetLock);
if (eventSet.find(event) == eventSet.end()) {
return false;
}
return true;
}
} // namespace hip
// ================================================================================================
hipError_t ihipEventCreateWithFlags(hipEvent_t* event, unsigned flags) {