gold-linked dragonfly kernel unbootable, likely due to segment page size, alignment
John Marino
binutils@marino.st
Wed Feb 22 15:43:00 GMT 2012
On 2/21/2012 14:38, Ian Lance Taylor wrote:
> The header handling behaviour is hardcoded, yes. That said, you should
> be able to control the program headers by using an explicit PHDRS
> section in your linker script. PHDRS are supported by both GNU ld and
> gold.
Okay, I'll investigate tweaking the linker script with a PHDRS section
and see if that is a solution. Thanks!
>
>> Also I'm curious why gold is defaulting to 0x1000 page alignment on
>> x86_64 when the same script on gnu ld results in alignment at
>> 0x200000.
>
> The default maxpagesize is different for GNU ld and gold. However, I'm
> surprised that using -z max_page_size -z common_page_size didn't fix
> that.
I am as well. The different maxpagesize settings of ld and gold isn't
the culprit either because I actually tried rebuilding gold with a
max-page-size default of 0x200000 on x86_64 and there was no difference
at all using the modified gold. It seems to default to the common page
size if it can, regardless of the maximum page size setting.
John
More information about the Binutils
mailing list