Skip to content

Commit 55cf3ba

Browse files
authored
Merge pull request #1437 from hdelan/event-wait-with-good-context
[HIP] Use context to get active device
2 parents 15233fd + 35a6899 commit 55cf3ba

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/adapters/hip/event.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ urEventWait(uint32_t numEvents, const ur_event_handle_t *phEventWaitList) {
190190
UR_ASSERT(numEvents > 0, UR_RESULT_ERROR_INVALID_VALUE);
191191

192192
try {
193-
ScopedContext Active(phEventWaitList[0]->getDevice());
193+
ScopedContext Active(phEventWaitList[0]->getContext()->getDevices()[0]);
194194
auto WaitFunc = [](ur_event_handle_t Event) -> ur_result_t {
195195
UR_ASSERT(Event, UR_RESULT_ERROR_INVALID_EVENT);
196196

0 commit comments

Comments
 (0)