This is the mail archive of the
mailing list for the binutils project.
Re: [RFC] PR ld/13621
On 01/31/2012 10:40 AM, Alan Modra wrote:
> The choice of .data isn't arbitrary, but based on section flags as
> well as adjacency. The idea being to hopefully put symbols in a
> section that belongs to the same segment (or overlay if such exists).
Well, it is, kinda.
Have a look at the minimal testcase in the patch. There, we also
eliminate .data as empty, and the symbol gets assigned to the .text
section. Different segment, very large "out of range" offset.
> Also, I dislike SHN_ABS symbols in executables and shared objects.
> They're supposed to be absolute, yet glibc ld.so dynamically relocates
> them, necessary for compatibility with ancient linkers and loaders..
> Is there some reason other than an elflint warning that this matters?
I don't know of a real execution problem, no. It's just... weird.