[Gold] Question about the incorrect variable alignment if the alignment is greater than the page size
Alexander Ivchenko
aivchenk@gmail.com
Tue Jun 4 13:22:00 GMT 2013
The attached patch fixes the problem. Also includes a testcase.
All make check-gold test passes for me on x86_64-unknown-linux-gnu.
Is it ok?
thanks,
Alexander
2013/5/31 Ian Lance Taylor <iant@google.com>:
> On Fri, May 31, 2013 at 4:13 AM, Alexander Ivchenko <aivchenk@gmail.com> wrote:
>>
>> Was that behavior made intentionally or it's just a bug?
>> I know that it's a pretty big alignment and that could be suspicious,
>> but we can at least warn the user that his code won't be linked the
>> way it was written.
>
> It's a bug. The bug is in Layout::set_segment_offsets. It rounds the
> address to abi_pagesize without considering that the segment alignment
> might be larger than that.
>
> Ian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: large_alignment_fix_01.patch
Type: application/octet-stream
Size: 9476 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20130604/7bc04042/attachment.obj>
More information about the Binutils
mailing list