From: Alexander Potapenko <glider@google.com>
To: Valdis Kletnieks <Valdis.Kletnieks@vt.edu>
Cc: Linux Memory Management List <linux-mm@kvack.org>,
LKML <linux-kernel@vger.kernel.org>,
Andrey Ryabinin <aryabinin@virtuozzo.com>
Subject: Re: KASAN overhead?
Date: Sat, 19 Mar 2016 13:13:59 +0100 [thread overview]
Message-ID: <CAG_fn=WKjdcUSi5JoiAPrmRCLEL-SWyGHCOYOZiZQ_fnFDvydQ@mail.gmail.com> (raw)
In-Reply-To: <7300.1458333684@turing-police.cc.vt.edu>
[-- Attachment #1: Type: text/plain, Size: 2530 bytes --]
On Mar 18, 2016 9:41 PM, "Valdis Kletnieks" <Valdis.Kletnieks@vt.edu> wrote:
>
> So I built linux-next next-20160417 with KASAN enabled:
Is that next-20160317?
> CONFIG_KASAN_SHADOW_OFFSET=0xdffffc0000000000
> CONFIG_HAVE_ARCH_KASAN=y
> CONFIG_KASAN=y
> # CONFIG_KASAN_OUTLINE is not set
> CONFIG_KASAN_INLINE=y
> CONFIG_TEST_KASAN=m
Which GCC version were you using? Are you sure it didn't accidentally
enable the outline instrumentation (e.g. if the compiler is too old)?
> and saw an *amazing* slowdown.
Have you tried earlier KASAN versions? Is this a recent regression?
> For comparison, here is the time taken
> to reach various points in the dmesg:
>
> % grep -i free dmesg.0317*
> dmesg.0317:[ 1.560907] Freeing SMP alternatives memory: 28K
(ffffffff93d3e000 - ffffffff93d45000)
> dmesg.0317:[ 12.041550] Freeing initrd memory: 10432K (ffff88003f5cb000
- ffff88003fffb000)
> dmesg.0317:[ 16.458451] ata1.00: ACPI cmd f5/00:00:00:00:00:00
(SECURITY FREEZE LOCK) filtered out
> dmesg.0317:[ 16.545603] ata1.00: ACPI cmd f5/00:00:00:00:00:00
(SECURITY FREEZE LOCK) filtered out
> dmesg.0317:[ 17.818934] Freeing unused kernel memory: 1628K
(ffffffff93ba7000 - ffffffff93d3e000)
> dmesg.0317:[ 17.820234] Freeing unused kernel memory: 1584K
(ffff880012c74000 - ffff880012e00000)
> dmesg.0317:[ 17.828426] Freeing unused kernel memory: 1524K
(ffff880013483000 - ffff880013600000)
> dmesg.0317-nokasan:[ 0.028821] Freeing SMP alternatives memory: 28K
(ffffffffaf104000 - ffffffffaf10b000)
> dmesg.0317-nokasan:[ 1.587232] Freeing initrd memory: 10432K
(ffff88003f5cb000 - ffff88003fffb000)
> dmesg.0317-nokasan:[ 2.433557] ata1.00: ACPI cmd f5/00:00:00:00:00:00
(SECURITY FREEZE LOCK) filtered out
> dmesg.0317-nokasan:[ 2.439411] ata1.00: ACPI cmd f5/00:00:00:00:00:00
(SECURITY FREEZE LOCK) filtered out
> dmesg.0317-nokasan:[ 2.488113] Freeing unused kernel memory: 1324K
(ffffffffaefb9000 - ffffffffaf104000)
> dmesg.0317-nokasan:[ 2.488518] Freeing unused kernel memory: 88K
(ffff88002e9ea000 - ffff88002ea00000)
> dmesg.0317-nokasan:[ 2.489490] Freeing unused kernel memory: 388K
(ffff88002ed9f000 - ffff88002ee00000)
Was KASAN reporting anything between these lines? Sometimes a recurring
warning slows everything down.
> Only config difference was changing to CONFIG_KASAN=n.
>
> Is this level of slowdown expected? Or is my kernel unexpectedly off in
the weeds?
How did it behave after the startup? Was it still slow?
Which machine were you using? Was it a real device or a VM?
[-- Attachment #2: Type: text/html, Size: 2974 bytes --]
next prev parent reply other threads:[~2016-03-19 12:14 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-18 20:41 Valdis Kletnieks
2016-03-19 12:13 ` Alexander Potapenko [this message]
2016-03-20 1:14 ` Valdis.Kletnieks
2016-03-21 13:45 ` Alexander Potapenko
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='CAG_fn=WKjdcUSi5JoiAPrmRCLEL-SWyGHCOYOZiZQ_fnFDvydQ@mail.gmail.com' \
--to=glider@google.com \
--cc=Valdis.Kletnieks@vt.edu \
--cc=aryabinin@virtuozzo.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.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