Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Return the proper PARSEC_HOOK_RETURN_ERROR in GPU error cases #99

Merged
merged 1 commit into from
Oct 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/zgemm_NN.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)B, ldbk,
lbeta, (cuDoubleComplex*)C, ldcm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/zgemm_NN_summa.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,7 @@ BODY [type=CUDA
(cuDoubleComplex*)B, ldbk,
lbeta, (cuDoubleComplex*)C, ldcm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/zgemm_NT.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,7 @@ BODY [type=CUDA
(cuDoubleComplex*)B, ldbn,
lbeta, (cuDoubleComplex*)C, ldcm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/zgemm_NT_summa.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,7 @@ BODY [type=CUDA
(cuDoubleComplex*)B, ldbn,
lbeta, (cuDoubleComplex*)C, ldcm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/zgemm_TN.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,7 @@ BODY [type=CUDA
(cuDoubleComplex*)B, ldbk,
lbeta, (cuDoubleComplex*)C, ldcm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/zgemm_TN_summa.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -236,8 +236,7 @@ BODY [type=CUDA
(cuDoubleComplex*)B, ldbk,
lbeta, (cuDoubleComplex*)C, ldcm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/zgemm_TT.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,7 @@ BODY [type=CUDA
(cuDoubleComplex*)B, ldbn,
lbeta, (cuDoubleComplex*)C, ldcm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/zgemm_TT_summa.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -239,8 +239,7 @@ BODY [type=CUDA
if(status != CUBLAS_STATUS_SUCCESS){
printf("ISSUE\n");
}
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/zgetrf_nopiv.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,7 @@ BODY [type=CUDA
(cuDoubleComplex*)B, ldak_B,
zone, (cuDoubleComplex*)C, ldam_C);
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
9 changes: 3 additions & 6 deletions src/zpoinv_L.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)B, ldan,
zone, (cuDoubleComplex*)C, ldam );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -268,8 +267,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)B, ldak,
zone, (cuDoubleComplex*)C, ldam );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -437,8 +435,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)B, ldak,
zone, (cuDoubleComplex*)C, ldam );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
9 changes: 3 additions & 6 deletions src/zpoinv_U.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)B, ldak,
zone, (cuDoubleComplex*)C, ldan );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -266,8 +265,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)B, ldak,
zone, (cuDoubleComplex*)C, ldam );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -434,8 +432,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)B, ldan,
zone, (cuDoubleComplex*)C, ldam );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
13 changes: 4 additions & 9 deletions src/zpotrf_L.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,7 @@ BODY [type=CUDA
d_iinfo = (int*)(wp->tmpmem + wp->lwork * sizeof(cuDoubleComplex));

status = cusolverDnZpotrf( handles->cusolverDn_handle, cublas_uplo, tempkm, T, ldak, workspace, wp->lwork, d_iinfo);
PARSEC_CUDA_CHECK_ERROR( "cublasZpotrf_v2 ", status,
{return PARSEC_HOOK_RETURN_ERROR;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZpotrf_v2 ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -238,12 +237,10 @@ BODY [type=CUDA]
CUBLAS_OP_C, CUBLAS_DIAG_NON_UNIT,
tempmm, descA->nb,
&zone, T, ldak, C, ldam);
PARSEC_CUDA_CHECK_ERROR( "cublasZtrsm_v2 ", status,
{return PARSEC_HOOK_RETURN_ERROR;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZtrsm_v2 ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END


BODY [type=RECURSIVE]
{
int tempmm = m == descA->mt-1 ? descA->m - m * descA->mb : descA->mb;
Expand Down Expand Up @@ -346,8 +343,7 @@ BODY [type=CUDA]
tempmm, descA->mb,
&mzone, A, ldam_A,
&zone, T, ldam_T);
PARSEC_CUDA_CHECK_ERROR( "cublasZherk_v2 ", status,
{return PARSEC_HOOK_RETURN_ERROR;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZherk_v2 ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -469,8 +465,7 @@ BODY [type=CUDA
&mzone, (cuDoubleComplex*)A, ldam_A,
(cuDoubleComplex*)B, ldan_B,
&zone, (cuDoubleComplex*)C, ldam_C );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm_v2 ", status,
{return PARSEC_HOOK_RETURN_ERROR;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm_v2 ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
12 changes: 4 additions & 8 deletions src/zpotrf_U.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,7 @@ BODY [type=CUDA
d_iinfo = (int*)(wp->tmpmem + wp->lwork * sizeof(cuDoubleComplex));

status = cusolverDnZpotrf( handles->cusolverDn_handle, cublas_uplo, tempkn, T, ldak, workspace, wp->lwork, d_iinfo);
PARSEC_CUDA_CHECK_ERROR( "cublasZpotrf_v2 ", status,
{return PARSEC_HOOK_RETURN_ERROR;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZpotrf_v2 ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -240,8 +239,7 @@ BODY [type=CUDA]
CUBLAS_OP_C, CUBLAS_DIAG_NON_UNIT,
descA->mb, tempnn,
&zone, T, ldak_T, C, ldak_C);
PARSEC_CUDA_CHECK_ERROR( "cublasZtrsm_v2 ", status,
{return PARSEC_HOOK_RETURN_ERROR;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZtrsm_v2 ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -349,8 +347,7 @@ BODY [type=CUDA]
&mzone, A, ldak,
&zone, T, ldan);

PARSEC_CUDA_CHECK_ERROR( "cublasZherk_v2 ", status,
{return PARSEC_HOOK_RETURN_ERROR;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZherk_v2 ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down Expand Up @@ -473,8 +470,7 @@ BODY [type=CUDA
&mzone, (cuDoubleComplex*)A, ldak_A,
(cuDoubleComplex*)B, ldak_B,
&zone, (cuDoubleComplex*)C, ldam_C);
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm_v2 ", status,
{return PARSEC_HOOK_RETURN_ERROR;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm_v2 ", status, {return PARSEC_HOOK_RETURN_ERROR;} );

printlogcuda("CUDA_zgemm( %d, %d, %d )\n\t( %s, %s, %d, %d, %d, %f, A(%d,%d)[%p], %d, A(%d,%d)[%p], %d, %f, A(%d,%d)[%p], %d)\n",
m, n, k,
Expand Down
3 changes: 1 addition & 2 deletions src/ztrsm_LLN.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)D, ldbk,
lalpha, (cuDoubleComplex*)E, ldb );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/ztrsm_LLT.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)D, ldb,
lalpha, (cuDoubleComplex*)E, ldbm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/ztrsm_LUN.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)D, ldb,
lalpha, (cuDoubleComplex*)E, ldbm );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/ztrsm_LUT.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)D, ldbk,
lalpha, (cuDoubleComplex*)E, ldb );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/ztrsm_RLN.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)D, lda,
lalpha, (cuDoubleComplex*)E, ldb );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/ztrsm_RLT.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)D, ldan,
zone, (cuDoubleComplex*)E, ldb );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/ztrsm_RUN.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)D, lda,
lalpha, (cuDoubleComplex*)E, ldb );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
3 changes: 1 addition & 2 deletions src/ztrsm_RUT.jdf
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,7 @@ BODY [type=CUDA]
(cuDoubleComplex*)D, ldan,
zone, (cuDoubleComplex*)E, ldb );
status = cublasGetError();
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status,
{return -1;} );
PARSEC_CUDA_CHECK_ERROR( "cublasZgemm ", status, {return PARSEC_HOOK_RETURN_ERROR;} );
}
END

Expand Down
Loading