summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorI-Jui (Ray) Sung <ray@multicorewareinc.com>2013-11-15 14:16:40 -0600
committerI-Jui (Ray) Sung <ray@multicorewareinc.com>2013-11-15 14:20:40 -0600
commit46dbc13169a9b97d3f8ac310ac35d5f51eea7de6 (patch)
tree59ba01d82d133782811bdf0d19bb7e72b2488d98
parent118d63cd5214c47540e9b78b8f15dabacdf7114f (diff)
GPU Calc: revert back to OpenCL fmin and fmax
When generating code for MIN and MAX an integer version (min/max) isn't correct. Change-Id: I4bf1e774e37e0ce30924178f022156e0e43f4c06
-rw-r--r--sc/source/core/opencl/formulagroupcl.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sc/source/core/opencl/formulagroupcl.cxx b/sc/source/core/opencl/formulagroupcl.cxx
index 6c27cd15c6af..35484806b767 100644
--- a/sc/source/core/opencl/formulagroupcl.cxx
+++ b/sc/source/core/opencl/formulagroupcl.cxx
@@ -775,7 +775,7 @@ public:
virtual std::string GetBottom(void) { return "MAXFLOAT"; }
virtual std::string Gen2(const std::string &lhs, const std::string &rhs) const
{
- return "min("+lhs + "," + rhs +")";
+ return "fmin("+lhs + "," + rhs +")";
}
virtual std::string BinFuncName(void) const { return "min"; }
};
@@ -785,7 +785,7 @@ public:
virtual std::string GetBottom(void) { return "-MAXFLOAT"; }
virtual std::string Gen2(const std::string &lhs, const std::string &rhs) const
{
- return "max("+lhs + "," + rhs +")";
+ return "fmax("+lhs + "," + rhs +")";
}
virtual std::string BinFuncName(void) const { return "max"; }
};