Only print warning that cusparseSolver did not converge if it was chosen with --use-gpu=true

This commit is contained in:
T.D. (Tongdong) Qiu 2019-12-09 10:02:21 +01:00
parent b355537e04
commit 13e524dba2

View File

@ -475,7 +475,10 @@ protected:
bdaBridge->get_result(x);
}else{
// CPU fallback, or default case for Dune
OpmLog::warning("cusparseSolver did not converge, now trying Dune to solve current linear system...");
const bool use_gpu = EWOMS_GET_PARAM(TypeTag, bool, UseGpu);
if(use_gpu){
OpmLog::warning("cusparseSolver did not converge, now trying Dune to solve current linear system...");
}
auto precond = constructPrecond(linearOperator, parallelInformation_arg);
solve(linearOperator, x, istlb, *sp, *precond, result);
} // end Dune call