Page MenuHomePhabricator
Feed Advanced Search

Jul 27 2020

MaskRay requested changes to D58102: Support X86 Control-flow Enforcement Technology (CET) in LLD.

Implemented. Can be closed now..

Jul 27 2020, 11:45 PM · Restricted Project, lld
grimar added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Thanks for the patch. I've committed as https://github.com/llvm/llvm-project/commit/fa1145a8d2f1bd00a60d0ed4572901d2b1403157.

Jul 27 2020, 2:17 AM · Restricted Project, lld
grimar closed D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.
Jul 27 2020, 2:17 AM · Restricted Project, lld

Jul 26 2020

irichter added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Looks great!

Jul 26 2020, 9:54 PM · Restricted Project, lld
MaskRay accepted D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Looks great!

Jul 26 2020, 8:43 PM · Restricted Project, lld
irichter updated the diff for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.
  • Append "." to LOG2CEIL comment
  • Use UINT64_C rather than static_cast<uint64_t>
  • Remove tests for 2^16 and 2^16+1
Jul 26 2020, 5:29 PM · Restricted Project, lld
MaskRay added inline comments to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.
Jul 26 2020, 12:26 PM · Restricted Project, lld
irichter updated the diff for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Now using llvm::Log2_64_Ceil; also, tests are somewhat less arbitrary (middle values are now near 2^16 and 2^32, maximum is tested at UINT64_MAX.)

Jul 26 2020, 10:25 AM · Restricted Project, lld

Jul 25 2020

grimar added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Use llvm::Log2_64_Ceil (llvm/Support/mathExtras.h)

Is it preferred coding style to include the namespace in a function call, when the file already has the relevant using namespace statement? Specifically, should I be using an unqualified return Log2_64_Ceil(...);, or a qualified return llvm::Log2_64_Ceil(...); call?

Jul 25 2020, 1:23 AM · Restricted Project, lld
grimar added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

I do not think we should focus too much on this in LLD test. I think just a few values should be fine. E.g 0, 1, 2, 3, 4, 65535, 65536, uint64(-1)
@MaskRay, what do you think?

I see that you suggest testing the upper bounds for 16-bits (UINT16_MAX and UINT16_MAX+1, both which should return 16). Is there any particular reason for checking this at this boundary? Why not UINT32_MAX,UINT32_MAX+1 (either instead of UINT16_MAX, or in addition thereto)? Should I also be testing UINT16_MAX+2 (should return 17) and/or UINT32_MAX+2 (should return 33)?

Jul 25 2020, 1:20 AM · Restricted Project, lld

Jul 24 2020

irichter added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

I do not think we should focus too much on this in LLD test. I think just a few values should be fine. E.g 0, 1, 2, 3, 4, 65535, 65536, uint64(-1)
@MaskRay, what do you think?

Jul 24 2020, 12:07 PM · Restricted Project, lld
irichter added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Use llvm::Log2_64_Ceil (llvm/Support/mathExtras.h)

Jul 24 2020, 11:37 AM · Restricted Project, lld
compnerd added inline comments to D82252: MachO: support `-syslibroot`.
Jul 24 2020, 11:23 AM · Restricted Project, Restricted Project, lld
MaskRay added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

I could test every transition (e.g. 0x0f, 0x10, 0x1f, 0x20, 0x3f, 0x40, ...), but that'll be >100 tests. I took a quick look at the libc and libcxx tests for log2, but those seem much more detailed than I'd expect to find in lld.

What do you think would be sufficient?

I do not think we should focus too much on this in LLD test. I think just a few values should be fine. E.g 0, 1, 2, 3, 4, 65535, 65536, uint64(-1)
@MaskRay, what do you think?

Jul 24 2020, 8:14 AM · Restricted Project, lld
grimar added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

I could test every transition (e.g. 0x0f, 0x10, 0x1f, 0x20, 0x3f, 0x40, ...), but that'll be >100 tests. I took a quick look at the libc and libcxx tests for log2, but those seem much more detailed than I'd expect to find in lld.

What do you think would be sufficient?

Jul 24 2020, 1:24 AM · Restricted Project, lld

Jul 23 2020

