Skip to content

Commit bf572d4

Browse files
committed
Respond to feedback
1 parent 8989e58 commit bf572d4

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
@@ -77,8 +77,6 @@ struct __tgt_async_info {
7777
llvm::SmallVector<void *, 2> AssociatedAllocations;
7878

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

8482
/// 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
@@ -486,7 +486,8 @@ Error olSyncQueue_impl(ol_queue_handle_t Queue) {
486486
// on it, but we have nothing to synchronize in that situation anyway.
487487
if (Queue->AsyncInfo->Queue) {
488488
// We don't need to release the queue and we would like the ability for
489-
// other offload threads to submit work concurrently, so pass "false" here.
489+
// other offload threads to submit work concurrently, so pass "false" here
490+
// so we don't release the underlying queue object.
490491
if (auto Err = Queue->Device->Device->synchronize(Queue->AsyncInfo, false))
491492
return Err;
492493
}

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ struct AsyncInfoWrapperTy {
119119
/// Register \p Ptr as an associated allocation that is freed after
120120
/// finalization.
121121
void freeAllocationAfterSynchronization(void *Ptr) {
122-
std::lock_guard<std::mutex> AllocationGuard{AsyncInfoPtr->Mutex};
122+
std::lock_guard<std::mutex> AllocationGuard(AsyncInfoPtr->Mutex);
123123
AsyncInfoPtr->AssociatedAllocations.push_back(Ptr);
124124
}
125125

0 commit comments

Comments
 (0)