https://sourceware.org/bugzilla/show_bug.cgi?id=21532
Jiong Wang <jiwang at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at sourceware dot org |jiwang at gcc dot
gnu.org
--- Comment #4 from Jiong Wang <jiwang at gcc dot gnu.org> ---
(In reply to Nick Clifton from comment #3)
> Hi Jiong,
>
> Thanks for taking a look at this.
>
> > Looks like AArch64 could avoid emiting COPY relocation if it's a
> > relocation
> > against writable section. We could adopt similar code from
> > elf_x86_64_adjust_dynamic_symbol or ppc64_elf_adjust_dynamic_symbol.
>
> Ah - maybe not. The original testcase (in the BZ) shows the bug happening
> when
> constant data is used rather than writeable data. You can also extend the
> second
> testcase I posted to use constant data and the same problem happens.
>
>
> >> It looks like the linker creates a copy of IEEEsingle in the executable but
> >> then the GOT entry for IEEEsingle is not updated in libLLVM.so, causing any
> >> accesses to IEEEsingle in libLLVM.so to refer to the original definition
> >
> > Does this means this is a glibc bug as well? dynamic linker needs to
> > redirect
> > the reference in the .so to the copy as well?
>
> This is a possibility, although I am not an expert on the dynamic linker. I
> think
> however that we need to verify that the static linker is producing the
> correct
> dynamic relocations first.
Thanks, I will prepare a patch to fix the BFD static linker.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
bug-binutils mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-binutils