Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Hatfield committed Jun 25, 2019
2 parents 63ad9e2 + fbd224b commit 5b736ab
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cublas_gemm_c.cu
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,13 @@ extern "C" {
cudaErrCheck(cudaMemcpy(a_d, a_h, m*k*sizeof(double), cudaMemcpyHostToDevice));
cudaErrCheck(cudaMemcpy(b_d, b_h, k*n*sizeof(double), cudaMemcpyHostToDevice));

cublasOperation_t transa_int = (transa == 'N' || transa == 'n') ? CUBLAS_OP_N : CUBLAS_OP_T;
cublasOperation_t transb_int = (transb == 'N' || transb == 'n') ? CUBLAS_OP_N : CUBLAS_OP_T;
cublasOperation_t transa_op = (transa == 'N' || transa == 'n') ? CUBLAS_OP_N : CUBLAS_OP_T;
cublasOperation_t transb_op = (transb == 'N' || transb == 'n') ? CUBLAS_OP_N : CUBLAS_OP_T;

// Perform GEMM
cublasErrCheck(
cublasGemmEx(
cublasHandle, transa_int, transb_int,
cublasHandle, transa_op, transb_op,
m, n, k,
&alpha,
a_d, CUDA_R_64F, lda,
Expand Down

0 comments on commit 5b736ab

Please sign in to comment.