Skip to content

Commit 245afd1

Browse files
committed
fixing returns 700 and then takes an exit path that causes to return 3. @obilaniu
1 parent fdf790b commit 245afd1

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/gpuarray_blas_cuda_cublas.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -835,6 +835,9 @@ static int sgemmBatch(cb_order order, cb_transpose transA, cb_transpose transB,
835835
return ctx->err->code;
836836
}
837837

838+
// added cuda_wait
839+
GA_CUDA_EXIT_ON_ERROR(ctx, cuda_wait(Ta, CUDA_WAIT_ALL));
840+
838841
err = cublasSgemmBatched(h->h,
839842
convT(transA), convT(transB),
840843
M, N, K, &alpha,
@@ -962,6 +965,9 @@ static int dgemmBatch(cb_order order, cb_transpose transA, cb_transpose transB,
962965
return ctx->err->code;
963966
}
964967

968+
// added cuda_wait
969+
GA_CUDA_EXIT_ON_ERROR(ctx, cuda_wait(Ta, CUDA_WAIT_ALL));
970+
965971
err = cublasDgemmBatched(h->h,
966972
convT(transA), convT(transB),
967973
M, N, K, &alpha,

0 commit comments

Comments
 (0)