public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Nick Clifton <nickc@redhat.com>
To: "Jan Beulich" <jbeulich@suse.com>, "Martin Storsjö" <martin@martin.st>
Cc: binutils@sourceware.org
Subject: Re: [PATCH] ld: pe: Improve performance of object file exclude symbol directives
Date: Tue, 6 Sep 2022 12:42:18 +0100	[thread overview]
Message-ID: <2568a388-02a9-4beb-f20b-e2493cda4a64@redhat.com> (raw)
In-Reply-To: <242a402a-57be-0738-d7b8-c19e1a631bb7@suse.com>

Hi Jan,

> On 05.09.2022 14:54, Nick Clifton via Binutils wrote:
>>> +      max_exclude_symbols = ROUND_UP(fdef->num_exclude_symbols + 1, 32);
>>
>> Given that the point of this patch is to improve performance when there
>> are a large number of excluded symbols, incrementing the array by 32 slots
>> at a time seems counter intuitive.  I would suggest a bigger number, eg 1024
>> or 10240.
> 
> Perhaps double the value, thus not overly much impacting the case of there
> being a moderate number of excludes?

To be honest I have no idea what a "large number of excludes" might look like.
So maybe 32 is actually a sensible increment.  Doubling the increment every
time the limit is reached could lead to resource exhaustion issues in extreme
cases, but I doubt if that will ever happen in real life, so that works for me
too.

Cheers
   Nick



  reply	other threads:[~2022-09-06 11:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-02 10:59 Martin Storsjö
2022-09-05 12:54 ` Nick Clifton
2022-09-06  7:40   ` Jan Beulich
2022-09-06 11:42     ` Nick Clifton [this message]
2022-09-06 11:54       ` Jan Beulich
2022-09-06 11:59         ` Martin Storsjö
2022-09-06 13:06         ` Nick Clifton
2022-09-06  9:39   ` Martin Storsjö

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2568a388-02a9-4beb-f20b-e2493cda4a64@redhat.com \
    --to=nickc@redhat.com \
    --cc=binutils@sourceware.org \
    --cc=jbeulich@suse.com \
    --cc=martin@martin.st \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).