[flang-commits] [clang] [flang] [llvm] [openmp] [Flang] Move builtin .mod generation into runtimes (PR #137828)

Michael Kruse via flang-commits flang-commits at lists.llvm.org
Tue Nov 25 04:16:23 PST 2025


Meinersbur wrote:

@hakostra Modules for other targets must be build explicitly, e.g. `-DLLVM_RUNTIME_TARGETS=default;nvptx64-nvidia-cuda`.

Without this PR, modules files are shared between all targets, i.e. both are using the same module files. For instance x86_64 has a [`real(10)`](https://github.com/llvm/llvm-project/blob/d748c81218bee39dafb9cc0c00ed7831a3ed44c3/flang-rt/lib/runtime/__fortran_ieee_exceptions.f90#L53) type, but there is no equivalent on nvptx. Some [constants](https://github.com/llvm/llvm-project/blob/d748c81218bee39dafb9cc0c00ed7831a3ed44c3/flang-rt/lib/runtime/iso_c_binding.f90#L77-L81) also have different values on different targets.

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


More information about the flang-commits mailing list