[flang-commits] [flang] [Flang] remove assert using femode_t from AIX (PR #74500)
via flang-commits
flang-commits at lists.llvm.org
Tue Dec 5 09:30:14 PST 2023
https://github.com/madanial0 created https://github.com/llvm/llvm-project/pull/74500
AIX does not have `femode_t` in `<cfenv>` header, removing the assert to fix build failures
>From f228e531429827f91a5107844ff7538d7510f498 Mon Sep 17 00:00:00 2001
From: Mark Danial <madanial at dixon.rtp.raleigh.ibm.com>
Date: Tue, 5 Dec 2023 12:27:46 -0500
Subject: [PATCH] [Flang] remove assert using femode_t from AIX
---
flang/runtime/exceptions.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/flang/runtime/exceptions.cpp b/flang/runtime/exceptions.cpp
index 797d0c87e601d..91084f230baa3 100644
--- a/flang/runtime/exceptions.cpp
+++ b/flang/runtime/exceptions.cpp
@@ -78,7 +78,7 @@ std::int32_t RTNAME(MapException)(int32_t except) {
// Verify that the size of ieee_modes_type and ieee_status_type objects from
// intrinsic module file __fortran_ieee_exceptions.f90 are large enough to
// hold femode_t and fenv_t objects, respectively.
-#ifndef _WIN32
+#if !defined(_WIN32) && !defined(_AIX)
static_assert(
sizeof(femode_t) <= sizeof(int) * _FORTRAN_RUNTIME_IEEE_FEMODE_T_EXTENT,
"increase ieee_modes_type size");
More information about the flang-commits
mailing list