This is an archive of the discontinued LLVM Phabricator instance.

[lld][WebAssembly] Fix for weak references to data symbols in archives
ClosedPublic

Authored by sbc100 on Oct 16 2019, 4:07 PM.

Details

Summary

Fix a bug where were not handling relocations against weakly undefined
data symbol. Add a test for this case. Also ensure that the weak
references to data symbols are not pulled in from archive files by
default (but are if -u <name> is added to the command line).

Fixes: PR43696

Event Timeline

sbc100 created this revision.Oct 16 2019, 4:07 PM
Herald added a project: Restricted Project. · View Herald TranscriptOct 16 2019, 4:07 PM
sbc100 updated this revision to Diff 225337.Oct 16 2019, 6:13 PM
  • comment
sbc100 added a reviewer: ruiu.Oct 16 2019, 6:13 PM
sbc100 added a reviewer: sunfish.
MaskRay added inline comments.
lld/test/wasm/archive-weak-undefined.ll
15–16

Add a comment saying an undefined weak will not fetch archive members

ruiu accepted this revision.Oct 16 2019, 8:02 PM

LGTM

This revision is now accepted and ready to land.Oct 16 2019, 8:02 PM
sbc100 updated this revision to Diff 225343.Oct 16 2019, 8:17 PM
  • comment
This revision was automatically updated to reflect the committed changes.