# Flang

**URL:** https://fortran-lang.discourse.group/c/compilers/flang/31.md

[Latest](https://fortran-lang.discourse.group/latest.md) · [Categories](https://fortran-lang.discourse.group/categories.md)

---

## [About the Flang category](https://fortran-lang.discourse.group/t/about-the-flang-category/9363)

<div class="topic-metadata">

**Author:** [@certik](https://fortran-lang.discourse.group/u/certik)\
**Replies:** 0

</div>

---

## [A piece of code that causes LLVM Flang to generate NaN/Inf randomly](https://fortran-lang.discourse.group/t/a-piece-of-code-that-causes-llvm-flang-to-generate-nan-inf-randomly/10713)

<div class="topic-metadata">

**Author:** [@zaikunzhang](https://fortran-lang.discourse.group/u/zaikunzhang)\
**Replies:** 32\
**Last updated:** [February 24, 2026, 4:30am UTC](https://fortran-lang.discourse.group/t/a-piece-of-code-that-causes-llvm-flang-to-generate-nan-inf-randomly/10713 "2026-02-24T04:30:00Z")

</div>

See N.B.: I am well aware that -ffast-math can cause un-mathematical results. Whatever the results might be, they should be deterministic. The behavior of the code is indeed quite complex — more complex than it …

---

## [Old but active programmer's experience with LLVM Flang](https://fortran-lang.discourse.group/t/old-but-active-programmers-experience-with-llvm-flang/10415)

<div class="topic-metadata">

**Author:** [@layzarc](https://fortran-lang.discourse.group/u/layzarc)\
**Replies:** 2\
**Last updated:** [October 10, 2025, 12:40pm UTC](https://fortran-lang.discourse.group/t/old-but-active-programmers-experience-with-llvm-flang/10415 "2025-10-10T12:40:48Z")

</div>

My over 20-year old 55000 statement optical engineering application has been ported to dozens of compilers and/or OSs. My current personal setup is an M2 Ultra Mac and I use MacPorts to build both Gfortran and Flang on i…

---

## [First official release of Flang!](https://fortran-lang.discourse.group/t/first-official-release-of-flang/9333)

<div class="topic-metadata">

**Author:** [@mleair](https://fortran-lang.discourse.group/u/mleair)\
**Replies:** 42\
**Last updated:** [September 6, 2025, 3:14pm UTC](https://fortran-lang.discourse.group/t/first-official-release-of-flang/9333 "2025-09-06T15:14:26Z")

</div>

Announcing the first official release of Flang! Congratulations to everyone who has contributed to this LLVM Fortran project, which began in late 2020. The blog post below provides a historical recap of the project. A…

---

## [Flang-new: How to force arrays to be allocated on the heap? (a possible bug)](https://fortran-lang.discourse.group/t/flang-new-how-to-force-arrays-to-be-allocated-on-the-heap-a-possible-bug/7824)

<div class="topic-metadata">

**Author:** [@zaikunzhang](https://fortran-lang.discourse.group/u/zaikunzhang)\
**Replies:** 1\
**Last updated:** [March 30, 2025, 2:00am UTC](https://fortran-lang.discourse.group/t/flang-new-how-to-force-arrays-to-be-allocated-on-the-heap-a-possible-bug/7824 "2025-03-30T02:00:21Z")

</div>

According to information on GitHub, flang -mmlir -fdynamic-heap-array should force dynamic arrays to be allocated on the heap and hence avoid stackoverflows when large dynamic arrays are present. The example mentioned o…

---

## [Flang-20 Not compiling with FPM for an OpenMP program](https://fortran-lang.discourse.group/t/flang-20-not-compiling-with-fpm-for-an-openmp-program/9348)

<div class="topic-metadata">

**Author:** [@apoorv01](https://fortran-lang.discourse.group/u/apoorv01)\
**Replies:** 6\
**Last updated:** [March 26, 2025, 1:22am UTC](https://fortran-lang.discourse.group/t/flang-20-not-compiling-with-fpm-for-an-openmp-program/9348 "2025-03-26T01:22:28Z")

</div>

Hi Flang Team, I am trying the new flang-20 compiler for a program using FPM with Openmp. The program compiled in flang-new (flang-18). I am using following command fpm build --flag -O3 --flag -fstack-arrays --flag -fo…

---

## [Flang-new 19.0: "warning: overflow on power with INTEGER exponent"](https://fortran-lang.discourse.group/t/flang-new-19-0-warning-overflow-on-power-with-integer-exponent/7801)

<div class="topic-metadata">

**Author:** [@zaikunzhang](https://fortran-lang.discourse.group/u/zaikunzhang)\
**Replies:** 2\
**Last updated:** [April 9, 2024, 11:14pm UTC](https://fortran-lang.discourse.group/t/flang-new-19-0-warning-overflow-on-power-with-integer-exponent/7801 "2024-04-09T23:14:05Z")

</div>

I am using flang-new 19.0. With the following Fortran code ! test\_overflow.f90 program test\_overflow implicit none print \*, range(0.0) print \*, 10.0\*\*(-32.0) print \*, 10.0\*\*(-32) end program test\_overflow …
