Closed Bug 1473436 Opened 6 years ago Closed 6 years ago

Default to lld for local *nix builds when it can be found

Categories

(Firefox Build System :: General, enhancement)

enhancement
Not set
normal

Tracking

(firefox63 fixed)

RESOLVED FIXED
mozilla63
Tracking Status
firefox63 --- fixed

People

(Reporter: glandium, Assigned: glandium)

References

(Blocks 1 open bug)

Details

Attachments

(2 files)

      No description provided.
Blocks: 1469088
I'm all for this change, but just for the sake of documenting: is there a specific motivation for it?
lld is much faster than the default linkers! Like typically 2--3x faster.
(In reply to David Major [:dmajor] from comment #3)
> I'm all for this change, but just for the sake of documenting: is there a
> specific motivation for it?

Same reason we're currently picking gold on local builds if you have it: it's faster than ld.bfd. And lld is even faster than gold.
Ok, great. Just wanted to make sure there wasn't a specific bug or functionality reason. Someone may be curious in a few years' time.
Great news, thanks!
Attachment #8989891 - Flags: review?(core-build-config-reviews) → review?(cmanchester)
Attachment #8989892 - Flags: review?(core-build-config-reviews) → review?(cmanchester)
Comment on attachment 8989891 [details]
Bug 1473436 - Disable elfhack on local builds.

https://reviewboard.mozilla.org/r/254882/#review262030
Attachment #8989891 - Flags: review?(cmanchester) → review+
Comment on attachment 8989892 [details]
Bug 1473436 - Default to lld for local *nix builds when it is available.

https://reviewboard.mozilla.org/r/254884/#review262032
Attachment #8989892 - Flags: review?(cmanchester) → review+
Pushed by mh@glandium.org:
https://hg.mozilla.org/integration/autoland/rev/bf4739550b9d
Disable elfhack on local builds. r=chmanchester
https://hg.mozilla.org/integration/autoland/rev/dbeb248015cc
Default to lld for local *nix builds when it is available. r=chmanchester
https://hg.mozilla.org/mozilla-central/rev/bf4739550b9d
https://hg.mozilla.org/mozilla-central/rev/dbeb248015cc
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
LLD is kinda buggy before LLVM 6.0. Fails to build Firefox on FreeBSD 11.1 (has LLD 4.0) due to missing readdir_r@FBSD_1.0 (pre-ino64 symbol used by libc crate) and --warn-unresolved symbols. It can be fixed by bumping minimum Clang version but FreeBSD 11.1 will reach EOL by 2018-09-30, way before Firefox 63.
You can probably just still use gold or bfd until then, right?
FreeBSD i386 (aka x86) doesn't support gold. Both bfd[1] and lld from packages (binutils and llvm60) work fine, just not those shipped with base system. A minor inconvenience as downstream doesn't have Nightly package.

[1] GNU ld 2.17.50 (bfd) from base is no good, see
    https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=222641
You need to log in before you can comment on or make changes to this bug.