diff --git a/projects/hip/api/hip/hip_module.cpp b/projects/hip/api/hip/hip_module.cpp index fe87f93a7b..23cf47d724 100644 --- a/projects/hip/api/hip/hip_module.cpp +++ b/projects/hip/api/hip/hip_module.cpp @@ -222,6 +222,9 @@ hipError_t ihipModuleLaunchKernel(hipFunction_t f, command->enqueue(); if(stopEvent != nullptr) { + if (eStop->event_ != nullptr) { + eStop->event_->release(); + } eStop->event_ = &command->event(); command->retain(); }