MaskRay added inline comments to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.
Jul 23 2020, 1:17 PM · Restricted Project, lld
irichter set the repository for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function to rG LLVM Github Monorepo.
Jul 23 2020, 11:48 AM · Restricted Project, lld
irichter updated the diff for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Fix build issue on Windows (explicitly cast to uint64_t, don't rely on UL suffix to be equivalent)

Jul 23 2020, 11:05 AM · Restricted Project, lld
Harbormaster failed remote builds in B65393: Diff 280150 for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function!
Jul 23 2020, 9:27 AM · Restricted Project, lld
irichter added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Yeah, it should be fine to support it. Added a suggestion about test.

Jul 23 2020, 9:14 AM · Restricted Project, lld
irichter updated the diff for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Added comment to source noting that LOG2CEIL(0) returns 0.

Jul 23 2020, 8:55 AM · Restricted Project, lld
grimar added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Yeah, it should be fine to support it. Added a suggestion about test.
(Also, please do not upload patches without a context, see https://llvm.org/docs/Phabricator.html#requesting-a-review-via-the-web-interface)

Jul 23 2020, 1:28 AM · Restricted Project, lld

Jul 22 2020

MaskRay added inline comments to D83510: [LLD][COFF] Skip computation of the undefined symbols references that are not shown.
Jul 22 2020, 2:54 PM · Restricted Project, lld
MaskRay added a reviewer for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function: grimar.
Jul 22 2020, 11:53 AM · Restricted Project, lld
MaskRay added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

I assume you will use 1 << LOG2CEIL(address) to round up to a power of 2. It is indeed cumbersome to work around it. The function should be fine.

Jul 22 2020, 11:52 AM · Restricted Project, lld

Jul 20 2020

saudi closed D83510: [LLD][COFF] Skip computation of the undefined symbols references that are not shown.
Jul 20 2020, 9:17 PM · Restricted Project, lld
mstorsjo added a comment to D83510: [LLD][COFF] Skip computation of the undefined symbols references that are not shown.

LGTM (but maybe wait for a bit to see if someone else might have more opinions)

FWIW, I think this codepath exists in a fairly similar form in the ELF backend, that might benefit from a similar optimization.

I double-checked, the corresponding code in ELF computes the strings in the same loop where they are displayed, instead of the 2 passes done for COFF.
So, no optimization seems necessary in the case of ELF.

Jul 20 2020, 9:16 PM · Restricted Project, lld
saudi added a comment to D83510: [LLD][COFF] Skip computation of the undefined symbols references that are not shown.

LGTM (but maybe wait for a bit to see if someone else might have more opinions)

FWIW, I think this codepath exists in a fairly similar form in the ELF backend, that might benefit from a similar optimization.

Jul 20 2020, 9:16 PM · Restricted Project, lld
irichter added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

We don't arbitrarily add GNU ld linker script support. We add them on an as-needed basis if its functionality cannot easily replaced by other mechanism.

Jul 20 2020, 8:54 AM · Restricted Project, lld

Jul 19 2020

MaskRay added a comment to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

We don't arbitrarily add GNU ld linker script support. We add them on an as-needed basis if its functionality cannot easily replaced by other mechanism. For LOG2CEIL, it is difficult for me to think about its use cases. Can you elaborate?

Jul 19 2020, 9:30 PM · Restricted Project, lld
irichter updated the summary of D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.
Jul 19 2020, 12:59 PM · Restricted Project, lld
Herald added a reviewer for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function: MaskRay.
Jul 19 2020, 12:55 PM · Restricted Project, lld
irichter added a reviewer for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function: ruiu.
Jul 19 2020, 12:55 PM · Restricted Project, lld
irichter updated the diff for D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.

Fixed improper results for LOG2CEIL(0), updated tests to properly find the error

Jul 19 2020, 12:54 PM · Restricted Project, lld
irichter updated the summary of D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function.
Jul 19 2020, 12:51 PM · Restricted Project, lld

Jul 17 2020

Herald added a project to D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function: Restricted Project.
Jul 17 2020, 10:38 AM · Restricted Project, lld

Jul 14 2020

ikudrin closed D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.
Jul 14 2020, 2:36 AM · lld, Restricted Project

Jul 13 2020

MaskRay accepted D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.

LGTM.

Jul 13 2020, 8:40 AM · lld, Restricted Project
ikudrin added inline comments to D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.
Jul 13 2020, 1:27 AM · lld, Restricted Project
ikudrin updated the diff for D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.
  • Moved the test into init-fini.s.
Jul 13 2020, 1:26 AM · lld, Restricted Project

Jul 12 2020

aykevl closed D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 12 2020, 9:20 AM · Restricted Project, lld
MaskRay accepted D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 12 2020, 8:11 AM · Restricted Project, lld
MaskRay added a comment to D78741: [LLD][ELF][AVR] Implement the missing relocation types.

Thanks for the update. All look good to me now.

Jul 12 2020, 8:11 AM · Restricted Project, lld
Harbormaster failed remote builds in B63888: Diff 277282 for D78741: [LLD][ELF][AVR] Implement the missing relocation types!
Jul 12 2020, 3:46 AM · Restricted Project, lld
aykevl updated the diff for D78741: [LLD][ELF][AVR] Implement the missing relocation types.
  • added --print-imm-hex (so this patch depends on D83634)
  • deleted some redundant parentheses
  • changed all comment markers to ;
Jul 12 2020, 3:17 AM · Restricted Project, lld

Jul 11 2020

MaskRay added a comment to D78741: [LLD][ELF][AVR] Implement the missing relocation types.

Please check D83634. We can then enable --print-imm-hex

Jul 11 2020, 5:10 PM · Restricted Project, lld
aykevl updated the diff for D78741: [LLD][ELF][AVR] Implement the missing relocation types.

I think this addresses all review comments.

Jul 11 2020, 2:06 PM · Restricted Project, lld
aykevl added inline comments to D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 11 2020, 2:02 PM · Restricted Project, lld
MaskRay added inline comments to D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 11 2020, 1:46 PM · Restricted Project, lld
aykevl added inline comments to D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 11 2020, 1:07 PM · Restricted Project, lld
MaskRay added inline comments to D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 11 2020, 11:09 AM · Restricted Project, lld
aykevl updated the diff for D78741: [LLD][ELF][AVR] Implement the missing relocation types.
  • add relocation types in comments
Jul 11 2020, 10:04 AM · Restricted Project, lld
aykevl added inline comments to D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 11 2020, 9:56 AM · Restricted Project, lld

Jul 10 2020

MaskRay retitled D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members from [ELF] Do not force bringing out symbols passed by -init and -fini. to [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.
Jul 10 2020, 4:40 PM · lld, Restricted Project
MaskRay added inline comments to D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.
Jul 10 2020, 4:23 PM · lld, Restricted Project
MaskRay added a comment to D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.

OK, I think D69885 (lto/init-fini.ll) still makes sense. A bitcode symbol can behave like a regular symbol or an archive symbol.
For the -init case, a bitcode definition should behave more like a regular definition and -init can cause the definition to be emitted.

Jul 10 2020, 4:22 PM · lld, Restricted Project
aaronpuchert added a comment to D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.

@aaronpuchert Your comment https://bugzilla.opensuse.org/show_bug.cgi?id=1155108#c10 "However, it's actually a bug in all three linkers. It has been fixed in lld just today [1]" made me wonder whether https://bugs.llvm.org/show_bug.cgi?id=43927 was really a linker bug.

The linkers were behaving differently though: lld and bfd dropped the FINI entirely whereas gold had FINI=0, which lead to a crash. Which of these behaviors would be expected?

Jul 10 2020, 1:22 PM · lld, Restricted Project
mstorsjo added a comment to D83510: [LLD][COFF] Skip computation of the undefined symbols references that are not shown.

Still looks good with the additional test update (thanks for that!)

Jul 10 2020, 1:15 PM · Restricted Project, lld
MaskRay added inline comments to D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 10 2020, 10:49 AM · Restricted Project, lld
MaskRay added a reviewer for D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members: psmith.
Jul 10 2020, 10:27 AM · lld, Restricted Project
MaskRay updated subscribers of D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members.

I think this is about different expectation of _init and _fini behaviors.

Jul 10 2020, 10:26 AM · lld, Restricted Project
aykevl updated the diff for D78741: [LLD][ELF][AVR] Implement the missing relocation types.

Thanks for the review! This should address all comments.

Jul 10 2020, 8:50 AM · Restricted Project, lld
saudi updated the diff for D83510: [LLD][COFF] Skip computation of the undefined symbols references that are not shown.

Updated the test, adding an LTO obj file.

Jul 10 2020, 8:10 AM · Restricted Project, lld
Herald added a reviewer for D83549: [ELF] Do not leave undefined symbols (specified by -init and -fini) if they are defined in non-fetched archive members: espindola.
Jul 10 2020, 5:54 AM · lld, Restricted Project

Jul 9 2020

mstorsjo accepted D83510: [LLD][COFF] Skip computation of the undefined symbols references that are not shown.

LGTM (but maybe wait for a bit to see if someone else might have more opinions)

Jul 9 2020, 2:42 PM · Restricted Project, lld
saudi created D83510: [LLD][COFF] Skip computation of the undefined symbols references that are not shown.
Jul 9 2020, 2:30 PM · Restricted Project, lld
MaskRay added inline comments to D78741: [LLD][ELF][AVR] Implement the missing relocation types.
Jul 9 2020, 10:24 AM · Restricted Project, lld
gkm added a comment to D81413: [lld-macho] improve handling of -platform_version.

@compnerd, do you intend to complete & land this diff?

Jul 9 2020, 9:10 AM · Restricted Project, lld
aykevl added a comment to D78741: [LLD][ELF][AVR] Implement the missing relocation types.

ping?

Jul 9 2020, 5:41 AM · Restricted Project, lld
ikudrin closed D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 9 2020, 5:16 AM · debug-info, lld, Restricted Project
ikudrin closed D83049: [DebugInfo] Do not hang when parsing a malformed .debug_pub* section..
Jul 9 2020, 5:16 AM · debug-info, lld, Restricted Project
jhenderson accepted D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..

Latest update LGTM.

Jul 9 2020, 1:11 AM · debug-info, lld, Restricted Project

Jul 8 2020

dblaikie accepted D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..

Great, thanks!

Jul 8 2020, 11:36 AM · debug-info, lld, Restricted Project
ikudrin updated the diff for D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
  • Updated the wording for the reporting of premature termination.
Jul 8 2020, 8:55 AM · debug-info, lld, Restricted Project
jhenderson added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 8 2020, 12:09 AM · debug-info, lld, Restricted Project

Jul 7 2020

dblaikie added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 7 2020, 5:37 PM · debug-info, lld, Restricted Project
jhenderson accepted D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..

LGTM, I think, but please wait for @dblaikie.

Jul 7 2020, 6:01 AM · debug-info, lld, Restricted Project
ikudrin added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 7 2020, 5:58 AM · debug-info, lld, Restricted Project
ikudrin updated the diff for D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
  • Fixed typos (again). Thanks, @jhenderson!
  • Updated the test to shrink the number of tool runs.
Jul 7 2020, 5:57 AM · debug-info, lld, Restricted Project
ikudrin updated the diff for D83049: [DebugInfo] Do not hang when parsing a malformed .debug_pub* section..
  • Updated the test to check everything in one run.
Jul 7 2020, 5:54 AM · debug-info, lld, Restricted Project
jhenderson added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 7 2020, 2:21 AM · debug-info, lld, Restricted Project

Jul 6 2020

dblaikie added inline comments to D83049: [DebugInfo] Do not hang when parsing a malformed .debug_pub* section..
Jul 6 2020, 6:24 PM · debug-info, lld, Restricted Project
dblaikie added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 6 2020, 5:59 PM · debug-info, lld, Restricted Project
MaskRay closed D83184: Avoid using globals in ELF Symbol Table.
Jul 6 2020, 12:06 PM · Restricted Project, lld
wsmoses added a comment to D83184: Avoid using globals in ELF Symbol Table.

I can commit the for you if you don't have commit access. Please provide Name <email> so that you can get proper credit.

Jul 6 2020, 11:46 AM · Restricted Project, lld
MaskRay added a comment to D83184: Avoid using globals in ELF Symbol Table.

I can commit the for you if you don't have commit access. Please provide Name <email> so that you can get proper credit.

Jul 6 2020, 11:43 AM · Restricted Project, lld
ikudrin added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 6 2020, 7:37 AM · debug-info, lld, Restricted Project
ikudrin updated the diff for D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..

Thanks, @jhenderson!

  • Use Cursor in the loop from the beginning.
  • Fix typos.
  • Extended tests.
  • Removed the old test; Moved the checks to the new test file.
Jul 6 2020, 7:37 AM · debug-info, lld, Restricted Project
jhenderson added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 6 2020, 12:38 AM · debug-info, lld, Restricted Project

Jul 5 2020

jhenderson accepted D83049: [DebugInfo] Do not hang when parsing a malformed .debug_pub* section..

LGTM.

Jul 5 2020, 11:53 PM · debug-info, lld, Restricted Project
MaskRay accepted D83184: Avoid using globals in ELF Symbol Table.

Thanks! This may have a minor performance increase.

Jul 5 2020, 5:03 PM · Restricted Project, lld
Harbormaster failed remote builds in B62949: Diff 275581 for D83184: Avoid using globals in ELF Symbol Table!
Jul 5 2020, 4:32 PM · Restricted Project, lld
wsmoses created D83184: Avoid using globals in ELF Symbol Table.
Jul 5 2020, 4:00 PM · Restricted Project, lld
wsmoses updated the diff for D83184: Avoid using globals in ELF Symbol Table.
Jul 5 2020, 4:00 PM · Restricted Project, lld

Jul 3 2020

ikudrin added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 3 2020, 8:34 AM · debug-info, lld, Restricted Project
ikudrin updated the diff for D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 3 2020, 8:34 AM · debug-info, lld, Restricted Project
ikudrin updated the diff for D83049: [DebugInfo] Do not hang when parsing a malformed .debug_pub* section..
Jul 3 2020, 8:34 AM · debug-info, lld, Restricted Project
ikudrin added inline comments to D83049: [DebugInfo] Do not hang when parsing a malformed .debug_pub* section..
Jul 3 2020, 8:34 AM · debug-info, lld, Restricted Project
jhenderson added inline comments to D83050: [DebugInfo] Add more checks to parsing .debug_pub* sections..
Jul 3 2020, 1:03 AM · debug-info, lld, Restricted Project
jhenderson added inline comments to D83049: [DebugInfo] Do not hang when parsing a malformed .debug_pub* section..
Jul 3 2020, 12:29 AM · debug-info, lld, Restricted Project