From: ard.biesheuvel@linaro.org (Ard Biesheuvel)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 0/2] ARM: kernel: module PLT optimizations
Date: Tue, 16 Aug 2016 17:51:44 +0200 [thread overview]
Message-ID: <1471362706-29859-1-git-send-email-ard.biesheuvel@linaro.org> (raw)
As reported by Jongsung, the O(n^2) search in the PLT allocation code may
disproportionately affect module load time for modules with a larger number
of relocations.
Since the existing routines rather naively take branch instructions into
account that are internal to the module, we can improve the situation
significantly by checking the symbol section index first, and disregarding
symbols that are defined in the same module.
Patch #1 merge the core and init PLTs, since the latter is virtually empty
anyway.
Patch #2 implements the optimization to only take SHN_UNDEF symbols into
account.
Ard Biesheuvel (2):
ARM: kernel: merge core and init PLTs
ARM: kernel: allocate PLT entries only for external symbols
arch/arm/include/asm/module.h | 6 +-
arch/arm/kernel/module-plts.c | 100 ++++++++++----------
arch/arm/kernel/module.lds | 3 +-
3 files changed, 53 insertions(+), 56 deletions(-)
--
2.7.4
next reply other threads:[~2016-08-16 15:51 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-16 15:51 Ard Biesheuvel [this message]
2016-08-16 15:51 ` [PATCH 1/2] ARM: kernel: merge core and init PLTs Ard Biesheuvel
2016-08-16 15:51 ` [PATCH 2/2] ARM: kernel: allocate PLT entries only for external symbols Ard Biesheuvel
2016-08-17 11:06 ` [PATCH 0/2] ARM: kernel: module PLT optimizations Dave Martin
2016-08-17 11:10 ` Ard Biesheuvel
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=1471362706-29859-1-git-send-email-ard.biesheuvel@linaro.org \
--to=ard.biesheuvel@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
/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 NNTP newsgroup(s).