summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/netlist/plib/pfmtlog.h
diff options
context:
space:
mode:
author couriersud <couriersud@gmx.org>2019-11-03 15:08:41 +0100
committer couriersud <couriersud@gmx.org>2019-11-03 15:25:01 +0100
commit34ccb11c536056deeb8ec3b2c36aeb064f70f844 (patch)
tree6ab710fb000703517636b78d1024809994d5e224 /src/lib/netlist/plib/pfmtlog.h
parent36c17abc7993de82454ac45d7193ae6e6f2f9455 (diff)
netlist: Completed __float128 support. [Couriersud]
Both compiling the core and the shaders with __float128 now work. The support was added to be ready to deal with academic edge cases. Performance drops to 10% of double - thus disabled by default.
Diffstat (limited to 'src/lib/netlist/plib/pfmtlog.h')
-rw-r--r--src/lib/netlist/plib/pfmtlog.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lib/netlist/plib/pfmtlog.h b/src/lib/netlist/plib/pfmtlog.h
index fd1f073cb73..df0463cbb61 100644
--- a/src/lib/netlist/plib/pfmtlog.h
+++ b/src/lib/netlist/plib/pfmtlog.h
@@ -192,6 +192,11 @@ public:
typename std::enable_if<std::is_floating_point<T>::value, pfmt &>::type
e(const T &x) {return format_element('e', x); }
+#if PUSE_FLOAT128
+ // FIXME: not what we want
+ pfmt & e(const __float128 &x) {return format_element('e', static_cast<long double>(x)); }
+#endif
+
template <typename T>
typename std::enable_if<std::is_floating_point<T>::value, pfmt &>::type
g(const T &x) {return format_element('g', x); }