Skip to content

infra: use LLD for all configurations #13203

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

kasper93
Copy link
Contributor

@kasper93 kasper93 commented Apr 9, 2025

This makes it consistent to use LLD across all configurations. It also moves away from using gold linker, which has recently been deprecated.

On top of that LLD is faster and has better compatibility with LLVM toolchain that is already used for building.

This commit also fixes warnings that can sometimes occur with BFD linker that doesn't fully support DWARF 5, at least the version on the builder: DWARF: invalid or unhandled FORM value: 0x22

Some projects already replaced linker in thier build scripts for this reason.

Copy link

github-actions bot commented Apr 9, 2025

kasper93 has previously contributed to projects/ffmpeg. The previous PR was #13175
kasper93 is either the primary contact or is in the CCs list of projects/mpv.
kasper93 has previously contributed to projects/mpv. The previous PR was #13158
kasper93 is a new contributor to projects/dbus-broker. The PR must be approved by known contributors before it can be merged. The past contributors are: DonggeLiu, evverx
kasper93 is a new contributor to projects/ntp. The PR must be approved by known contributors before it can be merged. The past contributors are: joycebrum, devtty1er, Dor1s, catenacyber (unverified)
kasper93 is a new contributor to projects/halide. The PR must be approved by known contributors before it can be merged. The past contributors are: nathaniel-brough
kasper93 is a new contributor to projects/tdengine. The PR must be approved by known contributors before it can be merged. The past contributors are: DonggeLiu, sangshuduo
kasper93 is a new contributor to projects/ecc-diff-fuzzer. The PR must be approved by known contributors before it can be merged. The past contributors are: catenacyber, gilles-peskine-arm, guidovranken, daverodgman, devtty1er, inferno-chromium, Dor1s
kasper93 is a new contributor to projects/libiec61850. The PR must be approved by known contributors before it can be merged. The past contributors are: DonggeLiu
kasper93 is a new contributor to projects/llhttp. The PR must be approved by known contributors before it can be merged. The past contributors are: DaveLak, DonggeLiu
kasper93 is a new contributor to projects/thrift. The PR must be approved by known contributors before it can be merged. The past contributors are: fishy, catenacyber
kasper93 is a new contributor to projects/connectedhomeip. The PR must be approved by known contributors before it can be merged. The past contributors are: Alami-Amine, andy31415, abcSup

@jonathanmetzman
Copy link
Contributor

/gcbrun trial_build.py all --sanitizer address --fuzzing-engine libfuzzer

This makes it consistent to use LLD across all configurations. It also
moves away from using gold linker, which has recently been deprecated.

On top of that LLD is faster and has better compatibility with LLVM
toolchain that is already used for building.

This commit also fixes warnings that can sometimes occur with BFD
linker that doesn't fully support DWARF 5, at least the version on the
builder: DWARF: invalid or unhandled FORM value: 0x22

Some projects already replaced linker in their build scripts for this
reason.
@kasper93
Copy link
Contributor Author

/gcbrun trial_build.py all --sanitizer address --fuzzing-engine libfuzzer

Added missing -Wno-unused-command-line-argument, should fix most failures.

@jonathanmetzman
Copy link
Contributor

Are we using lld by default? I'm not sure we are, but I haven't looked.

@kasper93
Copy link
Contributor Author

Are we using lld by default? I'm not sure we are, but I haven't looked.

The proposal is to use LLD by default. I've outlined the main reason in commit message. Currently BFD linker is used, with some jobs using GOLD. Idea is to unify and modernize to use LLD.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants