aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Klausler <pklausler@nvidia.com>2022-04-25 17:36:05 -0700
committerPeter Klausler <pklausler@nvidia.com>2022-04-26 09:40:03 -0700
commite1836123a7ecb57dcb9a4630c6960478df829fc5 (patch)
tree8e71e3b75d7e50bcb53ec302528331bb5ea77958
parent6c1a0d5205f6a2a01d6ff3e4213d24a2cff29875 (diff)
downloadllvm-e1836123a7ecb57dcb9a4630c6960478df829fc5.zip
llvm-e1836123a7ecb57dcb9a4630c6960478df829fc5.tar.gz
llvm-e1836123a7ecb57dcb9a4630c6960478df829fc5.tar.bz2
[flang] Get ppc64le build bot back up
A recent change assumed that the native C++ "long double" maps to a Fortran data type; but this turns out to not be true for ppc64le, which uses "double-double" for "long double". This is a quick patch to get the ppc64le flang build bot back up. A better fix that either uses HostTypeExists<> or replaces "long double" with "ieee128_t" (or some other solution) is expected to follow soon. Differential Revision: https://reviews.llvm.org/D124423
-rw-r--r--flang/lib/Evaluate/intrinsics-library.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/flang/lib/Evaluate/intrinsics-library.cpp b/flang/lib/Evaluate/intrinsics-library.cpp
index ba3b95f..2f56dcc 100644
--- a/flang/lib/Evaluate/intrinsics-library.cpp
+++ b/flang/lib/Evaluate/intrinsics-library.cpp
@@ -325,6 +325,8 @@ template <> struct HostRuntimeLibrary<double, LibraryVersion::LibmExtensions> {
static_assert(map.Verify(), "map must be sorted");
};
+#if !defined(__PPC__) || defined(__LONG_DOUBLE_IEEE128__)
+// TODO: use HostTypeExists instead?
template <>
struct HostRuntimeLibrary<long double, LibraryVersion::LibmExtensions> {
using F = FuncPointer<long double, long double>;
@@ -340,6 +342,7 @@ struct HostRuntimeLibrary<long double, LibraryVersion::LibmExtensions> {
static constexpr HostRuntimeMap map{table};
static_assert(map.Verify(), "map must be sorted");
};
+#endif // !defined(__PPC__) || defined(__LONG_DOUBLE_IEEE128__)
#endif
/// Define pgmath description