Merge pull request #1916 from asalmanp/refactor_cooperative_APIs

[HIP] Refactor cooperative APIs

[ROCm/clr commit: bf385d8641]
This commit is contained in:
Evgeny Mankov
2020-03-12 19:12:50 +03:00
committed by GitHub
2 changed files with 206 additions and 131 deletions
+3 -1
View File
@@ -1624,7 +1624,9 @@ void ihipPrintKernelLaunch(const char* kernelName, const grid_launch_parm* lp,
// Allows runtime to track some information about the stream.
hipStream_t ihipPreLaunchKernel(hipStream_t stream, dim3 grid, dim3 block, grid_launch_parm* lp,
const char* kernelNameStr, bool lockAcquired) {
stream = ihipSyncAndResolveStream(stream, lockAcquired);
if (stream == nullptr || stream != stream->getCtx()->_defaultStream) {
stream = ihipSyncAndResolveStream(stream, lockAcquired);
}
lp->grid_dim.x = grid.x;
lp->grid_dim.y = grid.y;
lp->grid_dim.z = grid.z;