llvm / llvm/llvm-project

Track compiler features that fail under LTO

Open
#179,532 4 comments 1 reaction 0 assignees View on GitHub
LTO metaissue
Dominant language
LLVM
Stars
40.5k
Forks
18.7k
PR merge metrics
PR metrics pending

Description

We have had a swath of issues getting things to work precisely as they should for LTO builds. Often the solution is to plumb additional flags to the linker, but in many cases we have workarounds in-tree.

This issue is an attempt to track these places in tree as well as the general issue of LTO compatibility.

The following issues are known incompatibilities:
- #168469
- #61991
- #69780
- #67698
- #65090
- #57864

Additionally, target-features often need to be propagated to the LTO pipeline, or the compiler may fail to select the correct features for things like module level ASM, or inline asm blocks. This is generally not an issue, but is extremely prevalent on RISCV (as evidenced by the partial listing above). Additionally, any code generation configuration that does not get expressed in the IR may not be set correctly in LTO builds, and as such a typical work around is to have the Frontend specify additional flags to the linker. This si problematic, since the code generation options typically only get added in clang, but are required for any frontend.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.