Retry powerpc gold stub grouping when groups prove too large

Alan Modra amodra@gmail.com
Thu Dec 4 09:45:00 GMT 2014


On Thu, Dec 04, 2014 at 10:11:56AM +0100, Markus Trippelsdorf wrote:
> When building the Linux kernel one gets many messages like:
> 
> ld: stub group size is too large; retrying with 22020096
> ld: stub group size is too large; retrying with 16515072
> 
> Do they really convey any useful information to the user? 

They tell me I have some bugs to squash with the 32-bit support..

For instance:
  bool
  can_reach_stub(Address from, unsigned int off, unsigned int r_type)
  {
    unsigned long max_branch_offset = max_branch_delta(r_type);
    if (max_branch_offset == 0)
      return true;
    gold_assert(from != invalid_address);
    Address loc = off + this->stub_address();
    return loc - from + max_branch_offset < 2 * max_branch_offset;
  }

For 32-bit, "Address" is uint32_t, so when unsigned long is 64-bit we
have a problem when "loc" < "from".

-- 
Alan Modra
Australia Development Lab, IBM



More information about the Binutils mailing list