[flang-commits] [flang] e183612 - [flang] Get ppc64le build bot back up

Peter Klausler via flang-commits flang-commits at lists.llvm.org
Tue Apr 26 09:40:12 PDT 2022


Author: Peter Klausler
Date: 2022-04-26T09:40:03-07:00
New Revision: e1836123a7ecb57dcb9a4630c6960478df829fc5

URL: https://github.com/llvm/llvm-project/commit/e1836123a7ecb57dcb9a4630c6960478df829fc5
DIFF: https://github.com/llvm/llvm-project/commit/e1836123a7ecb57dcb9a4630c6960478df829fc5.diff

LOG: [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

Added: 
    

Modified: 
    flang/lib/Evaluate/intrinsics-library.cpp

Removed: 
    


################################################################################
diff  --git a/flang/lib/Evaluate/intrinsics-library.cpp b/flang/lib/Evaluate/intrinsics-library.cpp
index ba3b95f3e97af..2f56dcc9eedf5 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


        


More information about the flang-commits mailing list