summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2014-03-07 09:27:05 -0500
committerKohei Yoshida <kohei.yoshida@collabora.com>2014-03-07 09:28:02 -0500
commit7a0ed3a406bd14bb2b52c383282daf4777ba76e0 (patch)
tree237dbd4107320159685acd884a02d1c3cd37c5e1 /sc
parent0f46b0694a42633500fb5267467a2b51978a57d2 (diff)
Disable pre-compilation of OpenCL kernels for now.
Change-Id: I1e61fab8ae26c11af05084db1a5542c066f69852
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/formulacell.cxx4
-rw-r--r--sc/source/core/opencl/formulagroupcl.cxx4
2 files changed, 5 insertions, 3 deletions
diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index 821bc67f3b11..a977ef717f33 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -54,7 +54,7 @@
#include <boost/scoped_ptr.hpp>
-#define ENABLE_THREADED_OPENCL_KERNEL_COMPILATION 1
+#define ENABLE_THREADED_OPENCL_KERNEL_COMPILATION 0
using namespace formula;
@@ -3506,8 +3506,6 @@ ScFormulaCellGroupRef ScFormulaCell::CreateCellGroup( SCROW nLen, bool bInvarian
#if ENABLE_THREADED_OPENCL_KERNEL_COMPILATION
if (mxGroup->sxCompilationThread.is())
mxGroup->scheduleCompilation();
-#else
- mxGroup->compileOpenCLKernel();
#endif
return mxGroup;
}
diff --git a/sc/source/core/opencl/formulagroupcl.cxx b/sc/source/core/opencl/formulagroupcl.cxx
index 3cf52f5e422c..dab611026f46 100644
--- a/sc/source/core/opencl/formulagroupcl.cxx
+++ b/sc/source/core/opencl/formulagroupcl.cxx
@@ -3208,6 +3208,10 @@ DynamicKernel::~DynamicKernel()
/// Build code
void DynamicKernel::CreateKernel(void)
{
+ if (mpKernel)
+ // already created.
+ return;
+
cl_int err;
std::string kname = "DynamicKernel"+mKernelSignature;
// Compile kernel here!!!