Kexec Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Holzheu <holzheu@linux.vnet.ibm.com>
To: Michael Holzheu <holzheu@linux.vnet.ibm.com>
Cc: kexec mailing list <kexec@lists.infradead.org>,
	Atsushi Kumagai <kumagai-atsushi@mxc.nes.nec.co.jp>,
	Petr Tesarik <ptesarik@suse.cz>, Jan Willeke <willeke@de.ibm.com>
Subject: Re: [PATCH v2 0/8] Handle mmaped regions in cache [more analysis]
Date: Thu, 12 Mar 2015 14:56:16 +0100	[thread overview]
Message-ID: <20150312145616.721b1e37@holzheu> (raw)
In-Reply-To: <20150309170858.0e8bf357@holzheu>

On Mon, 9 Mar 2015 17:08:58 +0100
Michael Holzheu <holzheu@linux.vnet.ibm.com> wrote:

> Hello Petr,
> 

[snip]

> As a conclusion, we could think of mapping larger chunks
> also for the fragmented case of -d 31 to reduce the amount
> of mmap/munmap calls.
> 

FYI: I did some more tests and I am no longer sure if the above
conclusion was correct.

A simple "copy" program that reads or maps/unmaps every page
from /proc/vmcore and then writes it to /dev/null is faster
with mmap()/munmap() than with using read():

read:
-----
# time ./copy /dev/null read

real    0m1.072s
user    0m0.010s
sys     0m1.054s

# perf stat -e syscalls:sys_enter_old_mmap,syscalls:sys_enter_munmap,syscalls:sys_enter_read ./copy /dev/null read            
                 8      syscalls:sys_enter_old_mmap                                   
                 1      syscalls:sys_enter_munmap                                   
            458753      syscalls:sys_enter_read                                     
       1.405457536 seconds time elapsed

mmap:
-----
# time ./copy /dev/null mmap

real    0m0.947s
user    0m0.314s
sys     0m0.631s

# perf stat -e syscalls:sys_enter_old_mmap,syscalls:sys_enter_munmap,syscalls:sys_enter_read ./copy /dev/null mmap
            458760      syscalls:sys_enter_old_mmap                                   
            458753      syscalls:sys_enter_munmap                                   
                 1      syscalls:sys_enter_read                                     
       1.175956735 seconds time elapsed

Regards,
Michael


_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

  reply	other threads:[~2015-03-12 13:56 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-06 14:03 [PATCH v2 0/8] Handle mmaped regions in cache Petr Tesarik
2015-03-06  8:23 ` [PATCH v2 1/8] cache: get rid of search loop in cache_add() Petr Tesarik
2015-03-06  8:52 ` [PATCH v2 2/8] cache: allow to return a page to the pool Petr Tesarik
2015-03-06  8:59 ` [PATCH v2 3/8] cache: do not allocate from the pending list Petr Tesarik
2015-03-06  9:26 ` [PATCH v2 4/8] cache: add hit/miss statistics to the final report Petr Tesarik
2015-03-06 13:07 ` [PATCH v2 5/8] cache: allocate buffers in one big chunk Petr Tesarik
2015-03-06 13:10 ` [PATCH v2 6/8] cache: allow arbitrary size of cache entries Petr Tesarik
2015-03-06 13:23 ` [PATCH v2 7/8] cache: store mapped regions directly in the cache Petr Tesarik
2015-03-06 13:28 ` [PATCH v2 8/8] cleanup: remove unused page_is_fractional Petr Tesarik
2015-03-09 16:08 ` [PATCH v2 0/8] Handle mmaped regions in cache Michael Holzheu
2015-03-09 16:08 ` [PATCH v2 0/8] Handle mmaped regions in cache [more analysis] Michael Holzheu
2015-03-12 13:56   ` Michael Holzheu [this message]
2015-03-12 15:38   ` Petr Tesarik
2015-03-13  4:10     ` Atsushi Kumagai
2015-03-13  8:04       ` Petr Tesarik
2015-03-16  5:14         ` Atsushi Kumagai
2015-03-16  7:26           ` Petr Tesarik
2015-03-16  8:06             ` Atsushi Kumagai
2015-03-16  8:24               ` Petr Tesarik
2015-03-13 16:19     ` Michael Holzheu

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=20150312145616.721b1e37@holzheu \
    --to=holzheu@linux.vnet.ibm.com \
    --cc=kexec@lists.infradead.org \
    --cc=kumagai-atsushi@mxc.nes.nec.co.jp \
    --cc=ptesarik@suse.cz \
    --cc=willeke@de.ibm.com \
    /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