From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: squashfs-devel@lists.sourceforge.net,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Cc: Pengutronix Kernel Team <kernel@pengutronix.de>
Subject: Possible performance regression with CONFIG_SQUASHFS_DECOMP_SINGLE
Date: Tue, 15 Mar 2022 17:23:00 +0100 [thread overview]
Message-ID: <c22a0f1c-883d-5122-ef88-0d7c57ab4e66@pengutronix.de> (raw)
Hello,
This an issue we had with v5.15 that we have since successfully worked around.
I am reporting it here as a pointer in case someone else runs into this and as
a heads up that there seems to be an underlying performance regression, so
here it goes:
We have an i.MX8MM (4x Cortex-A53) system with squashfs on eMMC as a root file
system. The system originally ran NXP's "imx_5.4.24_2.1.0" which has about
5000 patches on top of upstream v5.4.24 including PREEMPT_RT.
The system was updated to mainline Linux + PREEMPT_RT and boot time suffered
considerably growing from 40s with vendor kernel to 1m20s with mainline-based
kernel.
The slowdown on mainline was reproducible for all scheduling models (with
or without PREEMPT_RT) except for PREEMPT_NONE, which was back at 40s.
The services most impacted by the slowdown were C++ applications with many
shared libraries dynamically loaded from the rootfs.
Looking through the original kernel configuration we found that it has
CONFIG_SQUASHFS_DECOMP_SINGLE=y and CONFIG_SQUASHFS_FILE_CACHE=y.
Once changed to CONFIG_SQUASHFS_FILE_DIRECT=y and
CONFIG_SQUASHFS_DECOMP_MULTI_PERCPU=y, we were below 40s as we want.
That's clearly the preferred configuration and it resolves our problem
It doesn't solve the underlying issue though:
- CONFIG_PREEMPT_VOLUNTARY performs much worse than CONFIG_PREEMPT_NONE
for some workloads when CONFIG_SQUASHFS_DECOMP_SINGLE=y
- And this might not have been the case with v5.4. Unfortunately we can't
bisect, because there wasn't enough i.MX8MM support mainline back then
to boot the system. Earliest mainline-based kernel we reproduced this on
was v5.11.
TL;DR: Check if CONFIG_SQUASHFS_DECOMP_MULTI_PERCPU=y in your configuration
Cheers,
Ahmad
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
next reply other threads:[~2022-03-15 16:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-15 16:23 Ahmad Fatoum [this message]
2022-03-16 5:34 ` Phillip Lougher
2022-04-04 20:59 ` Ahmad Fatoum
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=c22a0f1c-883d-5122-ef88-0d7c57ab4e66@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=kernel@pengutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=squashfs-devel@lists.sourceforge.net \
/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
all inboxes | Powered by JetHome®