Skip to content

Commit 02886c1

Browse files
committed
Respond to feedback
1 parent a45d8b0 commit 02886c1

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

offload/include/Shared/APITypes.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,6 @@ struct __tgt_async_info {
7878
llvm::SmallVector<void *, 2> AssociatedAllocations;
7979

8080
/// Mutex to guard access to AssociatedAllocations and the Queue.
81-
/// This is only used for liboffload and should be ignored in libomptarget
82-
/// code.
8381
std::mutex Mutex;
8482

8583
/// The kernel launch environment used to issue a kernel. Stored here to

offload/liboffload/src/OffloadImpl.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -488,7 +488,8 @@ Error olSyncQueue_impl(ol_queue_handle_t Queue) {
488488
// on it, but we have nothing to synchronize in that situation anyway.
489489
if (Queue->AsyncInfo->Queue) {
490490
// We don't need to release the queue and we would like the ability for
491-
// other offload threads to submit work concurrently, so pass "false" here.
491+
// other offload threads to submit work concurrently, so pass "false" here
492+
// so we don't release the underlying queue object.
492493
if (auto Err = Queue->Device->Device->synchronize(Queue->AsyncInfo, false))
493494
return Err;
494495
}

offload/plugins-nextgen/common/include/PluginInterface.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ struct AsyncInfoWrapperTy {
153153
/// Register \p Ptr as an associated allocation that is freed after
154154
/// finalization.
155155
void freeAllocationAfterSynchronization(void *Ptr) {
156-
std::lock_guard<std::mutex> AllocationGuard{AsyncInfoPtr->Mutex};
156+
std::lock_guard<std::mutex> AllocationGuard(AsyncInfoPtr->Mutex);
157157
AsyncInfoPtr->AssociatedAllocations.push_back(Ptr);
158158
}
159159

0 commit comments

Comments
 (0)