diff --git a/sc/source/core/opencl/formulagroupcl.cxx b/sc/source/core/opencl/formulagroupcl.cxx index b30fa97f854f..6855434d37b7 100644 --- a/sc/source/core/opencl/formulagroupcl.cxx +++ b/sc/source/core/opencl/formulagroupcl.cxx @@ -3771,11 +3771,6 @@ DynamicKernelSoPArguments::DynamicKernelSoPArguments(const ScCalcConfig& config, mvSubArguments.push_back(SoPHelper(mCalcConfig, ts, ft->Children[i], std::make_shared(), nResultSize)); } - else if (pChild->GetExternal() == "com.sun.star.sheet.addin.Analysis.getConvert") - { - mvSubArguments.push_back(SoPHelper(mCalcConfig, ts, ft->Children[i], - std::make_shared(), nResultSize)); - } else if (pChild->GetExternal() == "com.sun.star.sheet.addin.Analysis.getIseven") { mvSubArguments.push_back(SoPHelper(mCalcConfig, ts, ft->Children[i], diff --git a/sc/source/core/opencl/op_math.cxx b/sc/source/core/opencl/op_math.cxx index 4042e2511177..5914436ffd8e 100644 --- a/sc/source/core/opencl/op_math.cxx +++ b/sc/source/core/opencl/op_math.cxx @@ -2642,72 +2642,6 @@ void OpCombin::GenSlidingWindowFunction(std::stringstream &ss, ss << " return result;\n"; ss << "}\n"; } -void OpConvert::GenSlidingWindowFunction( - std::stringstream &ss, const std::string &sSymName, - SubArguments &vSubArguments) -{ - // The CONVERT function converts a value from one unit of - // measurement to another. It takes the units of measurements to - // convert between as string arguments. This implementation - // handles just a very small subset of such conversions. - - int arg1=vSubArguments[1]->GetFormulaToken()->GetString(). - getString().toAsciiUpperCase().hashCode(); - int arg2=vSubArguments[2]->GetFormulaToken()->GetString(). - getString().toAsciiUpperCase().hashCode(); - - // Check if the from and to units are those combinations that the - // code below supports. - if( !((arg1==5584&&arg2==108)|| - (arg1==108&&arg2==5584)|| - (arg1==5665&&arg2==268206)|| - (arg1==268206&&arg2==5665)) ) - throw Unhandled(__FILE__, __LINE__); - - FormulaToken *tmpCur = vSubArguments[0]->GetFormulaToken(); - const formula::SingleVectorRefToken*tmpCurDVR= static_cast(tmpCur); - ss << "\ndouble " << sSymName; - ss << "_"<< BinFuncName() <<"("; - for (size_t i = 0; i < vSubArguments.size(); i++) - { - if (i) - ss << ","; - vSubArguments[i]->GenSlidingWindowDecl(ss); - } - ss << ")\n{\n"; - ss <<" int gid0=get_global_id(0);\n"; - ss << " double arg0 = " << vSubArguments[0]->GenSlidingWindowDeclRef(); - ss << ";\n"; - ss << " double arg1 = " << vSubArguments[1]->GenSlidingWindowDeclRef(); - ss << ";\n"; - ss << " double arg2 = " << vSubArguments[2]->GenSlidingWindowDeclRef(); - ss << ";\n"; - ss<< " if(isnan(arg0)||(gid0>="; - ss<GetArrayLength(); - ss<<"))\n"; - ss<<" arg0 = 0;\n"; - ss<< " if(isnan(arg1)||(gid0>="; - ss<GetArrayLength(); - ss<<"))\n"; - ss<<" arg1 = 0;\n"; - ss<< " if(isnan(arg2)||(gid0>="; - ss<GetArrayLength(); - ss<<"))\n"; - ss<<" arg2 = 0;\n"; - ss<<" if(arg1==5584U&&arg2==108U)\n"; - ss<<" return arg0*1000.0;\n"; - ss<<" else if(arg1==108U&&arg2==3385U)\n"; - ss<<" return arg0/1000.0;\n"; - ss<<" else if(arg1==5665U&&arg2==268206U)\n"; - ss<<" return arg0*60.0;\n"; - ss<<" else if(arg1==268206U&&arg2==5665U)\n"; - ss<<" return arg0/60.0;\n"; - ss<<" else\n"; - ss<<" return -9999999999;\n"; - ss << "}\n"; - -} void OpProduct::GenSlidingWindowFunction(std::stringstream &ss, const std::string &sSymName, SubArguments &vSubArguments) diff --git a/sc/source/core/opencl/op_math.hxx b/sc/source/core/opencl/op_math.hxx index f001d1b78beb..e8111403abbf 100644 --- a/sc/source/core/opencl/op_math.hxx +++ b/sc/source/core/opencl/op_math.hxx @@ -356,15 +356,6 @@ public: const std::string &sSymName, SubArguments &vSubArguments) override; virtual std::string BinFuncName() const override { return "Log10"; } }; -class OpConvert: public Normal -{ -public: - virtual void GenSlidingWindowFunction(std::stringstream &ss, - const std::string &sSymName, SubArguments &vSubArguments) override; - virtual std::string BinFuncName() const override { return "Convert"; } - virtual bool takeString() const override { return true; } - -}; class OpEven: public Normal { public: