@@ -59,8 +59,8 @@ bool WaitListEmptyOrAllEventsFromSameQueue(
59
59
return true ;
60
60
}
61
61
62
- UR_APIEXPORT ur_result_t UR_APICALL urEnqueueEventsWait (
63
- ur_queue_handle_t UrQueue, // /< [in] handle of the queue object
62
+ ur_result_t ur_queue_handle_legacy_t_::enqueueEventsWait ( // /< [in] handle of
63
+ // /< the queue object
64
64
uint32_t NumEventsInWaitList, // /< [in] size of the event wait list
65
65
const ur_event_handle_t
66
66
*EventWaitList, // /< [in][optional][range(0, numEventsInWaitList)]
@@ -72,7 +72,7 @@ UR_APIEXPORT ur_result_t UR_APICALL urEnqueueEventsWait(
72
72
*OutEvent // /< [in,out][optional] return an event object that identifies
73
73
// /< this particular command instance.
74
74
) {
75
- auto Queue = Legacy (UrQueue) ;
75
+ auto Queue = this ;
76
76
if (EventWaitList) {
77
77
bool UseCopyEngine = false ;
78
78
@@ -152,8 +152,9 @@ static const bool InOrderBarrierBySignal = [] {
152
152
return (UrRet ? std::atoi (UrRet) : true );
153
153
}();
154
154
155
- UR_APIEXPORT ur_result_t UR_APICALL urEnqueueEventsWaitWithBarrier (
156
- ur_queue_handle_t UrQueue, // /< [in] handle of the queue object
155
+ ur_result_t
156
+ ur_queue_handle_legacy_t_::enqueueEventsWaitWithBarrier ( // /< [in] handle of the
157
+ // /< queue object
157
158
uint32_t NumEventsInWaitList, // /< [in] size of the event wait list
158
159
const ur_event_handle_t
159
160
*EventWaitList, // /< [in][optional][range(0, numEventsInWaitList)]
@@ -165,7 +166,7 @@ UR_APIEXPORT ur_result_t UR_APICALL urEnqueueEventsWaitWithBarrier(
165
166
*OutEvent // /< [in,out][optional] return an event object that identifies
166
167
// /< this particular command instance.
167
168
) {
168
- auto Queue = Legacy (UrQueue) ;
169
+ auto Queue = this ;
169
170
170
171
// Lock automatically releases when this goes out of scope.
171
172
std::scoped_lock<ur_shared_mutex> lock (Queue->Mutex );
@@ -661,8 +662,7 @@ UR_APIEXPORT ur_result_t UR_APICALL urEventGetProfilingInfo(
661
662
return UR_RESULT_SUCCESS;
662
663
}
663
664
664
- UR_APIEXPORT ur_result_t UR_APICALL urEnqueueTimestampRecordingExp (
665
- ur_queue_handle_t UrQueue, // /< [in] handle of the queue object
665
+ ur_result_t ur_queue_handle_legacy_t_::enqueueTimestampRecordingExp (
666
666
bool Blocking, // /< [in] blocking or non-blocking enqueue
667
667
uint32_t NumEventsInWaitList, // /< [in] size of the event wait list
668
668
const ur_event_handle_t
@@ -676,7 +676,7 @@ UR_APIEXPORT ur_result_t UR_APICALL urEnqueueTimestampRecordingExp(
676
676
*OutEvent // /< [in,out] return an event object that identifies
677
677
// /< this particular command instance.
678
678
) {
679
- auto Queue = Legacy (UrQueue) ;
679
+ auto Queue = this ;
680
680
// Lock automatically releases when this goes out of scope.
681
681
std::scoped_lock<ur_shared_mutex> lock (Queue->Mutex );
682
682
@@ -1022,7 +1022,6 @@ ur_result_t urEventReleaseInternal(ur_event_handle_t Event) {
1022
1022
1023
1023
// Save pointer to the queue before deleting/resetting event.
1024
1024
auto Queue = Legacy (Event->UrQueue );
1025
- auto URQueue = Event->UrQueue ;
1026
1025
1027
1026
// If the event was a timestamp recording, we try to evict its entry in the
1028
1027
// queue.
@@ -1054,8 +1053,8 @@ ur_result_t urEventReleaseInternal(ur_event_handle_t Event) {
1054
1053
// created so that we can avoid ur_queue_handle_t is released before the
1055
1054
// associated ur_event_handle_t is released. Here we have to decrement it so
1056
1055
// ur_queue_handle_t can be released successfully.
1057
- if (URQueue ) {
1058
- UR_CALL (urQueueReleaseInternal (URQueue ));
1056
+ if (Queue ) {
1057
+ UR_CALL (urQueueReleaseInternal (Queue ));
1059
1058
}
1060
1059
1061
1060
return UR_RESULT_SUCCESS;
0 commit comments