Skip to content

Commit 4954d14

Browse files
committed
Comments
1 parent 2c0ac74 commit 4954d14

File tree

1 file changed

+2
-1
lines changed
  • offload/plugins-nextgen/amdgpu/src

1 file changed

+2
-1
lines changed

offload/plugins-nextgen/amdgpu/src/rtl.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -999,6 +999,7 @@ struct AMDGPUStreamTy {
999999
if (Callbacks.empty())
10001000
return Plugin::success();
10011001

1002+
assert(Callbacks.size() == ActionArgs.size() "Size mismatch");
10021003
for (auto [Callback, ActionArg] : llvm::zip(Callbacks, ActionArgs)) {
10031004
// Perform the action.
10041005
if (Callback == memcpyAction) {
@@ -1010,7 +1011,7 @@ struct AMDGPUStreamTy {
10101011
} else if (Callback == releaseSignalAction) {
10111012
if (auto Err = releaseSignalAction(&ActionArg))
10121013
return Err;
1013-
} else {
1014+
} else if (Callback) {
10141015
if (auto Err = Callback(ActionArg.CallbackArgs))
10151016
return Err;
10161017
}

0 commit comments

Comments
 (0)