This is an archive of the discontinued LLVM Phabricator instance.

[ELF] Explain some options in ld.lld.1
ClosedPublic

Authored by MaskRay on Feb 26 2019, 5:43 AM.

Event Timeline

MaskRay created this revision.Feb 26 2019, 5:43 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 26 2019, 5:43 AM
MaskRay updated this revision to Diff 188354.Feb 26 2019, 5:47 AM

Update date .Dd

MaskRay updated this revision to Diff 188355.Feb 26 2019, 5:50 AM

Change a .Ar to .Fl

ruiu added a comment.Feb 26 2019, 11:07 AM

Thank you for doing this.

docs/ld.lld.1
221

options -> option

222–224

I'd think this is hard to understand for those who are just reading this manual page. We don't explain anything about .llvm_addrsig for example.

Maybe it's better to explain it at a high level first? For example: C/C++ requires each data has a unique address. This option allows lld do unsafe optimization that breaks the requirement. If this option is given, lld may create copies of read-only data or merge two or more read-only data that happen to have the same value.

MaskRay updated this revision to Diff 188484.Feb 26 2019, 5:14 PM

Apply ruiu's suggestion

Does this look good now?

ruiu accepted this revision.Feb 28 2019, 7:41 PM

LGTM

This revision is now accepted and ready to land.Feb 28 2019, 7:41 PM
This revision was automatically updated to reflect the committed changes.