From: Ingo Molnar <mingo@kernel.org>
To: Bruce Merry <bmerry@ska.ac.za>
Cc: linux-kernel@vger.kernel.org,
Peter Zijlstra <peterz@infradead.org>,
Paul Mackerras <paulus@samba.org>, Ingo Molnar <mingo@redhat.com>,
Arnaldo Carvalho de Melo <acme@kernel.org>,
Jiri Olsa <jolsa@redhat.com>,
Arnaldo Carvalho de Melo <acme@infradead.org>
Subject: Re: [PATCH v2] perf bench: fix order of arguments to memcpy_alloc_mem
Date: Thu, 19 Feb 2015 01:31:11 +0100 [thread overview]
Message-ID: <20150219003111.GA13304@gmail.com> (raw)
In-Reply-To: <20150115092022.GA11292@kryton>
* Bruce Merry <bmerry@ska.ac.za> wrote:
> This was causing the destination instead of the source to be filled.
> As a result, the source was typically all mapped to one zero page,
> and hence very cacheable.
>
> Signed-off-by: Bruce Merry <bmerry@ska.ac.za>
> ---
> tools/perf/bench/mem-memcpy.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/tools/perf/bench/mem-memcpy.c b/tools/perf/bench/mem-memcpy.c
> index 6c14afe..db1d3a2 100644
> --- a/tools/perf/bench/mem-memcpy.c
> +++ b/tools/perf/bench/mem-memcpy.c
> @@ -289,7 +289,7 @@ static u64 do_memcpy_cycle(const struct routine *r, size_t len, bool prefault)
> memcpy_t fn = r->fn.memcpy;
> int i;
>
> - memcpy_alloc_mem(&src, &dst, len);
> + memcpy_alloc_mem(&dst, &src, len);
>
> if (prefault)
> fn(dst, src, len);
> @@ -312,7 +312,7 @@ static double do_memcpy_gettimeofday(const struct routine *r, size_t len,
> void *src = NULL, *dst = NULL;
> int i;
>
> - memcpy_alloc_mem(&src, &dst, len);
> + memcpy_alloc_mem(&dst, &src, len);
>
> if (prefault)
> fn(dst, src, len);
Acked-by: Ingo Molnar <mingo@kernel.org>
Thanks,
Ingo
next prev parent reply other threads:[~2015-02-19 0:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-15 9:20 [PATCH v2] perf bench: fix order of arguments to memcpy_alloc_mem Bruce Merry
2015-02-19 0:31 ` Ingo Molnar [this message]
2015-03-01 16:49 ` [tip:perf/urgent] perf bench: Fix " tip-bot for Bruce Merry
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=20150219003111.GA13304@gmail.com \
--to=mingo@kernel.org \
--cc=acme@infradead.org \
--cc=acme@kernel.org \
--cc=bmerry@ska.ac.za \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=paulus@samba.org \
--cc=peterz@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.