This is an archive of the discontinued LLVM Phabricator instance.

lld-link: Allow backward references between associated comdats
ClosedPublic

Authored by thakis on Jan 29 2019, 7:38 AM.

Details

Summary

References between associated comdats are invalid per COFF spec, but the newest Windows SDK contains obj files that have these references (https://bugs.chromium.org/p/chromium/issues/detail?id=925943#c13). So add back support for them and add tests for them. The old code handled them fine.

This makes lld-link match the behavior of newer link.exe versions as far as I can tell. (The behavior before this change matched the behavior of older link.exe versions.)

This mostly reverts r352254.

Diff Detail

Repository
rLLD LLVM Linker

Event Timeline

thakis created this revision.Jan 29 2019, 7:38 AM
hans accepted this revision.Jan 29 2019, 7:43 AM

lgtm

Maybe mention link.exe's behaviour in the commit message too?

This revision is now accepted and ready to land.Jan 29 2019, 7:43 AM
thakis edited the summary of this revision. (Show Details)Jan 29 2019, 7:49 AM
This revision was automatically updated to reflect the committed changes.