[flang-commits] [flang] DRAFT: [flang] Warn when F128 is unsupported (PR #102147)

Peter Klausler via flang-commits flang-commits at lists.llvm.org
Tue Aug 6 08:58:25 PDT 2024


================
@@ -21,9 +22,29 @@ namespace Fortran::tools {
 
   const llvm::Triple &targetTriple{targetMachine.getTargetTriple()};
   // FIXME: Handle real(3) ?
-  if (targetTriple.getArch() != llvm::Triple::ArchType::x86_64)
+  if (targetTriple.getArch() != llvm::Triple::ArchType::x86_64) {
     targetCharacteristics.DisableType(
         Fortran::common::TypeCategory::Real, /*kind=*/10);
+  }
+
+  // Figure out if we can support F128: see
+  // flang/runtime/Float128Math/math-entries.h
+  // clang-format off
+#ifdef FLANG_RUNTIME_F128_MATH_LIB
+  // we can use libquadmath wrappers
+  constexpr bool f128Support = true;
+#else
----------------
klausler wrote:

`#elif`

https://github.com/llvm/llvm-project/pull/102147


More information about the flang-commits mailing list