[Libreoffice-commits] core.git: sc/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Wed Nov 14 15:10:04 UTC 2018
sc/source/core/tool/formulagroup.cxx | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
New commits:
commit 080e58a9f69ea0e1c815eb66427baf2c6b330d9e
Author: Luboš Luňák <l.lunak at collabora.com>
AuthorDate: Mon Oct 15 13:40:32 2018 +0200
Commit: Luboš Luňák <l.lunak at collabora.com>
CommitDate: Wed Nov 14 16:09:37 2018 +0100
abort if opencl fails with SC_FORCE_CALCULATION=opencl
Otherwise calculation would silently fall back to other methods.
Change-Id: I3cf624b709e7007ae16736a1ecb91b7d3c18df8e
Reviewed-on: https://gerrit.libreoffice.org/63189
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak at collabora.com>
diff --git a/sc/source/core/tool/formulagroup.cxx b/sc/source/core/tool/formulagroup.cxx
index 533c0c002d87..eef51c328496 100644
--- a/sc/source/core/tool/formulagroup.cxx
+++ b/sc/source/core/tool/formulagroup.cxx
@@ -164,7 +164,14 @@ FormulaGroupInterpreter *FormulaGroupInterpreter::getStatic()
if (ScCalcConfig::isOpenCLEnabled())
{
const ScCalcConfig& rConfig = ScInterpreter::GetGlobalConfig();
- switchOpenCLDevice(rConfig.maOpenCLDevice, rConfig.mbOpenCLAutoSelect);
+ if( !switchOpenCLDevice(rConfig.maOpenCLDevice, rConfig.mbOpenCLAutoSelect))
+ {
+ if( ScCalcConfig::getForceCalculationType() == ForceCalculationOpenCL )
+ {
+ SAL_WARN( "opencl", "OpenCL forced but failed to initialize" );
+ abort();
+ }
+ }
}
#endif
}
More information about the Libreoffice-commits
mailing list