4

[PATCH] kbuild: modinst: Enable multithread xz compression

 1 year ago
source link: https://lore.kernel.org/lkml/[email protected]/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

[PATCH] kbuild: modinst: Enable multithread xz compression

linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "André Almeida" <[email protected]>
To: [email protected], [email protected],
	Masahiro Yamada <[email protected]>
Cc: [email protected], "Nathan Chancellor" <[email protected]>,
	"Nick Desaulniers" <[email protected]>,
	"Nicolas Schier" <[email protected]>,
	"André Almeida" <[email protected]>
Subject: [PATCH] kbuild: modinst: Enable multithread xz compression
Date: Wed, 22 Feb 2023 21:16:07 -0300	[thread overview]
Message-ID: <[email protected]> (raw)

As it's done for zstd compression, enable multithread compression for
xz to speed up module installation.

Signed-off-by: André Almeida <[email protected]>
---

On my setup xz is a bottleneck during module installation. Here are the
numbers to install it in a local directory, before and after this patch:

$ time make INSTALL_MOD_PATH=/home/tonyk/codes/.kernel_deploy/ modules_install -j16
Executed in  100.08 secs

$ time make INSTALL_MOD_PATH=/home/tonyk/codes/.kernel_deploy/ modules_install -j16
Executed in   28.60 secs
---
 scripts/Makefile.modinst | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/Makefile.modinst b/scripts/Makefile.modinst
index 4815a8e32227..28dcc523d2ee 100644
--- a/scripts/Makefile.modinst
+++ b/scripts/Makefile.modinst
@@ -99,7 +99,7 @@ endif
 quiet_cmd_gzip = GZIP    $@
       cmd_gzip = $(KGZIP) -n -f $<
 quiet_cmd_xz = XZ      $@
-      cmd_xz = $(XZ) --lzma2=dict=2MiB -f $<
+      cmd_xz = $(XZ) --lzma2=dict=2MiB -f -T0 $<
 quiet_cmd_zstd = ZSTD    $@
       cmd_zstd = $(ZSTD) -T0 --rm -f -q $<
 
-- 
2.39.2


next             reply	other threads:[~2023-02-23  0:17 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-23  0:16 André Almeida [this message]
2023-02-23 20:16 ` [PATCH] kbuild: modinst: Enable multithread xz compression Nathan Chancellor
2023-02-24  5:38 ` Masahiro Yamada
2023-02-24 12:12   ` André Almeida
2023-02-25 10:21     ` Masahiro Yamada
find likely ancestor, descendant, or conflicting patches for this message:

	(help)

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 \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    /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).

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK