RFC: x86: Enable -z separate-code by default
H.J. Lu
hjl.tools@gmail.com
Thu Feb 22 11:43:00 GMT 2018
On Mon, Feb 19, 2018 at 8:39 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
> On Mon, Feb 19, 2018 at 7:53 AM, Michael Matz <matz@suse.de> wrote:
>> Hi,
>>
>> On Mon, 19 Feb 2018, H.J. Lu wrote:
>>
>>> This patch enables -z separate-code by default for x86. To reduce
>>> x86-64 binary size, set ELF_MAXPAGESIZE to 4KB.
>>
>> Meh :-( Have you done any performance measurements on, say, SPECcpu?
>
> We will.
We compared SPEC CPU 2017 performance before and after this change on
Skylake server. There are no any significant performance changes.
Everything is mostly below +/-1%.
>>> Should I add an ld configure option, --enable-separate-code, instead?
>>
>> Yes, definitely. For old distros at least I definitely want to retain old
>> behaviour by default and a configure switch would make that easier.
>
> Will do.
>
Here is the patch to add --enable-separate-code to ld configure and
enable it by default for Linux/x86. But the default maximum page size
is changed to 4KB for x86-64.
Any comments?
--
H.J.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-ld-Add-enable-separate-code.patch
Type: text/x-patch
Size: 7697 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20180222/982b0287/attachment.bin>
More information about the Binutils
mailing list