[all-commits] [llvm/llvm-project] 8da8ff: [flang][RISCV] Add target-abi ModuleFlag. (#126188)
Craig Topper via All-commits
all-commits at lists.llvm.org
Thu Feb 13 08:08:32 PST 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 8da8ff8768bc0115f21d7d8fe8d47872190f8de1
https://github.com/llvm/llvm-project/commit/8da8ff8768bc0115f21d7d8fe8d47872190f8de1
Author: Craig Topper <craig.topper at sifive.com>
Date: 2025-02-13 (Thu, 13 Feb 2025)
Changed paths:
M clang/lib/Driver/ToolChains/Flang.cpp
M flang/include/flang/Frontend/TargetOptions.h
M flang/lib/Frontend/CompilerInvocation.cpp
M flang/lib/Frontend/FrontendActions.cpp
A flang/test/Driver/mabi-riscv.f90
A flang/test/Lower/RISCV/riscv-target-abi.f90
Log Message:
-----------
[flang][RISCV] Add target-abi ModuleFlag. (#126188)
This is needed to generate proper ABI flags in the ELF header for LTO
builds. If these flags aren't set correctly, we can't link with objects
that were built with the correct flags.
For non-LTO builds the mcpu/mattr in the TargetMachine will cause the
backend to infer an ABI. For LTO builds the mcpu/mattr aren't set.
I've only added lp64, lp64f, and lp64d ABIs. ilp32* requires riscv32
which is not yet supported in flang. lp64e requires a different
DataLayout string and would need additional plumbing.
Fixes #115679
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list