mirror of
https://github.com/CNugteren/CLBlast.git
synced 2024-07-04 21:36:57 +02:00
Added a check to prevent the stride of matrix C being set to 0 for the strided-batched-GEMM routine
This commit is contained in:
parent
9819957768
commit
afcf5dc6eb
|
@ -62,6 +62,9 @@ void XgemmStridedBatched<T>::DoGemmStridedBatched(const Layout layout, const Tra
|
||||||
throw BLASError(StatusCode::kInvalidBatchCount);
|
throw BLASError(StatusCode::kInvalidBatchCount);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Makes sure the strides are valid
|
||||||
|
if (c_stride == 0) { throw BLASError(StatusCode::kInvalidDimension); }
|
||||||
|
|
||||||
// Two methods to choose from, select which one to run
|
// Two methods to choose from, select which one to run
|
||||||
const auto do_gemm_direct = Xgemm<T>::UseDirectKernel(m, n, k, db_["XGEMM_MIN_INDIRECT_SIZE"]);
|
const auto do_gemm_direct = Xgemm<T>::UseDirectKernel(m, n, k, db_["XGEMM_MIN_INDIRECT_SIZE"]);
|
||||||
const auto gemm_kernel_id = (do_gemm_direct) ? 0 : db_["GEMMK"];
|
const auto gemm_kernel_id = (do_gemm_direct) ? 0 : db_["GEMMK"];
|
||||||
|
|
Loading…
Reference in a new issue