This is an archive of the discontinued LLVM Phabricator instance.

[ELF][MIPS] Ignore incorrect version definition index for _gp_disp symbol
ClosedPublic

Authored by atanasyan on Jan 24 2018, 8:38 AM.

Details

Summary

MIPS BFD linker puts _gp_disp symbol into DSO files and assigns zero version definition index to it. This value means 'unversioned local symbol' while _gp_disp is a section global symbol. We have to handle this bug in the LLD because BFD linker is used for building MIPS toolchain libraries.

Diff Detail

Repository
rL LLVM

Event Timeline

atanasyan created this revision.Jan 24 2018, 8:38 AM
grimar added a subscriber: grimar.Jan 24 2018, 11:02 PM
grimar added inline comments.
ELF/InputFiles.cpp
860 ↗(On Diff #131276)

I suggest to add "FIXME: " at the begining of comment,
saying that this hack can be removed once fixed in BFD and settle for a while.
It's consistent with other hacks/workarounds we have in code.

atanasyan updated this revision to Diff 131402.Jan 25 2018, 2:12 AM
  • Added FIXME tag to the comment

Ping?

Here is the bug report and the corresponding patch for GNU BFD: https://sourceware.org/ml/binutils/2018-01/msg00390.html

This revision was not accepted when it landed; it landed in state Needs Review.Feb 7 2018, 2:05 AM
This revision was automatically updated to reflect the committed changes.