diff options
author | Tor Lillqvist <tml@collabora.com> | 2014-10-29 17:48:49 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2014-10-29 17:48:49 +0200 |
commit | 8007a9d1fc1912ec128199314f69562131eb10fb (patch) | |
tree | 32003b1dddc5521d80f09df4d9076d72e01c34f6 | |
parent | 3bdee6495ebc7f515d6d297e7f7df9a46acc3880 (diff) |
sc::opencl::getOpenCLPlatformCount is unneeded
The same information can be seem from the size of the vector reference
returned by sc::opencl::fillOpenCLInfo().
Change-Id: I797aacdf85a852bc4fa65e0536fd5940aed396a1
-rw-r--r-- | sc/source/core/inc/openclwrapper.hxx | 1 | ||||
-rw-r--r-- | sc/source/core/opencl/openclwrapper.cxx | 15 | ||||
-rw-r--r-- | sc/source/core/tool/formulagroup.cxx | 4 |
3 files changed, 0 insertions, 20 deletions
diff --git a/sc/source/core/inc/openclwrapper.hxx b/sc/source/core/inc/openclwrapper.hxx index ef9842ab03f1..bc3957f6641c 100644 --- a/sc/source/core/inc/openclwrapper.hxx +++ b/sc/source/core/inc/openclwrapper.hxx @@ -88,7 +88,6 @@ public: static void setKernelEnv( KernelEnv *envInfo ); }; -size_t getOpenCLPlatformCount(); const std::vector<OpenCLPlatformInfo>& fillOpenCLInfo(); /** diff --git a/sc/source/core/opencl/openclwrapper.cxx b/sc/source/core/opencl/openclwrapper.cxx index 0f462c07d7a3..464d70bd0ccf 100644 --- a/sc/source/core/opencl/openclwrapper.cxx +++ b/sc/source/core/opencl/openclwrapper.cxx @@ -754,21 +754,6 @@ bool createPlatformInfo(cl_platform_id nPlatformId, OpenCLPlatformInfo& rPlatfor } -size_t getOpenCLPlatformCount() -{ - int status = clewInit(OPENCL_DLL_NAME); - if (status < 0) - return 0; - - cl_uint nPlatforms; - cl_int nState = clGetPlatformIDs(0, NULL, &nPlatforms); - - if (nState != CL_SUCCESS) - return 0; - - return nPlatforms; -} - const std::vector<OpenCLPlatformInfo>& fillOpenCLInfo() { static std::vector<OpenCLPlatformInfo> aPlatforms; diff --git a/sc/source/core/tool/formulagroup.cxx b/sc/source/core/tool/formulagroup.cxx index 9d61efa195ce..32e83c6efc3c 100644 --- a/sc/source/core/tool/formulagroup.cxx +++ b/sc/source/core/tool/formulagroup.cxx @@ -540,10 +540,6 @@ void FormulaGroupInterpreter::fillOpenCLInfo(std::vector<OpenCLPlatformInfo>& rP #if !HAVE_FEATURE_OPENCL (void) rPlatforms; #else - size_t nPlatforms = sc::opencl::getOpenCLPlatformCount(); - if (!nPlatforms) - return; - const std::vector<sc::OpenCLPlatformInfo>& rPlatformsFromWrapper = sc::opencl::fillOpenCLInfo(); |