This is an archive of the discontinued LLVM Phabricator instance.

ELF: Fix ICF crash on absolute symbol relocations.
ClosedPublic

Authored by pcc on Jan 19 2017, 7:57 PM.

Details

Summary

If two sections contained relocations to absolute symbols with the same
value we would crash when trying to access their sections. Add a check that
both symbols point to sections before accessing their sections, and treat
absolute symbols as equal if their values are equal.

Event Timeline

pcc created this revision.Jan 19 2017, 7:57 PM
ruiu accepted this revision.Jan 19 2017, 8:00 PM

LGTM

This revision is now accepted and ready to land.Jan 19 2017, 8:00 PM
This revision was automatically updated to reflect the committed changes.