aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/stream_executor/cuda
diff options
context:
space:
mode:
authorGravatar A. Unique TensorFlower <gardener@tensorflow.org>2018-06-19 14:17:54 -0700
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2018-06-19 14:21:43 -0700
commit27c27c58e1f8b4ac86f85eb201f0d9d667fa83a1 (patch)
tree63eb2e9b045563cea30268372ab7ff988358b9cc /tensorflow/stream_executor/cuda
parent445f16740007f209f426149fcf9b3c6ef4344532 (diff)
Improve filter for cuBLAS bug.
PiperOrigin-RevId: 201239428
Diffstat (limited to 'tensorflow/stream_executor/cuda')
-rw-r--r--tensorflow/stream_executor/cuda/cuda_blas.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/tensorflow/stream_executor/cuda/cuda_blas.cc b/tensorflow/stream_executor/cuda/cuda_blas.cc
index 31e407f199..874bf0e8cb 100644
--- a/tensorflow/stream_executor/cuda/cuda_blas.cc
+++ b/tensorflow/stream_executor/cuda/cuda_blas.cc
@@ -2183,8 +2183,8 @@ bool CUDABlas::DoBlasGemmWithAlgorithmImpl(
// Return false if we might be hitting a cuBLAS bug that produces the wrong
// result. See nvbugs/2156201, b/79126339.
-#if (CUDA_VERSION >= 9000)
- if (CUDA_VERSION < 9020 && algorithm != CUBLAS_GEMM_ALGO12 &&
+#if CUDA_VERSION >= 9000 && CUDA_VERSION < 9020
+ if ((algorithm == CUBLAS_GEMM_DEFAULT || algorithm >= CUBLAS_GEMM_ALGO13) &&
std::max({m, n, k}) >= 2097153 && cc_major < 7) {
return false;
}