[Flang-RT] Make implicit PPC intrinsic uses explicit (#206493)

The PPC-specific builtin moduls have implicit dependencies insert by
flang. For CMake to correctly setup the build order, they must be made
explicit.

This replicates the implicit module uses from

12b20b3673/flang/lib/Semantics/semantics.cpp (L680-L693)
in the modules themselves. The PPC-specific modules compiled by Flang-RT
are listed here:

12b20b3673/flang-rt/lib/runtime/CMakeLists.txt (L213-L219)

This should fix the intermittend build error mentioned in
https://github.com/llvm/llvm-project/pull/205634#issuecomment-4829653483.
Unfortunately I do not have a PowerPC (cross-)compilation build
environment ready to test, nor does the Premerge-CI build it.
This commit is contained in:
Michael Kruse 2026-06-29 20:09:16 +02:00 committed by GitHub
parent a8918b6bf3
commit c4bb83ea5b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 4 additions and 0 deletions

View file

@ -7,6 +7,7 @@
!===------------------------------------------------------------------------===!
module __ppc_intrinsics
use __ppc_types ! implicit dependencies, made explicit for CMake
private

View file

@ -7,6 +7,7 @@
!===------------------------------------------------------------------------===!
module __ppc_types
use __fortran_builtins ! implicit dependency, made explicit for CMake
implicit none
! Set PRIVATE by default to explicitly only export what is meant

View file

@ -7,6 +7,8 @@
!===------------------------------------------------------------------------===!
module mma
use __ppc_types ! implicit dependencies, made explicit for CMake
implicit none
private