]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
[GOLD] powerpc64le-linux fails to link large Linux kernel
authorAlan Modra <amodra@gmail.com>
Wed, 7 Dec 2016 03:42:26 +0000 (14:12 +1030)
committerAlan Modra <amodra@gmail.com>
Tue, 21 Feb 2017 23:10:21 +0000 (09:40 +1030)
commit983d1db4d7b5644b8c16a64bb6cb7267f602ebef
treef73f2f550fa67783da992f4f3933090316c56c88
parentf9aa8e5d979f7b60ca37b331a1dacebcf5e89a4f
[GOLD] powerpc64le-linux fails to link large Linux kernel

Gold attaches stubs to an existing section in contrast to ld.bfd which
inserts a new section for stubs.  If we want stubs before branches,
then the stubs must be added to the previous section.  Adding to the
previous section is a disaster if there is a large gap between the
previous section and the group.

PR gold/20878
* powerpc.cc (Stub_control): Replace stubs_always_before_branch_
with stubs_always_after_branch_, group_end_addr_ with
group_start_addr_.
(Stub_control::can_add_to_stub_group): Rewrite to suit scanning
sections by increasing address.
(Target_powerpc::group_sections): Scan that way.  Delete corner
case.
* options.h (--stub-group-size): Update help string.
gold/ChangeLog
gold/options.h
gold/powerpc.cc