[clang] [flang] [Flang] Add -ffast-real-mod and direct code for MOD on REAL types (PR #160660)

Tom Eccles via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 29 06:48:17 PDT 2025


================
@@ -0,0 +1,75 @@
+! RUN: %flang_fc1 -ffast-real-mod -emit-mlir -o - %s | FileCheck %s --check-prefixes=CHECK%if target=x86_64{{.*}} %{,CHECK-KIND10%}%if flang-supports-f128-math %{,CHECK-KIND16%}
----------------
tblah wrote:

That test is using lines like
```
integer, parameter :: kind16 = merge(16, 4, selected_real_kind(p=33).eq.16)
real(kind16) :: r, a, p
```

This make sure that on systems that don't support real(16) it will instead use real(4).

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


More information about the cfe-commits mailing list