Skip to content

Commit 2a960ba

Browse files
committed
[HIP] Update urQueueCreate to fix build
1 parent 2c5c237 commit 2a960ba

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

source/adapters/hip/queue.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,15 +119,15 @@ urQueueCreate(ur_context_handle_t hContext, ur_device_handle_t hDevice,
119119

120120
unsigned int Flags = 0;
121121
ur_queue_flags_t URFlags = 0;
122-
int Priority = 0; // Not guaranteed, but, in ROCm 5.7, 0 is the default
122+
int Priority = 0; // Not guaranteed, but, in ROCm 5.0-6.0, 0 is the default
123123

124124
if (pProps && pProps->stype == UR_STRUCTURE_TYPE_QUEUE_PROPERTIES) {
125125
URFlags = pProps->flags;
126126
if (URFlags & UR_QUEUE_FLAG_PRIORITY_HIGH) {
127-
ScopedContext Active(hContext->getDevice());
127+
ScopedContext Active(hDevice);
128128
UR_CHECK_ERROR(hipDeviceGetStreamPriorityRange(nullptr, &Priority));
129129
} else if (URFlags & UR_QUEUE_FLAG_PRIORITY_LOW) {
130-
ScopedContext Active(hContext->getDevice());
130+
ScopedContext Active(hDevice);
131131
UR_CHECK_ERROR(hipDeviceGetStreamPriorityRange(&Priority, nullptr));
132132
}
133133
}

0 commit comments

Comments
 (0)